Class: SSHKit::Backend::Printer
Instance Attribute Summary
Attributes inherited from Abstract
#host
Instance Method Summary
collapse
#make, #rake
Methods inherited from Abstract
#as, config, configure, #debug, #error, #fatal, #info, #initialize, #log, #make, #rake, #trace, #warn, #with, #within
Instance Method Details
#capture(*args) ⇒ Object
Also known as:
capture!
21
22
23
|
# File 'lib/sshkit/backends/printer.rb', line 21
def capture(*args)
String.new.tap { execute(*args) }
end
|
#execute(*args) ⇒ Object
Also known as:
upload!, download!, test
12
13
14
15
16
|
# File 'lib/sshkit/backends/printer.rb', line 12
def execute(*args)
command(*args).tap do |cmd|
output << cmd
end
end
|
#run ⇒ Object
8
9
10
|
# File 'lib/sshkit/backends/printer.rb', line 8
def run
instance_exec(host, &@block)
end
|