]> git.ipfire.org Git - thirdparty/git.git/blame - Documentation/git-revert.txt
Documentation/git-format-patch.txt: Add --signoff, --check, and long option-names.
[thirdparty/git.git] / Documentation / git-revert.txt
CommitLineData
215a7ad1
JH
1git-revert(1)
2=============
7fc9d69f
JH
3
4NAME
5----
215a7ad1 6git-revert - Revert an existing commit.
7fc9d69f
JH
7
8SYNOPSIS
9--------
8bf14d6e 10'git-revert' [--edit | --no-edit] [-n] <commit>
7fc9d69f
JH
11
12DESCRIPTION
13-----------
52a22d1e
LAS
14Given one existing commit, revert the change the patch introduces, and record a
15new commit that records it. This requires your working tree to be clean (no
16modifications from the HEAD commit).
7fc9d69f
JH
17
18OPTIONS
19-------
52a22d1e
LAS
20<commit>::
21 Commit to revert.
7fc9d69f 22
674b2808 23-e|--edit::
8bf14d6e
PB
24 With this option, `git-revert` will let you edit the commit
25 message prior committing the revert. This is the default if
26 you run the command from a terminal.
27
28--no-edit::
29 With this option, `git-revert` will not start the commit
30 message editor.
31
674b2808 32-n|--no-commit::
de2b82c6
JH
33 Usually the command automatically creates a commit with
34 a commit log message stating which commit was reverted.
35 This flag applies the change necessary to revert the
36 named commit to your working tree, but does not make the
37 commit. In addition, when this option is used, your
38 working tree does not have to match the HEAD commit.
39 The revert is done against the beginning state of your
40 working tree.
df8baa42
JF
41+
42This is useful when reverting more than one commits'
43effect to your working tree in a row.
de2b82c6
JH
44
45
7fc9d69f
JH
46Author
47------
48Written by Junio C Hamano <junkio@cox.net>
49
50Documentation
51--------------
52Documentation by Junio C Hamano and the git-list <git@vger.kernel.org>.
53
54GIT
55---
a7154e91 56Part of the gitlink:git[7] suite
7fc9d69f 57