Class: GemPublisher::CliFacade
- Inherits:
-
Object
- Object
- GemPublisher::CliFacade
- Defined in:
- lib/gem_publisher/cli_facade.rb
Constant Summary collapse
- Error =
Class.new(RuntimeError)
Instance Method Summary collapse
Instance Method Details
#execute(*arguments) ⇒ Object
8 9 10 11 12 13 14 15 |
# File 'lib/gem_publisher/cli_facade.rb', line 8 def execute(*arguments) cmd = Shellwords.join(arguments) stdout_str, stderr_str, status = Open3.capture3(cmd) if status.exitstatus > 0 raise Error, [stderr_str, stdout_str].join("\n").strip end stdout_str end |