1

I'm using Acquia's DevDesktop on Windows 10. For a shell, I'm using babun's zsh. Acquia provides the drush command line interface to Drupal.

The command itself seems okay:

{ drush }  » pwd                                                                                /cygdrive/c/Program Files (x86)/DevDesktop/tools/vendor/drush/drush 
{ drush }  » ./drush                                                                            /cygdrive/c/Program Files (x86)/DevDesktop/tools/vendor/drush/drush 
Execute a drush command. Run `drush help [command]` to view command-specific help.  Run `drush topic` to read even more documentation.
...

I created a symlink for it, but it doesn't work:

{ drush }  »  ls -lha /home/username/bin/drush                                                    /cygdrive/c/Program Files (x86)/DevDesktop/tools/vendor/drush/drush
lrwxrwxrwx 1 username None 73 Aug  1 23:29 /home/username/bin/drush -> '/cygdrive/c/Program Files (x86)/DevDesktop/tools/vendor/drush/drush/drush'

{ drush }  » cd ~                                                                                 /cygdrive/c/Program Files (x86)/DevDesktop/tools/vendor/drush/drush
{ ~ } master »                                                                                                                                              
{ ~ } master » drush                                                                                                                                               
Could not open input file: /home/username/bin/drush

I tried changing the permissions, and ensuring line endings are correct, as per this answer, but it still doesn't work.

{ ~ } master » chmod 775 /home/username/bin/drush   
{ ~ } master » dos2unix -F /home/username/bin/drush                                                                                                               
dos2unix: converting file /home/username/bin/drush to Unix format...
{ ~ } master » drush                                                                                                                                               
Could not open input file: /home/username/bin/drush

What am I doing wrong?

(I also asked this question on stackoverflow, but thought it might fare better here).

Edit as per DopeGhoti's comment, I checked the bin dir's permissions. Turns out it was a symlink too:

{ ~ } master » ls -lha /home/username/bin                                                                                                                           ~
lrwxrwxrwx 1 username None 25 Oct 26  2016 /home/username/bin -> /home/username/.local/bin

{ ~ } master » ls -la /home/username/.local/bin                                                                                                                     ~
total 1797
drwxrwxr-x+ 1 username None       0 Aug  1 23:39 .
drwxr-xr-x+ 1 username None       0 Oct 26  2016 ..
-rwxrwxr-x+ 1 username None 1836198 Jul 30 18:43 composer
lrwxrwxrwx  1 username None      73 Aug  1 23:29 drush -> '/cygdrive/c/Program Files (x86)/DevDesktop/tools/vendor/drush/drush/drush'

closed as off-topic by Michael Homer, Stephen Rauch, Jeff Schaller, Archemar, Rui F Ribeiro Aug 20 '17 at 8:47

This question appears to be off-topic. The users who voted to close gave these specific reasons:

  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – Stephen Rauch, Archemar, Rui F Ribeiro
  • "This question has been posted on multiple sites. Cross-posting is strongly discouraged; see the help center and community FAQ for more information." – Michael Homer, Jeff Schaller

  • What are the permissions of /home/username/bin? – DopeGhoti Aug 2 '17 at 20:57
  • @DopeGhoti see edits – user394 Aug 2 '17 at 22:15