1 <?xml version="1.0" encoding="UTF-8"?>
\r
2 <!DOCTYPE sect2 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
\r
4 <sect2 lang="en" id="git-mergetool--lib(1)">
\r
5 <title>git-mergetool--lib(1)</title>
\r
7 <primary>git-mergetool--lib(1)</primary>
\r
9 <simplesect id="git-mergetool--lib(1)__name">
\r
11 <simpara>git-mergetool--lib - Common Git merge tool shell scriptlets</simpara>
\r
13 <simplesect id="git-mergetool--lib(1)__synopsis">
\r
14 <title>SYNOPSIS</title>
\r
16 <literallayout><emphasis>TOOL_MODE=(diff|merge) . "$(git --exec-path)/git-mergetool--lib"</emphasis></literallayout>
\r
19 <simplesect id="git-mergetool--lib(1)__description">
\r
20 <title>DESCRIPTION</title>
\r
21 <simpara>This is not a command the end user would want to run. Ever.
\r
22 This documentation is meant for people who are studying the
\r
23 Porcelain-ish scripts and/or are writing new ones.</simpara>
\r
24 <simpara>The <emphasis>git-mergetool--lib</emphasis> scriptlet is designed to be sourced (using
\r
25 <emphasis>.</emphasis>) by other shell scripts to set up functions for working
\r
26 with Git merge tools.</simpara>
\r
27 <simpara>Before sourcing <emphasis>git-mergetool--lib</emphasis>, your script must set <emphasis>TOOL_MODE</emphasis>
\r
28 to define the operation mode for the functions listed below.
\r
29 <emphasis>diff</emphasis> and <emphasis>merge</emphasis> are valid values.</simpara>
\r
31 <simplesect id="git-mergetool--lib(1)__functions">
\r
32 <title>FUNCTIONS</title>
\r
40 returns a merge tool.
\r
50 returns the custom command for a merge tool.
\r
60 returns the custom path for a merge tool.
\r
70 launches a merge tool given the tool name and a true/false
\r
71 flag to indicate whether a merge base is present.
\r
72 <emphasis>$MERGED</emphasis>, <emphasis>$LOCAL</emphasis>, <emphasis>$REMOTE</emphasis>, and <emphasis>$BASE</emphasis> must be defined
\r
73 for use by the merge tool.
\r
79 <simplesect id="git-mergetool--lib(1)__git">
\r
81 <simpara>Part of the <xref linkend="git(1)" /> suite</simpara>
\r