| author | Junio C Hamano <gitster@pobox.com> | |
| Fri, 29 Aug 2008 20:40:36 +0000 (13:40 -0700) | ||
| committer | Junio C Hamano <gitster@pobox.com> | |
| Sat, 30 Aug 2008 23:46:25 +0000 (16:46 -0700) | ||
| commit | 8fdcf3125465f70c0cad5be5ab192d46e46307c7 | |
| tree | 9146b01c85b07f5211eae66cf575d78dc69950ab | tree | snapshot |
| parent | 53d1589ff6bd336e3ece39e0a963a3d2a537cf96 | commit | diff |
checkout: do not check out unmerged higher stages randomly
During a conflicted merge when you have unmerged stages for a
path F in the index, if you said:
$ git checkout F
we rewrote F as many times as we have stages for it, and the
last one (typically "theirs") was left in the work tree, without
resolving the conflict.
This fixes it by noticing that a specified pathspec pattern
matches an unmerged path, and by erroring out.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
During a conflicted merge when you have unmerged stages for a
path F in the index, if you said:
$ git checkout F
we rewrote F as many times as we have stages for it, and the
last one (typically "theirs") was left in the work tree, without
resolving the conflict.
This fixes it by noticing that a specified pathspec pattern
matches an unmerged path, and by erroring out.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
| builtin-checkout.c | diff | blob | history | |
| t/t7201-co.sh | diff | blob | history |