9 echo >&2 "Syntax: $0 branch-list-delimited-by-dashes"
19 if git branch -D gerrit;then
21 git checkout -b gerrit
25 for elem in $(echo "$1"|tr '-' ' ');do
26 if [ "$base" = $origin ];then
32 git merge --no-edit "$base"
36 if [ -e "$next".patch ];then
37 echo -e '/^--- /,$d\nw'|ed "$next".patch || :
39 git diff "$base" "$next" --|diffdecvs >>"$next".patch
40 git diff -U9999999 --binary "$base" "$next" -- >"$next".Upatch
42 cp "$next".patch dashtopatch.patch
43 echo -e '/^--- /,$d\nw'|ed dashtopatch.patch
45 patch -p1 <"$next".patch
46 git commit -a -F dashtopatch.patch
47 rm -f dashtopatch.patch