summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: e2f5f6e)
raw | patch | inline | side by side (parent: e2f5f6e)
author | Junio C Hamano <junkio@cox.net> | |
Sun, 25 Sep 2005 07:12:06 +0000 (00:12 -0700) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Tue, 27 Sep 2005 01:04:17 +0000 (18:04 -0700) |
Signed-off-by: Junio C Hamano <junkio@cox.net>
git-commit.sh | patch | blob | history | |
git-merge.sh | patch | blob | history |
diff --git a/git-commit.sh b/git-commit.sh
index d8bfc3c254929d3fb7a8aa702b4f4a86edefe8f0..9412840d8f2cc58b19d2ae3406396f2a271135d4 100755 (executable)
--- a/git-commit.sh
+++ b/git-commit.sh
esac
if [ -f "$GIT_DIR/MERGE_HEAD" ]; then
+
+ test -f "$GIT_DIR/MERGE_MSG" && cat "$GIT_DIR/MERGE_MSG"
+
echo "#"
echo "# It looks like your may be committing a MERGE."
echo "# If this is not correct, please remove the file"
diff --git a/git-merge.sh b/git-merge.sh
index 413bfcae9ffdf3d4545235e8000d8545e42e5384..7607e819c355fd30923c520b35ab4de7b918f013 100755 (executable)
--- a/git-merge.sh
+++ b/git-merge.sh
use_strategies=
dropsave() {
- rm -f -- "$GIT_DIR/MERGE_HEAD" \
+ rm -f -- "$GIT_DIR/MERGE_HEAD" "$GIT_DIR/MERGE_MSG" \
"$GIT_DIR/MERGE_SAVE" || exit 1
}
}
restorestate() {
- git reset --hard $head
- cpio -iuv <"$GIT_DIR/MERGE_SAVE"
- git-update-index --refresh >/dev/null
+ if test -f "$GIT_DIR/MERGE_SAVE"
+ then
+ git reset --hard $head
+ cpio -iuv <"$GIT_DIR/MERGE_SAVE"
+ git-update-index --refresh >/dev/null
+ fi
}
summary() {
single_strategy=no
;;
*)
+ rm -f "$GIT_DIR/MERGE_SAVE"
single_strategy=yes
;;
esac
do
echo $remote
done >"$GIT_DIR/MERGE_HEAD"
+echo $merge_msg >"$GIT_DIR/MERGE_MSG"
+
die "Automatic merge failed; fix up by hand"