Skip to content

Commit

Permalink
fixed remote directory
Browse files Browse the repository at this point in the history
  • Loading branch information
Jens Nazarenus committed Jan 11, 2014
1 parent b240049 commit 0d7c69a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/travis-custom-deploy/transfer/sftp.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ def transfer
Net::SFTP.start(@options['host'], @options['username'],
:password => @options['password']) do |sftp|
for e in @files
require 'pry'; binding.pry
sftp.upload!(e, "#{@remotedir}/")
end
end
Expand All @@ -30,7 +31,7 @@ def check_options(options)

# Prepares the remote directory (remote trailing slash)
def prepare_remotedir
@remotedir = @options[:remotedir]
@remotedir = @options['remotedir']
@remotedir = "" if @remotedir.nil?
@remotedir = @remotedir[0..-2] if @remotedir[-1] == "/"
end
Expand Down

0 comments on commit 0d7c69a

Please sign in to comment.