Class: Dapp::Config::Directive::Shell::Dimg
- Defined in:
- lib/dapp/config/directive/shell/dimg.rb
Overview
Dimg
Direct Known Subclasses
Defined Under Namespace
Classes: StageCommand
Instance Attribute Summary collapse
-
#_before_install ⇒ Object
readonly
Returns the value of attribute _before_install.
-
#_before_setup ⇒ Object
readonly
Returns the value of attribute _before_setup.
-
#_install ⇒ Object
readonly
Returns the value of attribute _install.
-
#_setup ⇒ Object
readonly
Returns the value of attribute _setup.
-
#_version ⇒ Object
readonly
Returns the value of attribute _version.
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Base
Constructor Details
This class inherits a constructor from Dapp::Config::Base
Instance Attribute Details
#_before_install ⇒ Object (readonly)
Returns the value of attribute _before_install.
8 9 10 |
# File 'lib/dapp/config/directive/shell/dimg.rb', line 8 def _before_install @_before_install end |
#_before_setup ⇒ Object (readonly)
Returns the value of attribute _before_setup.
8 9 10 |
# File 'lib/dapp/config/directive/shell/dimg.rb', line 8 def _before_setup @_before_setup end |
#_install ⇒ Object (readonly)
Returns the value of attribute _install.
8 9 10 |
# File 'lib/dapp/config/directive/shell/dimg.rb', line 8 def _install @_install end |
#_setup ⇒ Object (readonly)
Returns the value of attribute _setup.
8 9 10 |
# File 'lib/dapp/config/directive/shell/dimg.rb', line 8 def _setup @_setup end |
#_version ⇒ Object (readonly)
Returns the value of attribute _version.
7 8 9 |
# File 'lib/dapp/config/directive/shell/dimg.rb', line 7 def _version @_version end |
Class Method Details
.stage_command_generator(stage) ⇒ Object
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/dapp/config/directive/shell/dimg.rb', line 14 def self.stage_command_generator(stage) define_method stage do |&blk| (variable = instance_variable_get("@_#{stage}") || StageCommand.new(project: project)).instance_eval(&blk) instance_variable_set("@_#{stage}", variable) end define_method "_#{stage}_command" do return [] if (variable = instance_variable_get("@_#{stage}")).nil? variable._run end define_method "_#{stage}_version" do return [] if (variable = instance_variable_get("@_#{stage}")).nil? variable._version || _version end end |
Instance Method Details
#version(value) ⇒ Object
10 11 12 |
# File 'lib/dapp/config/directive/shell/dimg.rb', line 10 def version(value) @_version = value end |