TODO updates
[git.git] / PU
diff --git a/PU b/PU
index 7af28ac..2124b05 100755 (executable)
--- a/PU
+++ b/PU
@@ -51,21 +51,22 @@ case "$#" in
                        break ;;
                esac
                I=0
-               UNUSE=
-               USE=
+               UNUSE= USE= USED=
                for H in $HH
                do
                        I=$(($I+1))
                        case " $ans " in
                        *' '$I' '*)
                                USE="$USE$H "
+                               USED="$USED,$H"
                                ;;
                        *)
                                UNUSE="$UNUSE$H "
                                ;;
                        esac
                done
-               git pull -n . $USE || exit
+               USED=`expr "$USED" : ',\(.*\)'`
+               git merge -n "Merge $USED" pu $USE || exit
                HH=$UNUSE
        done
        exit
@@ -74,7 +75,7 @@ esac
 
 for H
 do
-       (IFS=",$IFS"; git pull -n . $H) || exit
+       (IFS=",$IFS"; git merge -n "Merge $H" pu $H) || exit
 done
 
-(IFS=",$IFS"; git show-branch master pu $* $ORIG_HEAD)
+(IFS=",$IFS"; git show-branch master $* pu `git rev-parse --short $ORIG_HEAD`)