1
0
mirror of https://github.com/git/git.git synced 2024-09-28 12:21:46 +02:00
git/builtin
Elijah Newren 5291828df8 merge-ort: write $GIT_DIR/AUTO_MERGE whenever we hit a conflict
There are a variety of questions users might ask while resolving
conflicts:
  * What changes have been made since the previous (first) parent?
  * What changes are staged?
  * What is still unstaged? (or what is still conflicted?)
  * What changes did I make to resolve conflicts so far?
The first three of these have simple answers:
  * git diff HEAD
  * git diff --cached
  * git diff
There was no way to answer the final question previously.  Adding one
is trivial in merge-ort, since it works by creating a tree representing
what should be written to the working copy complete with conflict
markers.  Simply write that tree to .git/AUTO_MERGE, allowing users to
answer the fourth question with
  * git diff AUTO_MERGE

I avoided using a name like "MERGE_AUTO", because that would be
merge-specific (much like MERGE_HEAD, REBASE_HEAD, REVERT_HEAD,
CHERRY_PICK_HEAD) and I wanted a name that didn't change depending on
which type of operation the merge was part of.

Ensure that paths which clean out other temporary operation-specific
files (e.g. CHERRY_PICK_HEAD, MERGE_MSG, rebase-merge/ state directory)
also clean out this AUTO_MERGE file.

Signed-off-by: Elijah Newren <newren@gmail.com>
Reviewed-by: Derrick Stolee <dstolee@microsoft.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-03-20 12:35:40 -07:00
..
add.c
am.c
annotate.c
apply.c
archive.c
bisect--helper.c
blame.c
branch.c
bugreport.c
bundle.c
cat-file.c
check-attr.c
check-ignore.c
check-mailmap.c
check-ref-format.c
checkout-index.c
checkout.c
clean.c
clone.c
column.c
commit-graph.c
commit-tree.c
commit.c
config.c
count-objects.c
credential-cache--daemon.c
credential-cache.c
credential-store.c
credential.c
describe.c
diff-files.c
diff-index.c
diff-tree.c
diff.c
difftool.c
env--helper.c
fast-export.c
fast-import.c
fetch-pack.c
fetch.c
fmt-merge-msg.c
for-each-ref.c
for-each-repo.c
fsck.c
gc.c
get-tar-commit-id.c
grep.c
hash-object.c
help.c
index-pack.c
init-db.c
interpret-trailers.c
log.c
ls-files.c
ls-remote.c
ls-tree.c
mailinfo.c
mailsplit.c
merge-base.c
merge-file.c
merge-index.c
merge-ours.c
merge-recursive.c
merge-tree.c
merge.c
mktag.c
mktree.c
multi-pack-index.c
mv.c
name-rev.c
notes.c
pack-objects.c
pack-redundant.c
pack-refs.c
patch-id.c
prune-packed.c
prune.c
pull.c
push.c
range-diff.c
read-tree.c
rebase.c merge-ort: write $GIT_DIR/AUTO_MERGE whenever we hit a conflict 2021-03-20 12:35:40 -07:00
receive-pack.c
reflog.c
remote-ext.c
remote-fd.c
remote.c
repack.c
replace.c
rerere.c
reset.c
rev-list.c
rev-parse.c
revert.c
rm.c
send-pack.c
shortlog.c
show-branch.c
show-index.c
show-ref.c
sparse-checkout.c
stash.c
stripspace.c
submodule--helper.c
symbolic-ref.c
tag.c
unpack-file.c
unpack-objects.c
update-index.c
update-ref.c
update-server-info.c
upload-archive.c
upload-pack.c
var.c
verify-commit.c
verify-pack.c
verify-tag.c
worktree.c
write-tree.c