-
-
Save simon2k/6987769 to your computer and use it in GitHub Desktop.
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
#!/bin/bash | |
set -e | |
pivotal_ticket_id=$1 | |
function commits_from_development() { | |
git checkout development > /dev/null 2>&1 | |
git log --reverse --oneline --no-abbrev-commit --grep $1 | cut -d ' ' -f 1 | |
} | |
function apply_on_master() { | |
git checkout master > /dev/null 2>&1 | |
git cherry-pick $@ | |
} | |
commits=$(commits_from_development $pivotal_ticket_id) | |
apply_on_master $commits |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment