Discovering Drush: Drupal's Swiss Army KnifePresentation Transcript
Drupal’s Swiss Army Knife
Drupal Camp Alberta 2010
September 12, 2010
๏ Presentation slides
(http://slideshare.net/jdschroeder and http://jdschroeder.ca)
๏ Presentation video
(http://drupalcampalberta.org and http://vimeo.com/drupalcampab)
๏ Who will get the most out of this presentation:
๏ You are reasonably comfortable using command-line utilities.
๏ You know the general concepts of Drupal.
๏ See what Drush can do and how to use it.
What is Drush?
๏ Drupal shell
๏ Not a module
๏ Collection of scripts that allow you to perform
Drupal tasks from the command line on your
So why should I care?
๏ Do you spend a lot of time at a command
๏ Accomplish admin tasks quicker than via the
๏ Scriptability of common tasks.
๏ Keeping up to date.
All that, and smart, too
๏ Drush knows what site you’re working on.
๏ Drush knows what version of Drupal you are
๏ To be run alongside your Drupal installations
(i.e. on a server).
๏ Requires command-line access to PHP 5.2.
๏ Current release is 3.3.
๏ Download and extract on your server.
๏ See README.txt
๏ Make the Drush script executable.
๏ Create a symlink in /usr/local/bin or create an
๏ Global and site speciﬁc drushrc.php ﬁles
๏ Conﬁgures path locations, site aliases,
checkout handling, database dump options,
command-speciﬁc options, and variable
๏ example.drushrc.php is included.
๏ $ drush [options] <command>
Did I say all versions?
๏ Not all commands are available to all Drupal
๏ site-install requires Drupal 7, several other
commands require at least Drupal 6.
Syncing ﬁles and data
๏ $ drush rsync sites/default
๏ $ drush sql-sync development
Want to learn more?
๏ Documentation on Drupal.org
๏ Session from the developers of Drush at
DrupalCons in 2009 and 2010: