I installed Drush with composer global require drush/drush:dev-master
but it has some problems. I am using Xampp and Windows 8.
How can I downgrade Drush from 8-dev to 7?
Drupal Answers is a question and answer site for Drupal developers and administrators. It only takes a minute to sign up.
Sign up to join this communityYou can first uninstall (remove) the version you don't want anymore (8-dev) and then try install the version you want.
So, first run drush status
; then look for drush script
. You can see the directory Drush was installed on your computer; try remove it manually or with rmdir <path>
.
And according to Drush Documentation page, install the version you want (i.e. 7).
composer global require drush/drush:7.*
# Remove the current version of drush.
composer global remove drush/drush
# Install drush version 7.
composer global require drush/drush:7.*
You can install drush as git clone, and either checkout master or a tag to accomplish this. Just remember to do a composer install
if you checkout a version that uses composer (pretty sure all of the 7.x tags do, not sure about the 6.x tags), or add this as a post-checkout hook.