- Module A depends on module B
- I cd into sites/example.com and drush en module_a
- Module B (required by module_a) is not present
- Drush tells me "The following projects have unmet dependencies: module_a requires module_b.
Would you like to download them"
- If I say yes, drush attemps to download module_b into sites/all (failing if I don't have write access there), whereas if I cancel and drush dl module_b, drush downloads module_b into my current directory, sites/example.com.
It would seem logical for dependencies to be downloaded into whatever directory I'm currently in (or, perhaps, the directory of the module I wanted to enable in the first place), rather than always dl into sites/all
Cheers,
Albert.
Comments
Comment #1
greg.1.anderson CreditAttribution: greg.1.anderson commentedThis came up on Stack Exchange today; while I have not tried to implement a fix for this, it seems that in addition to passing --destination on to pm-download, we'd also need to add a global --cwd Drush option (to override the current working directory) -- either that, or restore the old CWD before making the call out. This will catch the case where the user is implicitly selecting the destination by setting the cwd to the site configuration folder. Drush always sets the cwd to the Drupal root while it is running, because that is what Drupal code expects.
Comment #2
mojzis CreditAttribution: mojzis commentedthe older issue on the same theme wasnt described so well so i guess i will close it ? #1126992: unmet dependencies downloads to sites/all
Comment #3
greg.1.anderson CreditAttribution: greg.1.anderson commentedThanks for catching the dup. The old one was fine, but I didn't see or remember it when commenting on this one.
Comment #4
greg.1.anderson CreditAttribution: greg.1.anderson commentedThis issue was marked
closed (won't fix)
because Drush has moved to Github.If this feature is still desired, you may copy it to our Github project. For best results, create a Pull Request that has been updated for the master branch. Post a link here to the PR, and please also change the status of this issue to
closed (duplicate)
.Please ask support questions on Drupal Answers.
Comment #4.0
greg.1.anderson CreditAttribution: greg.1.anderson commentedremoved some superfluous text.