Adding modules and themes with drush
Adding new modules couldn't be easier with drush.
List modules on site
First, let's see what modules are loaded on our site:
cd [site document root]
drush pml
Install a new module
Now let's install a new module:
sudo drush dl views # downloads and puts in sites/all/modules
sudo drush en views # enables it
Note that this also gives the opportunity to install required dependencies.
Follow the same steps for a theme. The above will handle multiple projects by putting more than one name on the command line:
sudo drush dl views feeds # downloads and puts the 2 in sites/all/modules
sudo drush en views feeds # enables the 2
Use 'drush dis' to disable (un-enable) and 'drush pm-uninstall' to uninstall project(s).
- Log in to post comments