X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=git-debpush;h=bd0357b5dc3a301979297023efc67dce5fb727e3;hb=f6f6419eca67882b47632875d2ee7163f4d005c7;hp=ca737d20a97fd341dff16a10d46329b62e60dfac;hpb=18328a4af50e91cc8899bb519548b505af548abe;p=dgit.git diff --git a/git-debpush b/git-debpush index ca737d20..bd0357b5 100755 --- a/git-debpush +++ b/git-debpush @@ -38,7 +38,8 @@ set -o pipefail # **** Helper functions and variables **** us="$(basename $0)" -git_playtree_create=git-playtree-create ###substituted### +git_playtree_setup=git-playtree-setup ###substituted### +git_playtree_setup=${DEBPUSH_GIT_PLAYTREE_SETUP-$git_playtree_setup} cleanup() { if [ -d "$temp" ]; then @@ -104,10 +105,15 @@ check_treesame () { shift 2 set +e - git diff --exit-code "$first".."$second" -- . "$@" + git diff --quiet --exit-code "$first".."$second" -- . "$@" git_diff_rc=$? set -e + # show the user what the difference was + if [ $git_diff_rc = 1 ]; then + git diff --compact-summary "$first".."$second" -- . "$@" + fi + if [ $git_diff_rc -le 1 ]; then return $git_diff_rc else @@ -245,9 +251,9 @@ case "$format" in '3.0 (quilt)') upstream=true ;; '3.0 (native)') upstream=false ;; '1.0'|'') - if get_file_from_ref debian/source/options | grep '^-sn *$'; then + if get_file_from_ref debian/source/options | grep -q '^-sn *$'; then upstream=false - elif get_file_from_ref debian/source/options | grep '^-sk *$'; then + elif get_file_from_ref debian/source/options | grep -q '^-sk *$'; then upstream=true else fail 'please see "SOURCE FORMAT 1.0" in git-debpush(1)' @@ -392,12 +398,13 @@ if [ "$format" = "3.0 (quilt)" ]; then fi fi -git tag "${git_tag_opts[@]}" -s -F- "$debian_tag" "$branch" <