Currently, since http://drupal.org/node/648910 has been fixed, we can dl modules from our feature server by specifying the --source option on the command-line, which is great.
Now, i was wondering if we could improve this a little bit. Would it be possible to specify in our drushrc file a fallback --source option. I mean, if you drush dl projectname without adding the --source option on the command line, drush first tries to dl from drupal.org, and if the project is not found there, drush tries to dl from the specified fallback.
Better maybe might be to have an array of sources to download from. This could default to a single-value array including the drupal.org url. This way, we could also tell drush to first look on our feature server, and if that fails check drupal.org.
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | option-array-in-drushrc-file-to-specify-which-sources-to-download-from-1161074-1.patch | 3.42 KB | zilverdistel |
Comments
Comment #1
zilverdistel commentedHere's a patch that works for me (git apply to origin/7.x-4.x).
In my drushrc.php I specify:
Comment #2
cyberwolf commentedWould be a great addition!
Comment #3
kayalion commentedsubscribe
Comment #4
jonhattan'warning' is not appropiate for a informative message.
If this and other commented out lines of code are not neccesary just remove them.
Also, this needs documentation in example.drushrc.php.
Comment #5
zilverdistel commentedI agree about the warning, but when I use "notice", the message doesn't get displayed. That makes it kinde confusing, because there is a warning if the release is not found on the first server. Maybe we can tackle this by replacing the current warning (Trying to fetch from !source) by the following:
This message could have a severity "warning", I think. What do you think?
Concerning the comment you mention: it was allready there, so I'm not sure if my patch should touch it ...
Comment #6
cyberwolf commentedIMHO there should be only displayed 1 warning when none of the servers were able to satisfy the dl command. As you explicitly tell Drush through drushrc.php to look on multiple servers, you as a person are aware of that chain already, and there is no reason to explicitly warn the user about one link in the chain not being able to fullfil the request succesfully. Informative messages about the fallback chain are fine though and even recommended for debugging I think.
Comment #7
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.