]> git.ipfire.org Git - thirdparty/git.git/blob - Documentation/git-diff-files.txt
Docs: Use "-l::\n--long\n" format in OPTIONS sections
[thirdparty/git.git] / Documentation / git-diff-files.txt
1 git-diff-files(1)
2 =================
3
4 NAME
5 ----
6 git-diff-files - Compares files in the working tree and the index
7
8
9 SYNOPSIS
10 --------
11 'git-diff-files' [-q] [-0|-1|-2|-3|-c|--cc] [<common diff options>] [<path>...]
12
13 DESCRIPTION
14 -----------
15 Compares the files in the working tree and the index. When paths
16 are specified, compares only those named paths. Otherwise all
17 entries in the index are compared. The output format is the
18 same as "git-diff-index" and "git-diff-tree".
19
20 OPTIONS
21 -------
22 include::diff-options.txt[]
23
24 -1 -2 -3 or --base --ours --theirs, and -0::
25 Diff against the "base" version, "our branch" or "their
26 branch" respectively. With these options, diffs for
27 merged entries are not shown.
28 +
29 The default is to diff against our branch (-2) and the
30 cleanly resolved paths. The option -0 can be given to
31 omit diff output for unmerged entries and just show "Unmerged".
32
33 -c::
34 --cc::
35 This compares stage 2 (our branch), stage 3 (their
36 branch) and the working tree file and outputs a combined
37 diff, similar to the way 'diff-tree' shows a merge
38 commit with these flags.
39
40 -q::
41 Remain silent even on nonexistent files
42
43 Output format
44 -------------
45 include::diff-format.txt[]
46
47
48 Author
49 ------
50 Written by Linus Torvalds <torvalds@osdl.org>
51
52 Documentation
53 --------------
54 Documentation by David Greaves, Junio C Hamano and the git-list <git@vger.kernel.org>.
55
56 GIT
57 ---
58 Part of the linkgit:git[1] suite