1 <?xml version="1.0" encoding="UTF-8"?>
\r
2 <!DOCTYPE sect2 SYSTEM "../../../dtd/dblite.dtd">
\r
3 <sect2 id="tsvn-dug-settings-progs">
\r
4 <title>External Program Settings</title>
\r
6 Here you can define your own programs that TortoiseGit
\r
7 should use. The default setting is to use tools
\r
8 which are installed alongside TortoiseGit.
\r
11 Read <xref linkend="tsvn-dug-diff-tools"/> for a list of some of the
\r
12 external diff/merge programs that people are using with TortoiseGit.
\r
14 <sect3 id="tsvn-dug-settings-Diff">
\r
15 <title>Diff Viewer</title>
\r
16 <?dbhh topicname="HIDD_SETTINGSPROGSDIFF"?>
\r
17 <figure id="tsvn-dug-settings-dia-5">
\r
18 <title>The Settings Dialog, Diff Viewer Page</title>
\r
19 <graphic fileref="../images/SettingsProgs.png"/>
\r
22 An external diff program may be used for comparing different
\r
23 revisions of files. The external program will need to
\r
24 obtain the filenames from the command line, along with
\r
25 any other command line options. TortoiseGit uses
\r
26 substitution parameters prefixed with <literal>%</literal>.
\r
27 When it encounters one of these it will substitute the
\r
28 appropriate value. The order of the parameters will depend
\r
29 on the Diff program you use.
\r
32 <term condition="pot">%base</term>
\r
35 The original file without your changes
\r
40 <term condition="pot">%bname</term>
\r
43 The window title for the base file
\r
48 <term condition="pot">%mine</term>
\r
51 Your own file, with your changes
\r
56 <term condition="pot">%yname</term>
\r
59 The window title for your file
\r
66 The window titles are not pure filenames.
\r
67 TortoiseGit treats that as a name to display and creates
\r
68 the names accordingly. So e.g. if you're doing a
\r
69 diff from a file in revision 123 with a file
\r
70 in your working tree, the names will be
\r
71 <filename>filename: revision 123</filename>
\r
73 <filename>filename: working tree</filename>
\r
76 For example, with ExamDiff Pro:
\r
78 C:\Path-To\ExamDiff.exe %base %mine --left_display_name:%bname
\r
79 --right_display_name:%yname
\r
83 C:\Path-To\kdiff3.exe %base %mine --L1 %bname --L2 %yname
\r
87 C:\Path-To\WinMerge.exe -e -ub -dl %bname -dr %yname %base %mine
\r
91 C:\Path-To\compare.exe /max /wait /title1:%bname /title2:%yname
\r
96 You can also specify a different diff tool to use on Git
\r
97 properties. Since these tend to be short simple text strings, you
\r
98 may want to use a simpler more compact viewer.
\r
101 If you have configured an alternate diff tool, you can access
\r
102 TortoiseMerge <emphasis>and</emphasis> the third party tool
\r
103 from the context menus.
\r
105 <guimenu>Context menu</guimenu>
\r
106 <guimenuitem>Diff</guimenuitem>
\r
108 uses the primary diff tool, and
\r
109 <keycap>Shift</keycap>+
\r
111 <guimenu>Context menu</guimenu>
\r
112 <guimenuitem>Diff</guimenuitem>
\r
114 uses the secondary diff tool.
\r
117 A viewer program for unified-diff files (GNU diff or patch files).
\r
118 No parameters are required.
\r
119 The <guilabel>Default</guilabel> option is to check for
\r
120 a file association for <filename>.diff</filename> files,
\r
121 and then for <filename>.txt</filename> files.
\r
122 If you don't have a viewer for <filename>.diff</filename>
\r
123 files, you will most likely get NotePad.
\r
126 The original Windows NotePad program does not behave
\r
127 well on files which do not have standard CR-LF
\r
128 line-endings. Since most unified diff files have pure
\r
129 LF line-endings, they do not view well in NotePad.
\r
130 However, you can use a free NotePad replacement
\r
131 <ulink url="http://www.flos-freeware.ch/notepad2.html">
\r
132 <citetitle>Notepad2</citetitle>
\r
133 </ulink> (this is also shipped with TortoiseGit)
\r
134 which not only displays the line-endings correctly,
\r
135 but also colour codes the added and removed lines.
\r
138 <sect3 id="tsvn-dug-settings-Merge">
\r
139 <title>Merge Tool</title>
\r
140 <?dbhh topicname="HIDD_SETTINGSPROGSMERGE"?>
\r
141 <figure id="tsvn-dug-settings-dia-5a">
\r
142 <title>The Settings Dialog, Merge Tool Page</title>
\r
143 <graphic fileref="../images/SettingsMergeTool.png"/>
\r
146 An external merge program used to resolve conflicted
\r
147 files. Parameter substitution is used in the same way
\r
148 as with the Diff Program.
\r
151 <term condition="pot">%base</term>
\r
154 the original file without your or
\r
160 <term condition="pot">%bname</term>
\r
163 The window title for the base file
\r
168 <term condition="pot">%mine</term>
\r
171 your own file, with your changes
\r
176 <term condition="pot">%yname</term>
\r
179 The window title for your file
\r
184 <term condition="pot">%theirs</term>
\r
187 the file as it is in the repository
\r
192 <term condition="pot">%tname</term>
\r
195 The window title for the file in the repository
\r
200 <term condition="pot">%merged</term>
\r
203 the conflicted file, the result of
\r
204 the merge operation
\r
209 <term condition="pot">%mname</term>
\r
212 The window title for the merged file
\r
219 For example, with Perforce Merge:
\r
221 C:\Path-To\P4Merge.exe %base %theirs %mine %merged
\r
225 C:\Path-To\kdiff3.exe %base %mine %theirs -o %merged
\r
226 --L1 %bname --L2 %yname --L3 %tname
\r
230 C:\Path-To\compare.exe /max /wait /3 /title1:%tname /title2:%bname
\r
231 /title3:%yname %theirs %base %mine %merged /a2
\r
233 or with WinMerge (2.8 or later):
\r
235 C:\Path-To\WinMerge.exe %merged
\r
239 <sect3 id="tsvn-dug-settings-Progs-Adv">
\r
240 <title>Diff/Merge Advanced Settings</title>
\r
241 <?dbhh topicname="HIDD_SETTINGSPROGSADV"?>
\r
243 <figure id="tsvn-dug-settings-dia-6">
\r
244 <title>The Settings Dialog, Diff/Merge Advanced Dialog</title>
\r
245 <graphic fileref="../images/SettingsProgsAdv.png"/>
\r
247 In the advanced settings, you can define a different diff and merge
\r
248 program for every file extension. For instance you could associate
\r
249 Photoshop as the <quote>Diff</quote> Program for <filename>.jpg</filename> files :-)
\r
252 To associate using a file extension, you need to specify the extension.
\r
253 Use <literal>.bmp</literal> to describe Windows bitmap files.
\r
256 <sect3 id="tsvn-dug-settings-alternativeeditor">
\r
257 <title>Alternative editor</title>
\r
258 <?dbhh topicname="HIDD_SETTINGSPROGSALTERNATIVEEDITOR"?>
\r
259 <figure id="tsvn-dug-settings-dia-6b">
\r
260 <title>The Settings Dialog, Alternative editor Page</title>
\r
261 <graphic fileref="../images/SettingsAlternativeEditor.png"/>
\r
264 The original Windows NotePad program does not behave
\r
265 well on files which do not have standard CR-LF
\r
266 line-endings. However, a lot of git configuration files do not have
\r
267 a standard CR-LF line-ending. Because of this TortoiseGit uses a free
\r
268 (shipped) NotePad replacement
\r
269 <ulink url="http://www.flos-freeware.ch/notepad2.html">
\r
270 <citetitle>Notepad2</citetitle>
\r
272 which displays the line-endings correctly by default.
\r