Module: Avm::EacRailsBase1::RunnerWith::RailsEnvironment
- Defined in:
- lib/avm/eac_rails_base1/runner_with/rails_environment.rb
Defined Under Namespace
Modules: ClassMethods
Constant Summary collapse
- DEFAULT_RAILS_ENVIRONMENT_CONSTANT =
'DEFAULT_RAILS_ENVIRONMENT'
Instance Method Summary collapse
Instance Method Details
#default_rails_environment ⇒ Object
29 30 31 |
# File 'lib/avm/eac_rails_base1/runner_with/rails_environment.rb', line 29 def default_rails_environment self.class.default_rails_environment end |
#rails_environment ⇒ Object
33 34 35 |
# File 'lib/avm/eac_rails_base1/runner_with/rails_environment.rb', line 33 def rails_environment parsed.environment.presence || default_rails_environment end |
#rails_instance ⇒ Object
37 38 39 40 41 42 43 |
# File 'lib/avm/eac_rails_base1/runner_with/rails_environment.rb', line 37 def rails_instance if respond_to?(:runner_context) runner_context.call(:instance) else context(:instance) end end |