Class: Conjure::CommandTarget
- Inherits:
-
Object
- Object
- Conjure::CommandTarget
- Defined in:
- lib/conjure/command_target.rb
Instance Method Summary collapse
- #application ⇒ Object
- #existing_instance ⇒ Object
-
#initialize(options = {}) ⇒ CommandTarget
constructor
A new instance of CommandTarget.
- #new_instance ⇒ Object
Constructor Details
#initialize(options = {}) ⇒ CommandTarget
Returns a new instance of CommandTarget.
3 4 5 6 7 |
# File 'lib/conjure/command_target.rb', line 3 def initialize( = {}) @origin = [:origin] @branch = [:branch] || "master" @rails_env = [:rails_env] || "production" end |
Instance Method Details
#application ⇒ Object
9 10 11 |
# File 'lib/conjure/command_target.rb', line 9 def application @application ||= Application.find(:path => Dir.pwd, :origin => @origin) end |
#existing_instance ⇒ Object
13 14 15 |
# File 'lib/conjure/command_target.rb', line 13 def existing_instance @existing_instance ||= application.instances.first end |