]> asedeno.scripts.mit.edu Git - git.git/blobdiff - Documentation/git-am.txt
Documentation: mention ORIG_HEAD in am, merge, and rebase
[git.git] / Documentation / git-am.txt
index e640fc75cd3c463370f62b623a4060b014d9371a..88ca5f118340f37012c64c8c0395906ef1414894 100644 (file)
@@ -9,11 +9,11 @@ git-am - Apply a series of patches from a mailbox
 SYNOPSIS
 --------
 [verse]
-'git-am' [--signoff] [--dotest=<dir>] [--keep] [--utf8 | --no-utf8]
+'git am' [--signoff] [--keep] [--utf8 | --no-utf8]
          [--3way] [--interactive] [--binary]
          [--whitespace=<option>] [-C<n>] [-p<n>]
          <mbox>|<Maildir>...
-'git-am' [--skip | --resolved]
+'git am' [--skip | --resolved]
 
 DESCRIPTION
 -----------
@@ -28,19 +28,18 @@ OPTIONS
        supply this argument, reads from the standard input. If you supply
        directories, they'll be treated as Maildirs.
 
--s, --signoff::
+-s::
+--signoff::
        Add `Signed-off-by:` line to the commit message, using
        the committer identity of yourself.
 
--d=<dir>, --dotest=<dir>::
-       Instead of `.dotest` directory, use <dir> as a working
-       area to store extracted patches.
+-k::
+--keep::
+       Pass `-k` flag to 'git-mailinfo' (see linkgit:git-mailinfo[1]).
 
--k, --keep::
-       Pass `-k` flag to `git-mailinfo` (see linkgit:git-mailinfo[1]).
-
--u, --utf8::
-       Pass `-u` flag to `git-mailinfo` (see linkgit:git-mailinfo[1]).
+-u::
+--utf8::
+       Pass `-u` flag to 'git-mailinfo' (see linkgit:git-mailinfo[1]).
        The proposed commit log message taken from the e-mail
        is re-coded into UTF-8 encoding (configuration variable
        `i18n.commitencoding` can be used to specify project's
@@ -50,37 +49,42 @@ This was optional in prior versions of git, but now it is the
 default.   You could use `--no-utf8` to override this.
 
 --no-utf8::
-       Pass `-n` flag to `git-mailinfo` (see
+       Pass `-n` flag to 'git-mailinfo' (see
        linkgit:git-mailinfo[1]).
 
--3, --3way::
+-3::
+--3way::
        When the patch does not apply cleanly, fall back on
        3-way merge, if the patch records the identity of blobs
        it is supposed to apply to, and we have those blobs
        available locally.
 
--b, --binary::
-       Pass `--allow-binary-replacement` flag to `git-apply`
+-b::
+--binary::
+       Pass `--allow-binary-replacement` flag to 'git-apply'
        (see linkgit:git-apply[1]).
 
 --whitespace=<option>::
-       This flag is passed to the `git-apply` (see linkgit:git-apply[1])
+       This flag is passed to the 'git-apply' (see linkgit:git-apply[1])
        program that applies
        the patch.
 
--C<n>, -p<n>::
-       These flags are passed to the `git-apply` (see linkgit:git-apply[1])
+-C<n>::
+-p<n>::
+       These flags are passed to the 'git-apply' (see linkgit:git-apply[1])
        program that applies
        the patch.
 
--i, --interactive::
+-i::
+--interactive::
        Run interactively.
 
 --skip::
        Skip the current patch.  This is only meaningful when
        restarting an aborted patch.
 
--r, --resolved::
+-r::
+--resolved::
        After a patch failure (e.g. attempting to apply
        conflicting patch), the user has applied it by hand and
        the index file stores the result of the application.
@@ -93,7 +97,7 @@ default.   You could use `--no-utf8` to override this.
        to the screen before exiting.  This overrides the
        standard message informing you to use `--resolved`
        or `--skip` to handle the failure.  This is solely
-       for internal use between `git-rebase` and `git-am`.
+       for internal use between 'git-rebase' and 'git-am'.
 
 DISCUSSION
 ----------
@@ -141,6 +145,12 @@ directory exists, so if you decide to start over from scratch,
 run `rm -f -r .dotest` before running the command with mailbox
 names.
 
+Before any patches are applied, ORIG_HEAD is set to the tip of the
+current branch.  This is useful if you have problems with multiple
+commits, like running 'git am' on the wrong branch or an error in the
+commits that is more easily fixed by changing the mailbox (e.g.
+errors in the "From:" lines).
+
 
 SEE ALSO
 --------
@@ -157,4 +167,4 @@ Documentation by Petr Baudis, Junio C Hamano and the git-list <git@vger.kernel.o
 
 GIT
 ---
-Part of the linkgit:git[7] suite
+Part of the linkgit:git[1] suite