1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-11-17 06:25:13 +01:00
git/Documentation
Junio C Hamano 73eb40eeaa git-merge-file --ours, --theirs
Sometimes people want their conflicting merges autoresolved by
favouring upstream changes.  The standard answer they are given is
to run "git diff --name-only | xargs git checkout MERGE_HEAD --" in
such a case.  This is to accept automerge results for the paths that
are fully resolved automatically, while taking their version of the
file in full for paths that have conflicts.

This is problematic on two counts.

One is that this is not exactly what these people want.  It discards
all changes they did on their branch for any paths that conflicted.
They usually want to salvage as much automerge result as possible in
a conflicted file, and want to take the upstream change only in the
conflicted part.

This patch teaches two new modes of operation to the lowest-lever
merge machinery, xdl_merge().  Instead of leaving the conflicted
lines from both sides enclosed in <<<, ===, and >>> markers, the
conflicts are resolved favouring our side or their side of changes.

A larger problem is that this tends to encourage a bad workflow by
allowing people to record such a mixed up half-merged result as a
full commit without auditing.  This commit does not tackle this
issue at all.  In git, we usually give long enough rope to users
with strange wishes as long as the risky features are not enabled by
default, and this is such a risky feature.

Signed-off-by: Avery Pennarun <apenwarr@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-11-29 23:11:46 -08:00
..
howto Use 'fast-forward' all over the place 2009-10-24 23:50:28 -07:00
pt_BR Documentation: update pt-BR 2009-10-01 08:21:35 -04:00
technical Merge branch 'maint' 2009-11-22 19:04:30 -08:00
.gitattributes
.gitignore
asciidoc.conf
blame-options.txt
build-docdep.perl
cat-texi.perl
cmd-list.perl
CodingGuidelines
config.txt Merge branch 'mm/maint-hint-failed-merge' 2009-11-23 22:31:51 -08:00
diff-format.txt Update the documentation of the raw diff output format 2009-07-28 13:32:59 -07:00
diff-generate-patch.txt
diff-options.txt Fix over-simplified documentation for 'git log -z' 2009-11-23 01:21:51 -08:00
docbook-xsl.css
docbook.xsl
everyday.txt
fetch-options.txt builtin-fetch: add --dry-run option 2009-11-10 01:02:12 -08:00
fix-texi.perl
git-add.txt git-add.txt: fix formatting of --patch section 2009-11-14 00:26:37 -08:00
git-am.txt add documentation for mailinfo.scissors and '--no-scissors' 2009-09-11 00:23:07 -07:00
git-annotate.txt
git-apply.txt apply: Use the term "working tree" consistently 2009-11-22 12:08:08 -08:00
git-archimport.txt
git-archive.txt git-archive: infer output format from filename when unspecified 2009-09-13 13:54:39 -07:00
git-bisect.txt bisect reset: Allow resetting to any commit, not just a branch 2009-10-13 23:19:02 -07:00
git-blame.txt
git-branch.txt Documentation: clarify branch creation 2009-10-09 14:54:15 -07:00
git-bundle.txt
git-cat-file.txt
git-check-attr.txt
git-check-ref-format.txt Merge branch 'jn/show-normalized-refs' 2009-10-30 20:07:33 -07:00
git-checkout-index.txt
git-checkout.txt Merge branch 'tr/reset-checkout-patch' 2009-09-07 15:24:38 -07:00
git-cherry-pick.txt
git-cherry.txt
git-citool.txt
git-clean.txt UI consistency: allow --force for where -f means force 2009-08-29 14:08:03 -07:00
git-clone.txt git-clone.txt: Fix grammar and formatting 2009-10-21 17:16:08 -07:00
git-commit-tree.txt
git-commit.txt add -i, send-email, svn, p4, etc: use "git var GIT_EDITOR" 2009-11-13 12:20:50 -08:00
git-config.txt
git-count-objects.txt
git-cvsexportcommit.txt
git-cvsimport.txt
git-cvsserver.txt cvsserver doc: database generally can not be reproduced consistently 2009-11-22 22:56:32 -08:00
git-daemon.txt
git-describe.txt git-describe.txt: formatting fix 2009-11-10 14:06:41 -08:00
git-diff-files.txt Update the documentation of the raw diff output format 2009-07-28 13:32:59 -07:00
git-diff-index.txt Update the documentation of the raw diff output format 2009-07-28 13:32:59 -07:00
git-diff-tree.txt Update the documentation of the raw diff output format 2009-07-28 13:32:59 -07:00
git-diff.txt Update the documentation of the raw diff output format 2009-07-28 13:32:59 -07:00
git-difftool.txt mergetool--lib: add p4merge as a pre-configured mergetool option 2009-10-28 16:48:20 -07:00
git-fast-export.txt git fast-export: add --no-data option 2009-07-31 07:48:09 -07:00
git-fast-import.txt fast-import: Add support for importing commit notes 2009-10-19 19:00:24 -07:00
git-fetch-pack.txt
git-fetch.txt Merge branch 'bg/fetch-multi' 2009-11-23 00:03:15 -08:00
git-filter-branch.txt filter-branch: nearest-ancestor rewriting outside subdir filter 2009-11-13 11:26:43 -08:00
git-fmt-merge-msg.txt Documentation: git fmt-merge-msg does not have to be a script 2009-10-09 14:40:25 -07:00
git-for-each-ref.txt
git-format-patch.txt format-patch documentation: Fix formatting 2009-11-10 11:38:21 -08:00
git-fsck-objects.txt
git-fsck.txt fsck: default to "git fsck --full" 2009-10-20 12:11:39 -07:00
git-gc.txt Documentation/git-gc.txt: change "references" to "reference" 2009-10-20 00:01:23 -07:00
git-get-tar-commit-id.txt
git-grep.txt grep: Add --max-depth option. 2009-07-22 21:54:54 -07:00
git-gui.txt
git-hash-object.txt
git-help.txt
git-http-backend.txt http-backend: Use http.getanyfile to disable dumb HTTP serving 2009-11-04 17:58:16 -08:00
git-http-fetch.txt
git-http-push.txt Use 'fast-forward' all over the place 2009-10-24 23:50:28 -07:00
git-imap-send.txt
git-index-pack.txt
git-init-db.txt init-db: migrate to parse-options 2009-07-12 14:36:40 -07:00
git-init.txt git init: optionally allow a directory argument 2009-07-25 02:17:54 -07:00
git-instaweb.txt Add support for the Mongoose web server. 2009-08-23 15:03:53 -07:00
git-log.txt git-log: allow --decorate[=short|full] 2009-08-26 12:05:58 -07:00
git-lost-found.txt
git-ls-files.txt Merge branch 'jk/maint-1.6.3-ls-files-i' into maint 2009-11-15 23:07:32 -08:00
git-ls-remote.txt
git-ls-tree.txt
git-mailinfo.txt add documentation for mailinfo.scissors and '--no-scissors' 2009-09-11 00:23:07 -07:00
git-mailsplit.txt
git-merge-base.txt git-merge-base/git-show-branch --merge-base: Documentation and test 2009-08-05 10:29:37 -07:00
git-merge-file.txt git-merge-file --ours, --theirs 2009-11-29 23:11:46 -08:00
git-merge-index.txt
git-merge-one-file.txt
git-merge-tree.txt
git-merge.txt modernize fetch/merge/pull examples 2009-10-21 14:20:50 -07:00
git-mergetool--lib.txt
git-mergetool.txt mergetool--lib: add p4merge as a pre-configured mergetool option 2009-10-28 16:48:20 -07:00
git-mktag.txt
git-mktree.txt
git-mv.txt UI consistency: allow --force for where -f means force 2009-08-29 14:08:03 -07:00
git-name-rev.txt
git-notes.txt Teach "-m <msg>" and "-F <file>" to "git notes edit" 2009-10-19 18:59:43 -07:00
git-pack-objects.txt pack-objects: split implications of --all-progress from progress activation 2009-11-23 21:33:09 -08:00
git-pack-redundant.txt
git-pack-refs.txt
git-parse-remote.txt
git-patch-id.txt
git-peek-remote.txt
git-prune-packed.txt prune-packed: migrate to parse-options 2009-07-10 23:57:21 -07:00
git-prune.txt
git-pull.txt Merge branch 'ja/fetch-doc' into maint 2009-11-15 16:38:18 -08:00
git-push.txt Merge branch 'fc/doc-fast-forward' 2009-11-15 16:41:02 -08:00
git-quiltimport.txt quiltimport documentation: --dry-run and -n are synonyms 2009-09-13 01:32:49 -07:00
git-read-tree.txt Use 'fast-forward' all over the place 2009-10-24 23:50:28 -07:00
git-rebase.txt Merge branch 'tr/maint-merge-ours-clarification' (early part) 2009-11-22 16:28:06 -08:00
git-receive-pack.txt Use 'fast-forward' all over the place 2009-10-24 23:50:28 -07:00
git-reflog.txt
git-relink.txt
git-remote-helpers.txt Move WebDAV HTTP push under remote-curl 2009-10-30 19:20:54 -07:00
git-remote.txt git remote: Separate usage strings for subcommands 2009-11-20 22:15:30 -08:00
git-repack.txt
git-replace.txt Documentation: talk a little bit about GIT_NO_REPLACE_OBJECTS 2009-11-20 22:08:11 -08:00
git-repo-config.txt
git-request-pull.txt
git-rerere.txt git-rerere.txt: Clarify ambiguity of the config variable 2009-07-28 13:30:42 -07:00
git-reset.txt Use 'fast-forward' all over the place 2009-10-24 23:50:28 -07:00
git-rev-list.txt Merge branch 'maint' 2009-08-12 16:36:04 -07:00
git-rev-parse.txt
git-revert.txt
git-rm.txt
git-send-email.txt add -i, send-email, svn, p4, etc: use "git var GIT_EDITOR" 2009-11-13 12:20:50 -08:00
git-send-pack.txt Use 'fast-forward' all over the place 2009-10-24 23:50:28 -07:00
git-sh-setup.txt
git-shell.txt
git-shortlog.txt
git-show-branch.txt git-merge-base/git-show-branch --merge-base: Documentation and test 2009-08-05 10:29:37 -07:00
git-show-index.txt
git-show-ref.txt Show usage string for 'git show-ref -h' 2009-11-09 17:08:53 -08:00
git-show.txt
git-stage.txt
git-stash.txt stash list: drop the default limit of 10 stashes 2009-10-19 22:28:26 -07:00
git-status.txt
git-stripspace.txt
git-submodule.txt git submodule add: make the <path> parameter optional 2009-09-22 12:24:49 -07:00
git-svn.txt Document git-svn's first-parent rule 2009-11-16 23:33:58 -08:00
git-symbolic-ref.txt Fix typos in git-remote.txt and git-symbolic-ref.txt 2009-08-10 19:05:00 -07:00
git-tag.txt UI consistency: allow --force for where -f means force 2009-08-29 14:08:03 -07:00
git-tar-tree.txt
git-tools.txt
git-unpack-file.txt
git-unpack-objects.txt
git-update-index.txt git-update-index.txt: Document the --really-refresh option. 2009-11-10 10:38:13 -08:00
git-update-ref.txt
git-update-server-info.txt
git-upload-archive.txt
git-upload-pack.txt upload-pack: add a trigger for post-upload-pack hook 2009-08-28 22:39:17 -07:00
git-var.txt Teach git var about GIT_PAGER 2009-11-13 12:20:47 -08:00
git-verify-pack.txt verify-pack --stat-only: show histogram without verifying 2009-08-07 20:45:31 -07:00
git-verify-tag.txt
git-web--browse.txt
git-whatchanged.txt
git-write-tree.txt Minor improvement to the write-tree documentation 2009-08-26 12:05:58 -07:00
git.txt Sync with 1.6.5.3 2009-11-16 00:06:30 -08:00
gitattributes.txt Document delta attribute in "git help attributes". 2009-10-21 14:07:44 -07:00
gitcli.txt Update "describe" documentation to match reality 2009-09-22 19:40:05 -07:00
gitcore-tutorial.txt t1200: fix a timing dependent error 2009-11-25 00:00:32 -08:00
gitcvs-migration.txt
gitdiffcore.txt
gitglossary.txt
githooks.txt Use 'fast-forward' all over the place 2009-10-24 23:50:28 -07:00
gitignore.txt
gitk.txt
gitmodules.txt
gitrepository-layout.txt
gittutorial-2.txt
gittutorial.txt
gitworkflows.txt gitworkflows: Consistently back-quote git commands 2009-11-26 18:33:34 -08:00
glossary-content.txt Use 'fast-forward' all over the place 2009-10-24 23:50:28 -07:00
howto-index.sh
i18n.txt
install-doc-quick.sh
install-webdoc.sh
mailmap.txt
Makefile Merge branch 'tr/maint-roff-quote' into maint 2009-11-15 16:38:36 -08:00
manpage-1.72.xsl
manpage-base.xsl
manpage-bold-literal.xsl
manpage-normal.xsl
manpage-quote-apos.xsl Quote ' as \(aq in manpages 2009-10-22 12:59:50 -07:00
manpage-suppress-sp.xsl
merge-config.txt mergetool--lib: add p4merge as a pre-configured mergetool option 2009-10-28 16:48:20 -07:00
merge-options.txt Merge branch 'bg/merge-ff-only' 2009-11-10 12:32:59 -08:00
merge-strategies.txt Documentation: clarify 'ours' merge strategy 2009-11-15 12:26:08 -08:00
pretty-formats.txt strbuf_add_wrapped_text(): skip over colour codes 2009-11-23 15:36:07 -08:00
pretty-options.txt
pull-fetch-param.txt Merge branch 'bg/fetch-multi' 2009-11-23 00:03:15 -08:00
RelNotes-1.5.0.1.txt
RelNotes-1.5.0.2.txt
RelNotes-1.5.0.3.txt
RelNotes-1.5.0.4.txt
RelNotes-1.5.0.5.txt
RelNotes-1.5.0.6.txt
RelNotes-1.5.0.7.txt
RelNotes-1.5.0.txt
RelNotes-1.5.1.1.txt
RelNotes-1.5.1.2.txt
RelNotes-1.5.1.3.txt
RelNotes-1.5.1.4.txt
RelNotes-1.5.1.5.txt
RelNotes-1.5.1.6.txt
RelNotes-1.5.1.txt
RelNotes-1.5.2.1.txt
RelNotes-1.5.2.2.txt
RelNotes-1.5.2.3.txt
RelNotes-1.5.2.4.txt
RelNotes-1.5.2.5.txt
RelNotes-1.5.2.txt
RelNotes-1.5.3.1.txt
RelNotes-1.5.3.2.txt
RelNotes-1.5.3.3.txt
RelNotes-1.5.3.4.txt
RelNotes-1.5.3.5.txt
RelNotes-1.5.3.6.txt
RelNotes-1.5.3.7.txt
RelNotes-1.5.3.8.txt
RelNotes-1.5.3.txt
RelNotes-1.5.4.1.txt
RelNotes-1.5.4.2.txt
RelNotes-1.5.4.3.txt
RelNotes-1.5.4.4.txt
RelNotes-1.5.4.5.txt
RelNotes-1.5.4.6.txt
RelNotes-1.5.4.7.txt
RelNotes-1.5.4.txt
RelNotes-1.5.5.1.txt
RelNotes-1.5.5.2.txt
RelNotes-1.5.5.3.txt
RelNotes-1.5.5.4.txt
RelNotes-1.5.5.5.txt
RelNotes-1.5.5.6.txt
RelNotes-1.5.5.txt
RelNotes-1.5.6.1.txt
RelNotes-1.5.6.2.txt
RelNotes-1.5.6.3.txt
RelNotes-1.5.6.4.txt
RelNotes-1.5.6.5.txt
RelNotes-1.5.6.6.txt
RelNotes-1.5.6.txt
RelNotes-1.6.0.1.txt
RelNotes-1.6.0.2.txt
RelNotes-1.6.0.3.txt
RelNotes-1.6.0.4.txt
RelNotes-1.6.0.5.txt
RelNotes-1.6.0.6.txt
RelNotes-1.6.0.txt
RelNotes-1.6.1.1.txt
RelNotes-1.6.1.2.txt
RelNotes-1.6.1.3.txt
RelNotes-1.6.1.4.txt
RelNotes-1.6.1.txt
RelNotes-1.6.2.1.txt
RelNotes-1.6.2.2.txt
RelNotes-1.6.2.3.txt
RelNotes-1.6.2.4.txt
RelNotes-1.6.2.5.txt
RelNotes-1.6.2.txt
RelNotes-1.6.3.1.txt
RelNotes-1.6.3.2.txt
RelNotes-1.6.3.3.txt
RelNotes-1.6.3.4.txt GIT 1.6.3.4 2009-07-28 23:59:30 -07:00
RelNotes-1.6.3.txt
RelNotes-1.6.4.1.txt GIT 1.6.4.1 2009-08-21 20:16:10 -07:00
RelNotes-1.6.4.2.txt GIT 1.6.4.2 2009-08-29 14:31:01 -07:00
RelNotes-1.6.4.3.txt GIT 1.6.4.3 2009-09-13 01:28:13 -07:00
RelNotes-1.6.4.4.txt GIT 1.6.4.4 2009-09-16 14:53:26 -07:00
RelNotes-1.6.4.txt GIT 1.6.4 2009-07-29 00:32:42 -07:00
RelNotes-1.6.5.1.txt GIT 1.6.5.1 2009-10-16 23:57:19 -07:00
RelNotes-1.6.5.2.txt GIT 1.6.5.2 2009-10-25 18:37:56 -07:00
RelNotes-1.6.5.3.txt Git 1.6.5.3 2009-11-16 00:05:12 -08:00
RelNotes-1.6.5.txt GIT 1.6.5 2009-10-10 00:05:19 -07:00
RelNotes-1.6.6.txt Update draft release notes to 1.6.6 before merging topics for -rc1 2009-11-28 11:13:59 -08:00
rev-list-options.txt Documentation: update descriptions of revision options related to '--bisect' 2009-11-24 01:00:34 -08:00
SubmittingPatches
urls-remotes.txt
urls.txt Add url.<base>.pushInsteadOf: URL rewriting for push only 2009-09-08 01:18:46 -07:00
user-manual.conf
user-manual.txt Merge branch 'mm/maint-hint-failed-merge' 2009-11-23 22:31:51 -08:00