X-Git-Url: http://git.jankratochvil.net/?p=nethome.git;a=blobdiff_plain;f=bin%2Fdashtopatch;h=a70dff1e5753b5b060b8f846817ca59c39e86348;hp=c1776e7919a7e39f933975afb3d1689d65201442;hb=f51a7283ffe021d8f9b3bfb14a9cedb37a7d15ca;hpb=5e237d2960760310b80ba965d7f2ca879db3d1e0 diff --git a/bin/dashtopatch b/bin/dashtopatch index c1776e7..a70dff1 100755 --- a/bin/dashtopatch +++ b/bin/dashtopatch @@ -12,7 +12,7 @@ fi if [ -f origin ];then origin="`cat origin`" else - origin="gdb/master" + origin="origin/master" fi base=$origin gerrit=true @@ -33,11 +33,13 @@ for elem in $(echo "$1"|tr '-' ' ');do if $compile;then make fi - if [ -e "$next".patch ];then - echo -e '/^--- /,$d\nw'|ed "$next".patch || : + if [ "$origin" != "master" ];then + if [ -e "$next".patch ];then + echo -e '/^--- /,$d\nw'|ed "$next".patch || : + fi + git diff "$base" "$next" --|diffdecvs >>"$next".patch + git diff -U9999999 --binary "$base" "$next" -- >"$next".Upatch fi - git diff "$base" "$next" --|diffdecvs >>"$next".patch - git diff -U9999999 --binary "$base" "$next" -- >"$next".Upatch if $gerrit;then cp "$next".patch dashtopatch.patch echo -e '/^--- /,$d\nw'|ed dashtopatch.patch