Class: Net::SSH::Connection::Session

Inherits:
Object
  • Object
show all
Defined in:
lib/ruby-ssh/session.rb

Instance Method Summary collapse

Instance Method Details

#shell_runner {|runner| ... } ⇒ Object

Provides a convenient way to initialize a shell given a Net::SSH session. Yields the new shell if a block is given. Returns the shell instance.

Yields:

  • (runner)


8
9
10
11
12
# File 'lib/ruby-ssh/session.rb', line 8

def shell_runner
  runner = RubySSH::ShellRunner.new(self)
  yield runner if block_given?
  runner
end