It is essential for every Drupal developer to know how to use configure and use Drupal through Drush as it is a very valuable skill.

To get you started, below are some of the most common Drush commands for Drupal 8.

  • Clear cache: drush cache-rebuild(To clear all caches) or drush cc (To delete one specific cache)

Common Drupal 8 Drush Commands

  • Clear cache even when there’s some problem with Drupal: drush sql-query “DELETE FROM cache”

Common Drupal 8 Drush Commands

  • Open SQL command-line interface: drush sql cli

Common Drupal 8 Drush Commands

  • Print database connection details: drush sql-conf

Common Drupal 8 Drush Commands

  • String for connection to database: drush sql-connect

Common Drupal 8 Drush Commands

  • Enable a module: drush en {name_of_module}

Common Drupal 8 Drush Commands

  • Disable a module: drush dis {name_of_module}

Common Drupal 8 Drush Commands

  • Update a module: drush up {name_of_module}

Common Drupal 8 Drush Commands

  • Update Drupal core and themes: drush pm-update drupal

Common Drupal 8 Drush Commands

  • Check watchdog (logged events): drush ws

Common Drupal 8 Drush Commands

  • Runserver (PHP’s built-in http server for development): drush runserver

Common Drupal 8 Drush Commands

The commands above are the ones we think might come in as most useful. To learn more about Drush and its commands, read the official documentation.

0 Likes
220 Views

You may also like

Leave A Comment

Please enter your name. Please enter an valid email address. Please enter message.