about summary refs log tree commit diff stats
path: root/doc/pick.sh
diff options
context:
space:
mode:
Diffstat (limited to 'doc/pick.sh')
-rwxr-xr-xdoc/pick.sh15
1 files changed, 8 insertions, 7 deletions
diff --git a/doc/pick.sh b/doc/pick.sh
index fb9da83b..baa41c46 100755
--- a/doc/pick.sh
+++ b/doc/pick.sh
@@ -8,17 +8,18 @@
 # Bad commits are marked with a "custom:" at the beginning
 # of the commit message.
 
-BRANCH=`git branch 2>/dev/null|grep -e ^* | tr -d \*\ `
+MASTER_BRANCH='master'
+CUSTOM_BRANCH='hut'
+ORIGINAL_BRANCH=`git branch 2>/dev/null|grep -e ^* | tr -d \*\ `
 
-git checkout master
+git checkout $MASTER_BRANCH
 
 while read -r hash tag rest; do
 	if [ $tag != 'custom:' ]; then
 		git cherry-pick $hash || exit 1
 	fi
-done < <(git log --oneline --no-color master..hut)
+done < <(git log --oneline --no-color $MASTER_BRANCH..$CUSTOM_BRANCH)
 
-git checkout hut
-git rebase master
-
-git checkout $BRANCH
+git checkout $CUSTOM_BRANCH
+git rebase $MASTER_BRANCH
+git checkout $ORIGINAL_BRANCH