Class: Lambit::Commands::Common::CreateWorkspaceCommand
- Defined in:
- lib/lambit/commands/common.rb
Instance Attribute Summary collapse
-
#workspace ⇒ Object
readonly
Returns the value of attribute workspace.
Attributes inherited from Base
Instance Method Summary collapse
- #command ⇒ Object
-
#initialize(opts, args) ⇒ CreateWorkspaceCommand
constructor
A new instance of CreateWorkspaceCommand.
Methods inherited from Base
Constructor Details
#initialize(opts, args) ⇒ CreateWorkspaceCommand
Returns a new instance of CreateWorkspaceCommand.
69 70 71 72 |
# File 'lib/lambit/commands/common.rb', line 69 def initialize(opts, args) super @workspace = opts['workspace'] end |
Instance Attribute Details
#workspace ⇒ Object (readonly)
Returns the value of attribute workspace.
67 68 69 |
# File 'lib/lambit/commands/common.rb', line 67 def workspace @workspace end |
Instance Method Details
#command ⇒ Object
74 75 76 77 78 79 80 81 82 83 84 85 86 87 |
# File 'lib/lambit/commands/common.rb', line 74 def command begin FileUtils.mkdir_p self.workspace @exitstatus = 0 rescue Exception => e if Lambit.is_debug? Lambit.logger.error e else Lambit.logger.error e. end @exitstatus = 1 end return '', self.exitstatus end |