Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In Drupal drush en downloads the module if it does not exist in file sys already; can we have that in Backdrop too? #192

Open
klonos opened this issue Aug 3, 2019 · 1 comment

Comments

@klonos
Copy link
Member

klonos commented Aug 3, 2019

In Drupal if a module does not exist in the file system and a user types

drush en devel

drush asks the user if they would like to download devel, and if they say yes it downloads it and then enables it.

This request is for feature parity with that experience in Backdrop Drush Extension.

OP for Posterity

I've also mentioned this on Gitter...

On a Mac, with latest ddev/docker:

ddev version
DDEV-Local version	v1.10.0                        
commit            	v1.10.0                        
db                	drud/ddev-dbserver:v1.10.0-10.2
dba               	drud/phpmyadmin:v1.10.0        
ddev-ssh-agent    	drud/ddev-ssh-agent:v1.10.0    
docker            	19.03.1                        
docker-compose    	1.24.1                         
os                	darwin                         
router            	drud/ddev-router:v1.10.0       
web               	drud/ddev-webserver:v1.10.0

...certain commands like drush st and drush cc all work w/o any issue, either via ddev exec ... or direct drush commands after ddev ssh into the environment:

ddev exec drush st
 Backdrop version         :  1.14.x-dev
 Site URI                 :  http://docroot
 Database driver          :  mysql
 Database hostname        :  db
 Database port            :  3306
 Database username        :  db
 Database name            :  db
 Backdrop bootstrap       :  Successful
 Backdrop user            :
 PHP configuration        :  /etc/php/7.2/cli/php.ini
 PHP OS                   :  Linux
 Drush script             :  /usr/local/bin/drush8
 Drush version            :  8.2.3
 Backdrop Drush           :  1.0.0
 Drush temp directory     :  /tmp
 Drush configuration      :
 Drush alias files        :
 Install profile          :  standard
 Backdrop Settings File   :  ./settings.php
ddev ssh
...
drush cc all
'all' cache was cleared.

...while drush en and drush dl do not work:

drush en devel
The following projects will be enabled: devel.
    Do you want to enable the projects? (y/n): y

	Error devel does not exist in your Backdrop installation.
	Try downloading devel first with the command: drush dl devel

drush dl devel

	Error: There is no release located at https://github.com/backdrop-contrib/devel/releases/download//devel.zip.
	Try visiting the devel page directly: https://github.com/backdrop-contrib/devel
@klonos
Copy link
Member Author

klonos commented Aug 17, 2019

Since I last posted this, I've updated ddev from 1.10.0 to 1.10.2, and now drush dl seems to work:

ddev version
DDEV-Local version	v1.10.2                        
commit            	v1.10.2                        
db                	drud/ddev-dbserver:v1.10.0-10.2
dba               	drud/phpmyadmin:v1.10.0        
ddev-ssh-agent    	drud/ddev-ssh-agent:v1.10.2    
docker            	19.03.1                        
docker-compose    	1.24.1                         
os                	darwin                         
router            	drud/ddev-router:v1.10.0       
web               	drud/ddev-webserver:v1.10.2
ddev ssh

...

drush status
 Backdrop version         :  1.14.x-dev               
 Site URI                 :  http://docroot           
 Database driver          :  mysql                    
 Database hostname        :  db                       
 Database port            :  3306                     
 Database username        :  db                       
 Database name            :  db                       
 Backdrop bootstrap       :  Successful               
 Backdrop user            :                           
 PHP configuration        :  /etc/php/7.2/cli/php.ini 
 PHP OS                   :  Linux                    
 Drush script             :  /usr/local/bin/drush8    
 Drush version            :  8.2.3                    
 Backdrop Drush           :  1.0.0                    
 Drush temp directory     :  /tmp                     
 Drush configuration      :                           
 Drush alias files        :                           
 Install profile          :  standard                 
 Backdrop Settings File   :  ./settings.php
drush en devel
The following projects will be enabled: devel.
    Do you want to enable the projects? (y/n): y

	Error devel does not exist in your Backdrop installation.
	Try downloading devel first with the command: drush dl devel

drush dl devel

	Success:  Project devel downloaded to /var/www/html/docroot/modules/devel.

drush en devel
The following projects will be enabled: devel.
    Do you want to enable the projects? (y/n): y

	Success: module devel enabled.

Still drush en fails if the module does not exist already, whereas in Drupal, it asks if you want to download the module, then downloads and enables it.

@serundeputy serundeputy changed the title drush en and drush dl not working In Drupal drush en downloads the module if it does not exist in file sys already; can we have that in Backdrop too? Sep 15, 2019
@serundeputy serundeputy self-assigned this Jan 19, 2020
@serundeputy serundeputy added this to the 1.2.1 milestone Jan 19, 2020
@serundeputy serundeputy removed this from the 1.2.1 milestone Apr 11, 2020
@serundeputy serundeputy removed their assignment Apr 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants