Class: Give::CLI
- Inherits:
-
Thor
- Object
- Thor
- Give::CLI
- Defined in:
- lib/give.rb
Overview
Give::CLI
Command line interface provides the 4 commands, setup, start, update and finish
Instance Method Summary collapse
- #finish(owner, project, branch) ⇒ Object
- #setup(owner, project) ⇒ Object
- #start(branch) ⇒ Object
- #update(branch, upstream_branch = :master) ⇒ Object
Instance Method Details
#finish(owner, project, branch) ⇒ Object
38 39 40 41 42 |
# File 'lib/give.rb', line 38 def finish(owner, project, branch) local_repo = Give::Repo.new(:branch => branch) local_repo.push Give::Project.new(owner, project).send_pull_request(local_repo) end |
#setup(owner, project) ⇒ Object
22 23 24 |
# File 'lib/give.rb', line 22 def setup(owner, project) Give::Project.new(owner, project).fork end |
#start(branch) ⇒ Object
27 28 29 |
# File 'lib/give.rb', line 27 def start(branch) Give::Repo.new(:branch => branch).checkout_branch end |