You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
In Drupal 8.x and above, there is no longer a way to "enable/disable" modules. Instead we "install/uninstall" them.
However, Drush still has a pm:enable command along with pm:uninstall.
This is confusing (enable is the opposite of uninstall?) and inconsistent with the Drupal UI.
To Reproduce
List commands in Drush and you'll see that pm:enable turns a module on, and pm:uninstall turns it off (which also involves adding/removing configuration, database tables, and/or content).
Expected behavior
The pm:enable command should be named pm:install for consistency with the Drupal UI and with the pm:uninstall command.
$ drush | grep pm:uninstall
pm:uninstall (un, pmu) Uninstall one or more modules and their dependent modules.
$ drush un diff
[success] Successfully uninstalled: diff
Activity
greg-1-anderson commentedon Nov 13, 2020
+1 we can keep pm:enable as an alias, so there is little cost to doing this.
weitzman commentedon Dec 5, 2020
Yeah, this is a good proposal ... The docs web page will change url. We could add a redirect plugin for mkdocs if we want to avoid a few 404s.
rajeshreeputra commentedon Feb 2, 2022
I have create PR #5061
Also kept alias "install, pm-install, en, pm-enable, pm:enable" for pm:install
@weitzman could you please review changes in PR.
I have tested this on local and confirming that below all commands are working fine, as expected.
gitressa commentedon Apr 16, 2022
This is an improvement, but for consistency, shouldn't we also add an
unalias forpm:uninstall, just aspm:installhasin?pm:installpm:uninstallgitressa commentedon Apr 16, 2022
I created a PR which adds a
unalias, #5131.Fix drush-ops#4588 pm:enable renamed to pm:install (backward compat p…
add pm:install as alias
add pm:install as alias (#2)