]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Doit: allow private editions
authorJunio C Hamano <junio@twinsun.com>
Fri, 23 Jan 2009 18:36:53 +0000 (10:36 -0800)
committerJunio C Hamano <gitster@pobox.com>
Fri, 23 Jan 2009 18:41:41 +0000 (10:41 -0800)
Doit

diff --git a/Doit b/Doit
index 5a8645166879bcb74e3b7b619c3bacd804817265..74051e02d7ae13160aedfd4743891f4ecab8f8c0 100755 (executable)
--- a/Doit
+++ b/Doit
@@ -31,6 +31,9 @@ do
                continue
        }
 
+       private=$(git rev-parse -q --verify private-$branch 2>/dev/null)
+       case $? in 0|1) ;; *) exit $? ;; esac
+
        if      installed=$($HOME/git-$branch/bin/git version) &&
                if version=$(expr "$installed" : '.*\.g\([0-9a-f]*\)$')
                then
@@ -52,6 +55,18 @@ do
 
        echo "** $branch" &&
        git checkout $branch &&
+
+       case "$private" in
+       '')
+               ;;
+       ?*)
+               git merge --squash --no-commit "$private" || {
+                       echo >&2 "Cannot apply private edition changes"
+                       git reset --hard
+               }
+               ;;
+       esac &&
+
        Meta/Make $M -- $J clean &&
        case "$with_dash" in
        y)
@@ -63,6 +78,7 @@ do
                esac
                ;;
        esac &&
+
        Meta/Make $M -- $J all &&
        Meta/Make $M -- $J test &&
        case "$branch" in
@@ -78,6 +94,8 @@ do
        Meta/Make $M -- install &&
        Meta/Make clean || exit $?
 
+       git reset --hard
+
 done >./:all.log 3>&2 2>&1
 
 git checkout master