Imported Upstream version 2.25.1
[platform/upstream/git.git] / Documentation / git-revert.txt
index b15139f..9d22270 100644 (file)
@@ -9,9 +9,7 @@ SYNOPSIS
 --------
 [verse]
 'git revert' [--[no-]edit] [-n] [-m parent-number] [-s] [-S[<keyid>]] <commit>...
-'git revert' --continue
-'git revert' --quit
-'git revert' --abort
+'git revert' (--continue | --skip | --abort | --quit)
 
 DESCRIPTION
 -----------
@@ -24,12 +22,15 @@ from the HEAD commit).
 Note: 'git revert' is used to record some new commits to reverse the
 effect of some earlier commits (often only a faulty one).  If you want to
 throw away all uncommitted changes in your working directory, you
-should see linkgit:git-reset[1], particularly the '--hard' option.  If
+should see linkgit:git-reset[1], particularly the `--hard` option.  If
 you want to extract specific files as they were in another commit, you
-should see linkgit:git-checkout[1], specifically the `git checkout
-<commit> -- <filename>` syntax.  Take care with these alternatives as
+should see linkgit:git-restore[1], specifically the `--source`
+option. Take care with these alternatives as
 both will discard uncommitted changes in your working directory.
 
+See "Reset, restore and revert" in linkgit:git[1] for the differences
+between the three commands.
+
 OPTIONS
 -------
 <commit>...::
@@ -37,7 +38,7 @@ OPTIONS
        For a more complete list of ways to spell commit names, see
        linkgit:gitrevisions[7].
        Sets of commits can also be given but no traversal is done by
-       default, see linkgit:git-rev-list[1] and its '--no-walk'
+       default, see linkgit:git-rev-list[1] and its `--no-walk`
        option.
 
 -e::
@@ -66,6 +67,13 @@ more details.
        With this option, 'git revert' will not start the commit
        message editor.
 
+--cleanup=<mode>::
+       This option determines how the commit message will be cleaned up before
+       being passed on to the commit machinery. See linkgit:git-commit[1] for more
+       details. In particular, if the '<mode>' is given a value of `scissors`,
+       scissors will be appended to `MERGE_MSG` before being passed on in the case
+       of a conflict.
+
 -n::
 --no-commit::
        Usually the command automatically creates some commits with
@@ -89,6 +97,7 @@ effect to your index in a row.
 -s::
 --signoff::
        Add Signed-off-by line at the end of the commit message.
+       See the signoff option in linkgit:git-commit[1] for more information.
 
 --strategy=<strategy>::
        Use the given merge strategy.  Should only be used once.
@@ -100,6 +109,11 @@ effect to your index in a row.
        Pass the merge strategy-specific option through to the
        merge strategy.  See linkgit:git-merge[1] for details.
 
+--rerere-autoupdate::
+--no-rerere-autoupdate::
+       Allow the rerere mechanism to update the index with the
+       result of auto-conflict resolution if possible.
+
 SEQUENCER SUBCOMMANDS
 ---------------------
 include::sequencer.txt[]