Class: SSHKit::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/sshkit/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



8
9
10
11
12
13
# File 'lib/sshkit/configuration.rb', line 8

def initialize
  @output  = $stdout
  @format  = :dot
  @runner  = :parallel
  @backend = SSHKit::Backend::Netssh
end

Instance Attribute Details

#backendObject

Returns the value of attribute backend.



6
7
8
# File 'lib/sshkit/configuration.rb', line 6

def backend
  @backend
end

#command_mapObject



15
16
17
18
19
20
21
22
23
24
25
# File 'lib/sshkit/configuration.rb', line 15

def command_map
  @command_map ||= begin
    Hash.new do |hash, command|
      if %w{if test time}.include? command.to_s
        hash[command] = command.to_s
      else
        hash[command] = "/usr/bin/env #{command}"
      end
    end
  end
end

#formatObject

Returns the value of attribute format.



6
7
8
# File 'lib/sshkit/configuration.rb', line 6

def format
  @format
end

#outputObject

Returns the value of attribute output.



6
7
8
# File 'lib/sshkit/configuration.rb', line 6

def output
  @output
end

#runnerObject

Returns the value of attribute runner.



6
7
8
# File 'lib/sshkit/configuration.rb', line 6

def runner
  @runner
end