Created
June 30, 2014 11:12
-
-
Save mkf-simpson/6abdd838bb0177614dc5 to your computer and use it in GitHub Desktop.
task number from branch name
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
#!/usr/bin/env bash | |
branch=$(git symbolic-ref --short HEAD) | |
branch_description=$(echo $branch | cut -f2 -d/) | |
prefix=$(echo $branch_description | cut -f1 -d-) | |
number=$(echo $branch_description | cut -f2 -d-) | |
git commit -am "$prefix-$number $1" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment