Ensure -e ssh ... is always passed to rsync. Fixes #54

This commit is contained in:
Tom Vaughan 2014-02-23 11:26:27 -03:00
parent c22ff4bc15
commit 865b98f1c0
2 changed files with 3 additions and 3 deletions

View file

@ -50,7 +50,7 @@ activate :deploy do |deploy|
# deploy.user = "tvaughan" # no default
# deploy.port = 5309 # ssh port, default: 22
# deploy.clean = true # remove orphaned files on remote host, default: false
# deploy.flags = "-rltgoDvzO --no-p --del -e" # add custom flags, default: -avze
# deploy.flags = "-rltgoDvzO --no-p --del" # add custom flags, default: -avz
end
```

View file

@ -21,8 +21,8 @@ module Middleman
user = "#{self.user}@" if self.user && !self.user.empty?
dest_url = "#{user}#{self.host}:#{self.path}"
flags = self.flags || '-avze'
command = "rsync #{flags} 'ssh -p #{self.port}' #{self.server_instance.build_dir}/ #{dest_url}"
flags = self.flags || '-avz'
command = "rsync #{flags} '-e ssh -p #{self.port}' #{self.server_instance.build_dir}/ #{dest_url}"
if self.clean
command += " --delete"