lib/shexy.rb in shexy-0.3.1 vs lib/shexy.rb in shexy-0.3.2

- old
+ new

@@ -31,11 +31,11 @@ # Shexy.copy_to 'test@test-host', '/home/rubiojr/my-uber-file', '/tmp/' # module Shexy - VERSION = '0.3.1' + VERSION = '0.3.2' [:user, :password, :key, :cmd, :host].each do |n| instance_eval %{ def #{n}; Thread.current[:shexy_#{n}]; end def #{n}=(v); Thread.current[:shexy_#{n}] = v; end @@ -48,10 +48,10 @@ def self.use_sudo(v = true); Thread.current[:shexy_use_sudo] = v; end def self.wait_for_ssh(timeout = 60) Timeout.timeout(timeout) do begin - sleep(1) until tcp_test_ssh(host) do + sleep(1) until tcp_test_ssh do end rescue Errno::ECONNRESET # safe to ignore, we need to retry all the time. end end