Last active
March 17, 2016 14:49
-
-
Save mario21ic/14aa58a1787710ad938d to your computer and use it in GitHub Desktop.
Script to git pull/push into current branch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function current_branch() { | |
| git branch|grep "\*"|awk '{print $2}' | |
| } | |
| function gpull() { | |
| git pull origin $(current_branch) | |
| } | |
| function gpush() { | |
| git push origin $(current_branch) | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment