1GIT-DIFFTOOL(1)                   Git Manual                   GIT-DIFFTOOL(1)
2
3
4

NAME

6       git-difftool - Show changes using common diff tools
7

SYNOPSIS

9       git difftool [<options>] [<commit> [<commit>]] [--] [<path>...]
10
11

DESCRIPTION

13       git difftool is a Git command that allows you to compare and edit files
14       between revisions using common diff tools. git difftool is a frontend
15       to git diff and accepts the same options and arguments. See git-
16       diff(1).
17

OPTIONS

19       -d, --dir-diff
20           Copy the modified files to a temporary location and perform a
21           directory diff on them. This mode never prompts before launching
22           the diff tool.
23
24       -y, --no-prompt
25           Do not prompt before launching a diff tool.
26
27       --prompt
28           Prompt before each invocation of the diff tool. This is the default
29           behaviour; the option is provided to override any configuration
30           settings.
31
32       -t <tool>, --tool=<tool>
33           Use the diff tool specified by <tool>. Valid values include emerge,
34           kompare, meld, and vimdiff. Run git difftool --tool-help for the
35           list of valid <tool> settings.
36
37           If a diff tool is not specified, git difftool will use the
38           configuration variable diff.tool. If the configuration variable
39           diff.tool is not set, git difftool will pick a suitable default.
40
41           You can explicitly provide a full path to the tool by setting the
42           configuration variable difftool.<tool>.path. For example, you can
43           configure the absolute path to kdiff3 by setting
44           difftool.kdiff3.path. Otherwise, git difftool assumes the tool is
45           available in PATH.
46
47           Instead of running one of the known diff tools, git difftool can be
48           customized to run an alternative program by specifying the command
49           line to invoke in a configuration variable difftool.<tool>.cmd.
50
51           When git difftool is invoked with this tool (either through the -t
52           or --tool option or the diff.tool configuration variable) the
53           configured command line will be invoked with the following
54           variables available: $LOCAL is set to the name of the temporary
55           file containing the contents of the diff pre-image and $REMOTE is
56           set to the name of the temporary file containing the contents of
57           the diff post-image.  $MERGED is the name of the file which is
58           being compared.  $BASE is provided for compatibility with custom
59           merge tool commands and has the same value as $MERGED.
60
61       --tool-help
62           Print a list of diff tools that may be used with --tool.
63
64       --[no-]symlinks
65           git difftool's default behavior is create symlinks to the working
66           tree when run in --dir-diff mode and the right-hand side of the
67           comparison yields the same content as the file in the working tree.
68
69           Specifying --no-symlinks instructs git difftool to create copies
70           instead.  --no-symlinks is the default on Windows.
71
72       -x <command>, --extcmd=<command>
73           Specify a custom command for viewing diffs.  git-difftool ignores
74           the configured defaults and runs $command $LOCAL $REMOTE when this
75           option is specified. Additionally, $BASE is set in the environment.
76
77       -g, --gui
78           When git-difftool is invoked with the -g or --gui option the
79           default diff tool will be read from the configured diff.guitool
80           variable instead of diff.tool.
81
82       See git-diff(1) for the full list of supported options.
83

CONFIG VARIABLES

85       git difftool falls back to git mergetool config variables when the
86       difftool equivalents have not been defined.
87
88       diff.tool
89           The default diff tool to use.
90
91       diff.guitool
92           The default diff tool to use when --gui is specified.
93
94       difftool.<tool>.path
95           Override the path for the given tool. This is useful in case your
96           tool is not in the PATH.
97
98       difftool.<tool>.cmd
99           Specify the command to invoke the specified diff tool.
100
101           See the --tool=<tool> option above for more details.
102
103       difftool.prompt
104           Prompt before each invocation of the diff tool.
105

SEE ALSO

107       git-diff(1)
108           Show changes between commits, commit and working tree, etc
109
110       git-mergetool(1)
111           Run merge conflict resolution tools to resolve merge conflicts
112
113       git-config(1)
114           Get and set repository or global options
115

GIT

117       Part of the git(1) suite
118
119
120
121Git 1.8.3.1                       11/19/2018                   GIT-DIFFTOOL(1)
Impressum