summaryrefslogtreecommitdiff
path: root/t/t7111-reset-table.sh
diff options
context:
space:
mode:
authorChristian Couder <chriscool@tuxfamily.org>2010-01-19 04:26:01 (GMT)
committerJunio C Hamano <gitster@pobox.com>2010-03-07 04:06:50 (GMT)
commit812d2a3d61b1bbb1931aff2ed6d2a17e939f5bf2 (patch)
tree8a4b55f654c0b5f9fe4a4ebfd226e79b949df17d /t/t7111-reset-table.sh
parentab892a19e83edd1cf9a767bc09d3239f72469d05 (diff)
downloadgit-812d2a3d61b1bbb1931aff2ed6d2a17e939f5bf2.zip
git-812d2a3d61b1bbb1931aff2ed6d2a17e939f5bf2.tar.gz
git-812d2a3d61b1bbb1931aff2ed6d2a17e939f5bf2.tar.bz2
reset: disallow using --keep when there are unmerged entries
The use case for --keep option is to remove previous commits unrelated to the current changes in the working tree. So in this use case we are not supposed to have unmerged entries. This is why it seems safer to just disallow using --keep when there are unmerged entries. And this patch changes the error message when --keep was disallowed and there were some unmerged entries from: error: Entry 'file1' would be overwritten by merge. Cannot merge. fatal: Could not reset index file to revision 'HEAD^'. to: fatal: Cannot do a keep reset in the middle of a merge. which is nicer. Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7111-reset-table.sh')
-rwxr-xr-xt/t7111-reset-table.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t7111-reset-table.sh b/t/t7111-reset-table.sh
index 2ebda97..ce421ad 100755
--- a/t/t7111-reset-table.sh
+++ b/t/t7111-reset-table.sh
@@ -115,7 +115,7 @@ X U B B soft XXXXX
X U B B mixed X B B
X U B B hard B B B
X U B B merge B B B
-X U B B keep X B B
+X U B B keep XXXXX
EOF
test_done