Method: FileTransfer::Ftp#upload
- Defined in:
- lib/file_transfer/ftp.rb
#upload(from_path, to_path) ⇒ Object
Uploads file to FTP server
34 35 36 37 38 39 40 |
# File 'lib/file_transfer/ftp.rb', line 34 def upload(from_path, to_path) to_path = split_path(to_path) open_connection do ftp.chdir to_path[:file_path] ftp.putbinaryfile(from_path) end end |