Class: Bailiff::Runner
- Inherits:
-
Thor
- Object
- Thor
- Bailiff::Runner
- Defined in:
- lib/bailiff/runner.rb
Instance Method Summary collapse
Instance Method Details
#execute(file = 'Bailfile') ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/bailiff/runner.rb', line 6 def execute(file = 'Bailfile') verify_bailfile(file) context = load_bailfile(file) opts = {} if [:remote] != "user@server" data = [:remote].split("@") Net::SSH.start(data[1], data[0]) do |ssh| opts[:ssh] = ssh context.execute(opts) end else context.execute(opts) end end |
#verify(file = 'Bailfile') ⇒ Object
22 23 24 25 26 |
# File 'lib/bailiff/runner.rb', line 22 def verify(file = 'Bailfile') verify_bailfile(file) context = load_bailfile(file) puts context.resolve end |