Module: SshKeySwitcher::Utils::Cmd
- Defined in:
- lib/ssh_key_switcher/utils/cmd.rb
Class Method Summary collapse
Class Method Details
.exec(command, opts = {}) ⇒ Object
10 11 12 13 14 15 16 17 |
# File 'lib/ssh_key_switcher/utils/cmd.rb', line 10 def exec(command, opts = {}) stdout, stderr, status = Open3.capture3(command) if opts[:print] print stderr print stdout end [stdout, stderr, status] end |