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
64 <term condition="pot">%bpath</term>
\r
67 Full path to the original file
\r
72 <term condition="pot">%ypath</term>
\r
75 Full path to your file
\r
80 <term condition="pot">%brev</term>
\r
83 The revision of the original file, if available
\r
88 <term condition="pot">%yrev</term>
\r
91 The revision of the second file, if available
\r
98 The window titles are not pure filenames.
\r
99 TortoiseGit treats that as a name to display and creates
\r
100 the names accordingly. So e.g. if you're doing a
\r
101 diff from a file in revision 123 with a file
\r
102 in your working tree, the names will be
\r
103 <filename>filename: revision 123</filename>
\r
105 <filename>filename: working tree</filename>
\r
108 For example, with ExamDiff Pro:
\r
110 C:\Path-To\ExamDiff.exe %base %mine --left_display_name:%bname
\r
111 --right_display_name:%yname
\r
115 C:\Path-To\kdiff3.exe %base %mine --L1 %bname --L2 %yname
\r
119 C:\Path-To\WinMerge.exe -e -ub -dl %bname -dr %yname %base %mine
\r
123 C:\Path-To\compare.exe /max /wait /title1:%bname /title2:%yname
\r
128 You can also specify a different diff tool to use on Git
\r
129 properties. Since these tend to be short simple text strings, you
\r
130 may want to use a simpler more compact viewer.
\r
133 If you have configured an alternate diff tool, you can access
\r
134 TortoiseMerge <emphasis>and</emphasis> the third party tool
\r
135 from the context menus.
\r
137 <guimenu>Context menu</guimenu>
\r
138 <guimenuitem>Diff</guimenuitem>
\r
140 uses the primary diff tool, and
\r
141 <keycap>Shift</keycap>+
\r
143 <guimenu>Context menu</guimenu>
\r
144 <guimenuitem>Diff</guimenuitem>
\r
146 uses the secondary diff tool.
\r
149 A viewer program for unified-diff files (GNU diff or patch files).
\r
150 No parameters are required.
\r
151 The <guilabel>Default</guilabel> option is to check for
\r
152 a file association for <filename>.diff</filename> files,
\r
153 and then for <filename>.txt</filename> files.
\r
154 If you don't have a viewer for <filename>.diff</filename>
\r
155 files, you will most likely get NotePad.
\r
158 The original Windows NotePad program does not behave
\r
159 well on files which do not have standard CR-LF
\r
160 line-endings. Since most unified diff files have pure
\r
161 LF line-endings, they do not view well in NotePad.
\r
162 However, you can use a free NotePad replacement
\r
163 <ulink url="http://www.flos-freeware.ch/notepad2.html">
\r
164 <citetitle>Notepad2</citetitle>
\r
165 </ulink> (this is also shipped with TortoiseGit)
\r
166 which not only displays the line-endings correctly,
\r
167 but also colour codes the added and removed lines.
\r
170 <sect3 id="tsvn-dug-settings-Merge">
\r
171 <title>Merge Tool</title>
\r
172 <?dbhh topicname="HIDD_SETTINGSPROGSMERGE"?>
\r
173 <figure id="tsvn-dug-settings-dia-5a">
\r
174 <title>The Settings Dialog, Merge Tool Page</title>
\r
175 <graphic fileref="../images/SettingsMergeTool.png"/>
\r
178 An external merge program used to resolve conflicted
\r
179 files. Parameter substitution is used in the same way
\r
180 as with the Diff Program.
\r
183 <term condition="pot">%base</term>
\r
186 the original file without your or
\r
192 <term condition="pot">%bname</term>
\r
195 The window title for the base file
\r
200 <term condition="pot">%mine</term>
\r
203 your own file, with your changes
\r
208 <term condition="pot">%yname</term>
\r
211 The window title for your file
\r
216 <term condition="pot">%theirs</term>
\r
219 the file as it is in the repository
\r
224 <term condition="pot">%tname</term>
\r
227 The window title for the file in the repository
\r
232 <term condition="pot">%merged</term>
\r
235 the conflicted file, the result of
\r
236 the merge operation
\r
241 <term condition="pot">%mname</term>
\r
244 The window title for the merged file
\r
251 For example, with Perforce Merge:
\r
253 C:\Path-To\P4Merge.exe %base %theirs %mine %merged
\r
257 C:\Path-To\kdiff3.exe %base %mine %theirs -o %merged
\r
258 --L1 %bname --L2 %yname --L3 %tname
\r
262 C:\Path-To\compare.exe /max /wait /3 /title1:%tname /title2:%bname
\r
263 /title3:%yname %theirs %base %mine %merged /a2
\r
265 or with WinMerge (2.8 or later):
\r
267 C:\Path-To\WinMerge.exe %merged
\r
271 <sect3 id="tsvn-dug-settings-Progs-Adv">
\r
272 <title>Diff/Merge Advanced Settings</title>
\r
273 <?dbhh topicname="HIDD_SETTINGSPROGSADV"?>
\r
275 <figure id="tsvn-dug-settings-dia-6">
\r
276 <title>The Settings Dialog, Diff/Merge Advanced Dialog</title>
\r
277 <graphic fileref="../images/SettingsProgsAdv.png"/>
\r
279 In the advanced settings, you can define a different diff and merge
\r
280 program for every file extension. For instance you could associate
\r
281 Photoshop as the <quote>Diff</quote> Program for <filename>.jpg</filename> files :-)
\r
284 To associate using a file extension, you need to specify the extension.
\r
285 Use <literal>.bmp</literal> to describe Windows bitmap files.
\r
288 <sect3 id="tsvn-dug-settings-alternativeeditor">
\r
289 <title>Alternative editor</title>
\r
290 <?dbhh topicname="HIDD_SETTINGSPROGSALTERNATIVEEDITOR"?>
\r
291 <figure id="tsvn-dug-settings-dia-6b">
\r
292 <title>The Settings Dialog, Alternative editor Page</title>
\r
293 <graphic fileref="../images/SettingsAlternativeEditor.png"/>
\r
296 The original Windows NotePad program does not behave
\r
297 well on files which do not have standard CR-LF
\r
298 line-endings. However, a lot of git configuration files do not have
\r
299 a standard CR-LF line-ending. Because of this TortoiseGit uses a free
\r
300 (shipped) NotePad replacement
\r
301 <ulink url="http://www.flos-freeware.ch/notepad2.html">
\r
302 <citetitle>Notepad2</citetitle>
\r
304 which displays the line-endings correctly by default.
\r