18.11.2015 Views

Beginning Drupal 8

Todd Tomlinson - Beginning Drupal 8 (The Expert's Voice in Drupal) - 2015

Todd Tomlinson - Beginning Drupal 8 (The Expert's Voice in Drupal) - 2015

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Chapter 15 ■ Using Drush<br />

To disable the Calendar module, use<br />

drush pm-disable calendar<br />

or the shortened version, drush pm calendar.<br />

If a new version or security patch for the calendar module is released and you’re ready to apply the<br />

update, run<br />

drush pm-update calendar<br />

or the shortened version, drush up calendar.<br />

As you can see, what may take several clicks through the administrative interface can be done through<br />

simple and quick command-line tools.<br />

Table 15-1 represents a comprehensive list of common Drush commands. For a more complete<br />

description, visit http://drush.org.<br />

Table 15-1. Core Drush Commands<br />

Command<br />

archive-dump<br />

archive-restore<br />

cache-clear<br />

cache-get<br />

cache-set<br />

core-config<br />

core-cron<br />

core-execute<br />

core-quick-drupal<br />

core-requirements<br />

core-rsync<br />

core-status<br />

core-topic<br />

drupal-directory<br />

help<br />

image-flush<br />

php-eval<br />

php-script<br />

queue-list<br />

queue-run<br />

Description<br />

Back up your code, files, and database into a single file.<br />

Expand a site archive into a <strong>Drupal</strong> web site.<br />

Clear a specific cache, or all <strong>Drupal</strong> caches.<br />

Fetch a cached object and display it.<br />

Cache an object expressed in JSON or var_export() format.<br />

Edit drushrc, site alias, and <strong>Drupal</strong> settings.php files.<br />

Run all cron hooks in all active modules for specified site.<br />

Execute a shell command. Usually used with a site alias.<br />

Download, install, serve, and log in to <strong>Drupal</strong> with minimal configuration and<br />

dependencies.<br />

Provides information about things that may be wrong in your <strong>Drupal</strong><br />

installation, if any.<br />

Rsync the <strong>Drupal</strong> tree to/from another server using SSH.<br />

Provide a bird’s-eye view of the current <strong>Drupal</strong> installation, if any.<br />

Read detailed documentation on a given topic.<br />

Return path to a given module/theme directory.<br />

Print this help message. See drush help help for more options.<br />

Flush all derived images for a given style.<br />

Evaluate arbitrary PHP code after bootstrapping <strong>Drupal</strong> (if available).<br />

Run PHP script(s).<br />

Return a list of all defined queues.<br />

Run a specific queue by name.<br />

(continued)<br />

172

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!