Class: Bcnd::Runner
- Inherits:
-
Object
- Object
- Bcnd::Runner
- Defined in:
- lib/bcnd/runner.rb
Instance Attribute Summary collapse
-
#env ⇒ Object
Returns the value of attribute env.
Instance Method Summary collapse
- #deploy ⇒ Object
-
#initialize ⇒ Runner
constructor
A new instance of Runner.
Constructor Details
#initialize ⇒ Runner
6 7 8 |
# File 'lib/bcnd/runner.rb', line 6 def initialize self.env = Bcnd::CI.new end |
Instance Attribute Details
#env ⇒ Object
Returns the value of attribute env.
5 6 7 |
# File 'lib/bcnd/runner.rb', line 5 def env @env end |
Instance Method Details
#deploy ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/bcnd/runner.rb', line 10 def deploy if env.pull_request? puts "Nothing to do for a pull request. Exiting." return end case env.deploy_stage when :mainline deploy_mainline when :stable deploy_stable else puts "Can't recognize the current stage" end end |