Last active
May 3, 2016 14:51
-
-
Save juanjmerono/9ee6bb6d3ba4d2645b9c7cbd749a38d8 to your computer and use it in GitHub Desktop.
This file contains 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 | |
# | |
# | |
function log () { | |
if [[ $_VERBOSE -eq 1 ]]; then | |
echo "$@" | |
fi | |
} | |
if [ "$1" == "-v" ] | |
then | |
git cherry 11.x master -v --abbrev=10 | grep '^+' | grep --invert-match -E 'SAK-|KNL-|SAM-|LSNBLDR-|LNSBLDR-|LSNBDLR-|DASH-|RSF-|Sak-' | grep -E '(\#|\s)[0-9]{4}(\:|\s|$)*' | |
else | |
if [ "$1" == "-a" ] | |
then | |
git cherry 11.x master -v --abbrev=10 | grep '^+' | grep --invert-match -E 'SAK-|KNL-|SAM-|LSNBLDR-|LNSBLDR-|LSNBDLR-|DASH-|RSF-|Sak-|(\#|\s)[0-9]{4}(\:|\s|$)*' | |
else | |
for f in $(git cherry 11.x master -v --abbrev=10 | grep '^+' | grep --invert-match -E 'SAK-|KNL-|SAM-|LSNBLDR-|LNSBLDR-|LSNBDLR-|DASH-|RSF-|Sak-' | grep -E '(\#|\s)[0-9]{4}(\:|\s|$)*' | awk '{print $2;}'); do | |
echo "git cherry-pick $f" | |
done | |
fi | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment