Closed (won't fix)
Project:
Drush
Version:
8.x-6.x-dev
Component:
Base system (internal API)
Priority:
Normal
Category:
Bug report
Assigned:
Issue tags:
Reporter:
Created:
18 Jan 2011 at 13:32 UTC
Updated:
11 Sep 2013 at 04:59 UTC
Jump to comment: Most recent file
Comments
Comment #1
moshe weitzman commentedThere is a built-in alias called @sites for this. e.g.
Oddly, @sites is not shown by plain old
drush sa. Assigning to Greg.Comment #2
joachim commentedHere's a patch to document the @sites alias in aliases example file.
Comment #3
roball commentedIn final drush 5.0, 'drush sa' gives me
where onesite.example.com and anothersite.example.com are the sites represented by the @sites alias, but the @sites alias itself is not displayed. The correct output should be
shouldn't it?
Comment #4
roball commentedComment #5
greg.1.anderson commentedThis is an unimplemented feature; the @sites alias has never been shown in the sa command. The old title was better.
Comment #6
roball commentedBut according to
'drush sa' should print all alias records. The @sites alias is definitely missing, but "onesite.example.com" and "anothersite.example.com" are no alias records.
What does work, however, is when the 'sa' command is executed with the '@sites' argument:
The list of site URIs is printed alphabetically, which is an improvement over drush 4.
Comment #7
greg.1.anderson commentedPlease try the attached patch. It should clear up both this issue, and the other one you reported in #875322: Adding context information for @sites output.
Comment #8
greg.1.anderson commentedHere is a slight improvement, for situations where there are no @sites.
Comment #9
roball commentedThank you for the quick patch. With patch #8 applied, I now get
so "@sites" is now included, fine. But shouldn't the actual @sites items (onesite.example.com, anothersite.example.com, ...) be excluded from the list of all alias records?
Comment #10
moshe weitzman commented@roball - I think listing onsite.example.com and friends is by design.
@greg - when i use #8 patch and run dr sa from outside a drupal site, I see @sites in the list but it has no output in detail view. Is that by design? if so, feel free to commit this.
Comment #11
greg.1.anderson commentedNo, @sites should not show up in sa unless it contains at least one site. I thought I had already fixed that -- but in any event, I will re-fix it and then commit.
Regarding #9, yes, Drush creates an implicit alias (without an "@") for every bootstrapped or referenced site. This allows you to use the name of the site folder ("default" & c.) for rsync / sql-sync args as desired. sa lists all aliases that Drush knows about, including multiple representations of the same site.
Comment #12
greg.1.anderson commentedAlso reported: @sites is not working if
$options['root']is used to select the Drupal root.Comment #13
greg.1.anderson commentedRe-titling to match increased scope of patch.
Comment #14
roball commentedMay I ask why patch #8 has not yet been committed?
Comment #15
greg.1.anderson commentedStill needs fixing per #12.
Comment #16
roball commentedWith Drush 5.7, I now get the following error when trying to apply st to @sites:
Comment #17
roball commentedCan we expect a fix in Drush 5.x?
Thanks for giving any status update.
Comment #18
greg.1.anderson commentedI for one am really busy right now and have no immediate plans to work on this. Patches welcome.
Comment #19
roball commentedThe bug reported at #16 observed with drush 5.9 is still present in 6.0-rc1:
Comment #20
roball commentedActually, commands such as st or ups do work when applied on @sites, but only while being in the Drupal root directory. Being in any other directory causes drush to exit with the following error:
So the following workaround makes it working:
Comment #21
greg.1.anderson commentedThanks for testing. This is a restatement of #12. Patches welcome.
Comment #22
greg.1.anderson commentedThis issue was marked
closed (won't fix)because Drush has moved to Github.If desired, you may copy this bug to our Github project and then post a link here to the new issue. Please also change the status of this issue to
closed (duplicate).Please ask support questions on Drupal Answers.