]> git.ipfire.org Git - thirdparty/git.git/blame - Documentation/git-diff-files.txt
t4034: abstract away SHA-1-specific constants
[thirdparty/git.git] / Documentation / git-diff-files.txt
CommitLineData
2cf565c5
DG
1git-diff-files(1)
2=================
2cf565c5
DG
3
4NAME
5----
5f3aa197 6git-diff-files - Compares files in the working tree and the index
2cf565c5
DG
7
8
9SYNOPSIS
10--------
7791a1d9 11[verse]
b1889c36 12'git diff-files' [-q] [-0|-1|-2|-3|-c|--cc] [<common diff options>] [<path>...]
2cf565c5
DG
13
14DESCRIPTION
15-----------
5f3aa197 16Compares the files in the working tree and the index. When paths
2cf565c5 17are specified, compares only those named paths. Otherwise all
5f3aa197 18entries in the index are compared. The output format is the
0b444cdb 19same as for 'git diff-index' and 'git diff-tree'.
2cf565c5
DG
20
21OPTIONS
22-------
dda2d79a 23include::diff-options.txt[]
2cf565c5 24
bf474e24
MH
25-1 --base::
26-2 --ours::
27-3 --theirs::
28-0::
10637b84
LT
29 Diff against the "base" version, "our branch" or "their
30 branch" respectively. With these options, diffs for
31 merged entries are not shown.
32+
a6080a0a 33The default is to diff against our branch (-2) and the
15bf57a1
JH
34cleanly resolved paths. The option -0 can be given to
35omit diff output for unmerged entries and just show "Unmerged".
10637b84 36
3240240f
SB
37-c::
38--cc::
34801cab
JH
39 This compares stage 2 (our branch), stage 3 (their
40 branch) and the working tree file and outputs a combined
41 diff, similar to the way 'diff-tree' shows a merge
42 commit with these flags.
43
2cf565c5 44-q::
addf88e4 45 Remain silent even on nonexistent files
2cf565c5 46
f552e51e 47
2cf565c5
DG
48include::diff-format.txt[]
49
2cf565c5
DG
50GIT
51---
9e1f0a85 52Part of the linkgit:git[1] suite