Pregunta

I'm trying to make a proof of concept script with ruby, but seem to be failing... I've give then script permission to run, but when it's ran I get ": No such file or directory" from my terminal.

I do have net-sftp installed through gem, so I'm at a loss as to what it could be.

#!/usr/bin/env ruby

require 'net/sftp'

Net::SFTP.start('10.0.0.8', 'jacob', :password=> 'password') do |sftp|
  #download a directory
  sftp.download!("/home/jacob/backups/*", "/home/pi")
end
¿Fue útil?

Solución

Turns out it was an issue with my system, not ruby. Sorry for the confusion.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top