Class: GithubIssuesCli::Command::Push
- Inherits:
-
GithubIssuesCli::Command
- Object
- Clamp::Command
- GithubIssuesCli::Command
- GithubIssuesCli::Command::Push
- Defined in:
- lib/github_issues_cli/command/push.rb
Instance Attribute Summary
Attributes inherited from GithubIssuesCli::Command
Instance Method Summary collapse
Methods inherited from GithubIssuesCli::Command
#authenticate, #get_git_repo, #get_github_repo, #get_issue_number, #get_source, #initialize, #run
Constructor Details
This class inherits a constructor from GithubIssuesCli::Command
Instance Method Details
#execute ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 |
# File 'lib/github_issues_cli/command/push.rb', line 4 def execute issue_number = get_issue_number source = get_source issue_number if source.nil? source = 'origin/issue-' + issue_number end print 'Pushing code to ' puts bold source remote, branch = source.split('/') get_git_repo.push(remote, branch) end |