summaryrefslogtreecommitdiff
path: root/Documentation/git-apply.txt
diff options
context:
space:
mode:
authorJohannes Schindelin <Johannes.Schindelin@gmx.de>2007-09-17 23:34:06 +0100
committerJunio C Hamano <gitster@pobox.com>2007-09-18 17:41:18 -0700
commit7a98869935a3682b5ff9679c92bf9bc12f87d8c5 (patch)
treef938e05dafa951d6f18ffb1f6f7c5ba1ffb46bd7 /Documentation/git-apply.txt
parent89df580d0a2e97b0c7c072d87e5e815534deed56 (diff)
downloadgit-7a98869935a3682b5ff9679c92bf9bc12f87d8c5.tar.gz
apply: get rid of --index-info in favor of --build-fake-ancestor
git-am used "git apply -z --index-info" to find the original versions of the files touched by the diff, to be able to do an inexpensive three-way merge. This operation makes only sense in a repository, since the index information in the diff refers to blobs, which have to be present in the current repository. Therefore, teach "git apply" a mode to write out the result as an index file to begin with, obviating the need for scripts to do it themselves. The sole user for --index-info is "git am" is converted to use --build-fake-ancestor in this patch. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/git-apply.txt')
-rw-r--r--Documentation/git-apply.txt11
1 files changed, 7 insertions, 4 deletions
diff --git a/Documentation/git-apply.txt b/Documentation/git-apply.txt
index 4c7e3a2f7f..c1c54bfe0b 100644
--- a/Documentation/git-apply.txt
+++ b/Documentation/git-apply.txt
@@ -10,7 +10,7 @@ SYNOPSIS
--------
[verse]
'git-apply' [--stat] [--numstat] [--summary] [--check] [--index]
- [--apply] [--no-add] [--index-info] [-R | --reverse]
+ [--apply] [--no-add] [--build-fake-ancestor <file>] [-R | --reverse]
[--allow-binary-replacement | --binary] [--reject] [-z]
[-pNUM] [-CNUM] [--inaccurate-eof] [--cached]
[--whitespace=<nowarn|warn|error|error-all|strip>]
@@ -63,12 +63,15 @@ OPTIONS
cached data, apply the patch, and store the result in the index,
without using the working tree. This implies '--index'.
---index-info::
+--build-fake-ancestor <file>::
Newer git-diff output has embedded 'index information'
for each blob to help identify the original version that
the patch applies to. When this flag is given, and if
- the original version of the blob is available locally,
- outputs information about them to the standard output.
+ the original versions of the blobs is available locally,
+ builds a temporary index containing those blobs.
++
+When a pure mode change is encountered (which has no index information),
+the information is read from the current index instead.
-R, --reverse::
Apply the patch in reverse.