Note that there are some explanatory texts on larger screens.

plurals
  1. POHow do I get Drush rsync to use site-aliases correctly?
    primarykey
    data
    text
    <p>I'm using Drush 4.2 and I'm trying to rsync files from a the dev server to my local machine. My aliases.drushrc.php is located in the root of my local drupal installation and has the following in it:</p> <pre><code> $aliases['local'] = array( 'root' =&gt; '/Users/christian/Sites/site-root', 'path-aliases' =&gt; array( '%files' =&gt; 'sites/default/files' ), ); $aliases['dev'] = array( 'root' =&gt; '/var/www/vhosts/some-domain.com/subdomains/dev/httpdocs', 'remote-host' =&gt; 'some-domain.com', 'remote-user' =&gt; 'root', 'path-aliases' =&gt; array( '%drush' =&gt; ' /var/tools/drush/drush', '%files' =&gt; 'sites/default/files', ), ); </code></pre> <p>As a test I try to run this from the local drupal root:</p> <blockquote> <p>drush rsync @dev:%files ~/Desktop/test/</p> </blockquote> <p>I expect @dev:%files to expand to the remote file path but instead I get:</p> <blockquote> <p>You will destroy data from /Volumes/MacintoshHD/Users/christian/Desktop/test/ and replace with data from @dev:/Volumes/MacintoshHD/Users/christian/Sites/site-root/%files</p> </blockquote> <p>Any ideas?</p> <p>UPDATE: I've also found that when I'm try the command:</p> <blockquote> <p>drush dd @dev:%files</p> </blockquote> <p>I get </p> <blockquote> <p>Target '@dev:%files' not found.</p> </blockquote> <p>UPDATE 2</p> <p>I've found that the issue seems to be coming from the location of the aliases.drushrc.php file. I had it in the drupal root of the site I was working on. I found that if I moved it to ~/.drush/ then everything worked perfectly.</p> <p>I'd prefer to have it under source control though. I tried putting it in sites/default/ but it had the same problems as before. I'll award the bounty to whomever tells me where to put this file so it's under the source controlled site root. </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload