Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Allow alternate branch names in feature finish.

Previously, we'd just push whatever branch you were on - whoops!  Or
worse, if the user didn't have push.default set to 'current', we could
be pushing to any number of other branches; this is probably still a
problem a bunch of other places. :(

Fixes #38.
  • Loading branch information...
commit b549859ef46e5e4fd6347b32cbbff93b88f78467 1 parent 70fec6d
@xiongchiamiov xiongchiamiov authored
Showing with 2 additions and 2 deletions.
  1. +1 −1  feature.rb
  2. +1 −1  hotfix.rb
View
2  feature.rb
@@ -69,7 +69,7 @@
when 'finish'
feature = ARGV[1] || Git::current_branch
# Push commits to origin
- Git::run_safe("git push")
+ Git::run_safe("git push origin #{feature}:#{feature}")
exit 1 if !confirm("Create a pull-request for feature branch named: '#{feature}' ?")
octokit = Github::api
View
2  hotfix.rb
@@ -38,7 +38,7 @@
end
# Push commits to origin
- Git::run_safe("git push")
+ Git::run_safe("git push origin #{hotfix}:#{hotfix}")
exit 1 if !confirm("Create a pull-request for hotfix branch named: '#{hotfix}' ?")
octokit = Github::api
Please sign in to comment.
Something went wrong with that request. Please try again.