Skip to content

Instantly share code, notes, and snippets.

@unnitallman
Created August 18, 2011 01:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save unnitallman/1153108 to your computer and use it in GitHub Desktop.
Save unnitallman/1153108 to your computer and use it in GitHub Desktop.
FTP with Ruby
require 'net/ftp'
ftp=Net::FTP.new
ftp.connect(URL,21)
ftp.login(username,passwd)
ftp.chdir(directory)
ftp.getbinaryfile(filename)
ftp.close
http://ruby-doc.org/stdlib/libdoc/net/ftp/rdoc/index.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment