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

NAME

6       git-mergetool - Run merge conflict resolution tools to resolve merge
7       conflicts
8

SYNOPSIS

10       git mergetool [--tool=<tool>] [-y|--no-prompt|--prompt] [<file>]...
11

DESCRIPTION

13       Use git mergetool to run one of several merge utilities to resolve
14       merge conflicts. It is typically run after git merge.
15
16       If one or more <file> parameters are given, the merge tool program will
17       be run to resolve differences on each file. If no <file> names are
18       specified, git mergetool will run the merge tool program on every file
19       with merge conflicts.
20

OPTIONS

22       -t <tool>, --tool=<tool>
23           Use the merge resolution program specified by <tool>. Valid merge
24           tools are: kdiff3, tkdiff, meld, xxdiff, emerge, vimdiff, gvimdiff,
25           ecmerge, diffuse, tortoisemerge, opendiff, p4merge and araxis.
26
27           If a merge resolution program is not specified, git mergetool will
28           use the configuration variable merge.tool. If the configuration
29           variable merge.tool is not set, git mergetool will pick a suitable
30           default.
31
32           You can explicitly provide a full path to the tool by setting the
33           configuration variable mergetool.<tool>.path. For example, you can
34           configure the absolute path to kdiff3 by setting
35           mergetool.kdiff3.path. Otherwise, git mergetool assumes the tool is
36           available in PATH.
37
38           Instead of running one of the known merge tool programs, git
39           mergetool can be customized to run an alternative program by
40           specifying the command line to invoke in a configuration variable
41           mergetool.<tool>.cmd.
42
43           When git mergetool is invoked with this tool (either through the -t
44           or --tool option or the merge.tool configuration variable) the
45           configured command line will be invoked with $BASE set to the name
46           of a temporary file containing the common base for the merge, if
47           available; $LOCAL set to the name of a temporary file containing
48           the contents of the file on the current branch; $REMOTE set to the
49           name of a temporary file containing the contents of the file to be
50           merged, and $MERGED set to the name of the file to which the merge
51           tool should write the result of the merge resolution.
52
53           If the custom merge tool correctly indicates the success of a merge
54           resolution with its exit code, then the configuration variable
55           mergetool.<tool>.trustExitCode can be set to true. Otherwise, git
56           mergetool will prompt the user to indicate the success of the
57           resolution after the custom tool has exited.
58
59       -y, --no-prompt
60           Don’t prompt before each invocation of the merge resolution
61           program.
62
63       --prompt
64           Prompt before each invocation of the merge resolution program. This
65           is the default behaviour; the option is provided to override any
66           configuration settings.
67

AUTHOR

69       Written by Theodore Y Ts’o <tytso@mit.edu[1]>
70

DOCUMENTATION

72       Documentation by Theodore Y Ts’o.
73

GIT

75       Part of the git(1) suite
76

NOTES

78        1. tytso@mit.edu
79           mailto:tytso@mit.edu
80
81
82
83Git 1.7.1                         08/16/2017                  GIT-MERGETOOL(1)
Impressum