Class: Cask::Cmd::ExternalRubyCommand Private

Inherits:
Object
  • Object
show all
Defined in:
brew/Library/Homebrew/cask/cmd.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Wrapper class for running an external Ruby command.

Instance Method Summary collapse

Constructor Details

#initialize(command, path) ⇒ ExternalRubyCommand

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of ExternalRubyCommand.



197
198
199
200
# File 'brew/Library/Homebrew/cask/cmd.rb', line 197

def initialize(command, path)
  @command_name = command.to_s.capitalize.to_sym
  @path = path
end

Instance Method Details

#helpObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



206
207
208
# File 'brew/Library/Homebrew/cask/cmd.rb', line 206

def help
  command_class&.help
end

#run(*args) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



202
203
204
# File 'brew/Library/Homebrew/cask/cmd.rb', line 202

def run(*args)
  command_class&.run(*args)
end