##// END OF EJS Templates
hgrc.5: mark more inline literals
Martin Geisler -
r9746:2dee9a35 default
parent child Browse files
Show More
@@ -1,955 +1,955 b''
1 ======
1 ======
2 hgrc
2 hgrc
3 ======
3 ======
4
4
5 ---------------------------------
5 ---------------------------------
6 configuration files for Mercurial
6 configuration files for Mercurial
7 ---------------------------------
7 ---------------------------------
8
8
9 :Author: Bryan O'Sullivan <bos@serpentine.com>
9 :Author: Bryan O'Sullivan <bos@serpentine.com>
10 :Organization: Mercurial
10 :Organization: Mercurial
11 :Manual section: 5
11 :Manual section: 5
12 :Manual group: Mercurial Manual
12 :Manual group: Mercurial Manual
13
13
14 .. contents::
14 .. contents::
15 :backlinks: top
15 :backlinks: top
16 :class: htmlonly
16 :class: htmlonly
17
17
18
18
19 SYNOPSIS
19 SYNOPSIS
20 --------
20 --------
21
21
22 The Mercurial system uses a set of configuration files to control
22 The Mercurial system uses a set of configuration files to control
23 aspects of its behavior.
23 aspects of its behavior.
24
24
25 FILES
25 FILES
26 -----
26 -----
27
27
28 Mercurial reads configuration data from several files, if they exist.
28 Mercurial reads configuration data from several files, if they exist.
29 The names of these files depend on the system on which Mercurial is
29 The names of these files depend on the system on which Mercurial is
30 installed. ``*.rc`` files from a single directory are read in
30 installed. ``*.rc`` files from a single directory are read in
31 alphabetical order, later ones overriding earlier ones. Where multiple
31 alphabetical order, later ones overriding earlier ones. Where multiple
32 paths are given below, settings from earlier paths override later
32 paths are given below, settings from earlier paths override later
33 ones.
33 ones.
34
34
35 | (Unix, Windows) ``<repo>/.hg/hgrc``
35 | (Unix, Windows) ``<repo>/.hg/hgrc``
36
36
37 Per-repository configuration options that only apply in a
37 Per-repository configuration options that only apply in a
38 particular repository. This file is not version-controlled, and
38 particular repository. This file is not version-controlled, and
39 will not get transferred during a "clone" operation. Options in
39 will not get transferred during a "clone" operation. Options in
40 this file override options in all other configuration files. On
40 this file override options in all other configuration files. On
41 Unix, most of this file will be ignored if it doesn't belong to a
41 Unix, most of this file will be ignored if it doesn't belong to a
42 trusted user or to a trusted group. See the documentation for the
42 trusted user or to a trusted group. See the documentation for the
43 trusted_ section below for more details.
43 trusted_ section below for more details.
44
44
45 | (Unix) ``$HOME/.hgrc``
45 | (Unix) ``$HOME/.hgrc``
46 | (Windows) ``%USERPROFILE%\.hgrc``
46 | (Windows) ``%USERPROFILE%\.hgrc``
47 | (Windows) ``%USERPROFILE%\Mercurial.ini``
47 | (Windows) ``%USERPROFILE%\Mercurial.ini``
48 | (Windows) ``%HOME%\.hgrc``
48 | (Windows) ``%HOME%\.hgrc``
49 | (Windows) ``%HOME%\Mercurial.ini``
49 | (Windows) ``%HOME%\Mercurial.ini``
50
50
51 Per-user configuration file(s), for the user running Mercurial. On
51 Per-user configuration file(s), for the user running Mercurial. On
52 Windows 9x, ``%HOME%`` is replaced by ``%APPDATA%``. Options in these
52 Windows 9x, ``%HOME%`` is replaced by ``%APPDATA%``. Options in these
53 files apply to all Mercurial commands executed by this user in any
53 files apply to all Mercurial commands executed by this user in any
54 directory. Options in these files override per-system and per-installation
54 directory. Options in these files override per-system and per-installation
55 options.
55 options.
56
56
57 | (Unix) ``/etc/mercurial/hgrc``
57 | (Unix) ``/etc/mercurial/hgrc``
58 | (Unix) ``/etc/mercurial/hgrc.d/*.rc``
58 | (Unix) ``/etc/mercurial/hgrc.d/*.rc``
59
59
60 Per-system configuration files, for the system on which Mercurial
60 Per-system configuration files, for the system on which Mercurial
61 is running. Options in these files apply to all Mercurial commands
61 is running. Options in these files apply to all Mercurial commands
62 executed by any user in any directory. Options in these files
62 executed by any user in any directory. Options in these files
63 override per-installation options.
63 override per-installation options.
64
64
65 | (Unix) ``<install-root>/etc/mercurial/hgrc``
65 | (Unix) ``<install-root>/etc/mercurial/hgrc``
66 | (Unix) ``<install-root>/etc/mercurial/hgrc.d/*.rc``
66 | (Unix) ``<install-root>/etc/mercurial/hgrc.d/*.rc``
67
67
68 Per-installation configuration files, searched for in the
68 Per-installation configuration files, searched for in the
69 directory where Mercurial is installed. ``<install-root>`` is the
69 directory where Mercurial is installed. ``<install-root>`` is the
70 parent directory of the **hg** executable (or symlink) being run. For
70 parent directory of the **hg** executable (or symlink) being run. For
71 example, if installed in ``/shared/tools/bin/hg``, Mercurial will look
71 example, if installed in ``/shared/tools/bin/hg``, Mercurial will look
72 in ``/shared/tools/etc/mercurial/hgrc``. Options in these files apply
72 in ``/shared/tools/etc/mercurial/hgrc``. Options in these files apply
73 to all Mercurial commands executed by any user in any directory.
73 to all Mercurial commands executed by any user in any directory.
74
74
75 | (Windows) ``C:\Mercurial\Mercurial.ini``
75 | (Windows) ``C:\Mercurial\Mercurial.ini``
76 | (Windows) ``HKEY_LOCAL_MACHINE\SOFTWARE\Mercurial``
76 | (Windows) ``HKEY_LOCAL_MACHINE\SOFTWARE\Mercurial``
77 | (Windows) ``<install-dir>\Mercurial.ini``
77 | (Windows) ``<install-dir>\Mercurial.ini``
78
78
79 Per-installation/system configuration files, for the system on
79 Per-installation/system configuration files, for the system on
80 which Mercurial is running. Options in these files apply to all
80 which Mercurial is running. Options in these files apply to all
81 Mercurial commands executed by any user in any directory. Registry
81 Mercurial commands executed by any user in any directory. Registry
82 keys contain PATH-like strings, every part of which must reference
82 keys contain PATH-like strings, every part of which must reference
83 a ``Mercurial.ini`` file or be a directory where ``*.rc`` files will
83 a ``Mercurial.ini`` file or be a directory where ``*.rc`` files will
84 be read.
84 be read.
85
85
86 SYNTAX
86 SYNTAX
87 ------
87 ------
88
88
89 A configuration file consists of sections, led by a ``[section]`` header
89 A configuration file consists of sections, led by a ``[section]`` header
90 and followed by ``name: value`` entries; ``name=value`` is also accepted.
90 and followed by ``name: value`` entries; ``name=value`` is also accepted.
91
91
92 ::
92 ::
93
93
94 [spam]
94 [spam]
95 eggs=ham
95 eggs=ham
96 green=
96 green=
97 eggs
97 eggs
98
98
99 Each line contains one entry. If the lines that follow are indented,
99 Each line contains one entry. If the lines that follow are indented,
100 they are treated as continuations of that entry. Leading whitespace is
100 they are treated as continuations of that entry. Leading whitespace is
101 removed from values. Empty lines are skipped. Lines beginning with
101 removed from values. Empty lines are skipped. Lines beginning with
102 ``#`` or ``;`` are ignored and may be used to provide comments.
102 ``#`` or ``;`` are ignored and may be used to provide comments.
103
103
104 A line of the form ``%include file`` will include ``file`` into the
104 A line of the form ``%include file`` will include ``file`` into the
105 current configuration file. The inclusion is recursive, which means
105 current configuration file. The inclusion is recursive, which means
106 that included files can include other files. Filenames are relative to
106 that included files can include other files. Filenames are relative to
107 the configuration file in which the ``%include`` directive is found.
107 the configuration file in which the ``%include`` directive is found.
108
108
109 A line with ``%unset name`` will remove ``name`` from the current
109 A line with ``%unset name`` will remove ``name`` from the current
110 section, if it has been set previously.
110 section, if it has been set previously.
111
111
112
112
113 SECTIONS
113 SECTIONS
114 --------
114 --------
115
115
116 This section describes the different sections that may appear in a
116 This section describes the different sections that may appear in a
117 Mercurial "hgrc" file, the purpose of each section, its possible keys,
117 Mercurial "hgrc" file, the purpose of each section, its possible keys,
118 and their possible values.
118 and their possible values.
119
119
120 ``alias``
120 ``alias``
121 """""""""
121 """""""""
122 Defines command aliases.
122 Defines command aliases.
123 Aliases allow you to define your own commands in terms of other
123 Aliases allow you to define your own commands in terms of other
124 commands (or aliases), optionally including arguments.
124 commands (or aliases), optionally including arguments.
125
125
126 Alias definitions consist of lines of the form::
126 Alias definitions consist of lines of the form::
127
127
128 <alias> = <command> [<argument]...
128 <alias> = <command> [<argument]...
129
129
130 For example, this definition::
130 For example, this definition::
131
131
132 latest = log --limit 5
132 latest = log --limit 5
133
133
134 creates a new command ``latest`` that shows only the five most recent
134 creates a new command ``latest`` that shows only the five most recent
135 changesets. You can define subsequent aliases using earlier ones::
135 changesets. You can define subsequent aliases using earlier ones::
136
136
137 stable5 = latest -b stable
137 stable5 = latest -b stable
138
138
139 .. note:: It is possible to create aliases with the same names as
139 .. note:: It is possible to create aliases with the same names as
140 existing commands, which will then override the original
140 existing commands, which will then override the original
141 definitions. This is almost always a bad idea!
141 definitions. This is almost always a bad idea!
142
142
143
143
144 ``auth``
144 ``auth``
145 """"""""
145 """"""""
146 Authentication credentials for HTTP authentication. Each line has
146 Authentication credentials for HTTP authentication. Each line has
147 the following format::
147 the following format::
148
148
149 <name>.<argument> = <value>
149 <name>.<argument> = <value>
150
150
151 where <name> is used to group arguments into authentication entries.
151 where <name> is used to group arguments into authentication entries.
152 Example::
152 Example::
153
153
154 foo.prefix = hg.intevation.org/mercurial
154 foo.prefix = hg.intevation.org/mercurial
155 foo.username = foo
155 foo.username = foo
156 foo.password = bar
156 foo.password = bar
157 foo.schemes = http https
157 foo.schemes = http https
158
158
159 bar.prefix = secure.example.org
159 bar.prefix = secure.example.org
160 bar.key = path/to/file.key
160 bar.key = path/to/file.key
161 bar.cert = path/to/file.cert
161 bar.cert = path/to/file.cert
162 bar.schemes = https
162 bar.schemes = https
163
163
164 Supported arguments:
164 Supported arguments:
165
165
166 ``prefix``
166 ``prefix``
167 Either ``*`` or a URI prefix with or without the scheme part.
167 Either ``*`` or a URI prefix with or without the scheme part.
168 The authentication entry with the longest matching prefix is used
168 The authentication entry with the longest matching prefix is used
169 (where ``*`` matches everything and counts as a match of length
169 (where ``*`` matches everything and counts as a match of length
170 1). If the prefix doesn't include a scheme, the match is performed
170 1). If the prefix doesn't include a scheme, the match is performed
171 against the URI with its scheme stripped as well, and the schemes
171 against the URI with its scheme stripped as well, and the schemes
172 argument, q.v., is then subsequently consulted.
172 argument, q.v., is then subsequently consulted.
173 ``username``
173 ``username``
174 Optional. Username to authenticate with. If not given, and the
174 Optional. Username to authenticate with. If not given, and the
175 remote site requires basic or digest authentication, the user
175 remote site requires basic or digest authentication, the user
176 will be prompted for it.
176 will be prompted for it.
177 ``password``
177 ``password``
178 Optional. Password to authenticate with. If not given, and the
178 Optional. Password to authenticate with. If not given, and the
179 remote site requires basic or digest authentication, the user
179 remote site requires basic or digest authentication, the user
180 will be prompted for it.
180 will be prompted for it.
181 ``key``
181 ``key``
182 Optional. PEM encoded client certificate key file.
182 Optional. PEM encoded client certificate key file.
183 ``cert``
183 ``cert``
184 Optional. PEM encoded client certificate chain file.
184 Optional. PEM encoded client certificate chain file.
185 ``schemes``
185 ``schemes``
186 Optional. Space separated list of URI schemes to use this
186 Optional. Space separated list of URI schemes to use this
187 authentication entry with. Only used if the prefix doesn't include
187 authentication entry with. Only used if the prefix doesn't include
188 a scheme. Supported schemes are http and https. They will match
188 a scheme. Supported schemes are http and https. They will match
189 static-http and static-https respectively, as well.
189 static-http and static-https respectively, as well.
190 Default: https.
190 Default: https.
191
191
192 If no suitable authentication entry is found, the user is prompted
192 If no suitable authentication entry is found, the user is prompted
193 for credentials as usual if required by the remote.
193 for credentials as usual if required by the remote.
194
194
195
195
196 ``decode/encode``
196 ``decode/encode``
197 """""""""""""""""
197 """""""""""""""""
198 Filters for transforming files on checkout/checkin. This would
198 Filters for transforming files on checkout/checkin. This would
199 typically be used for newline processing or other
199 typically be used for newline processing or other
200 localization/canonicalization of files.
200 localization/canonicalization of files.
201
201
202 Filters consist of a filter pattern followed by a filter command.
202 Filters consist of a filter pattern followed by a filter command.
203 Filter patterns are globs by default, rooted at the repository root.
203 Filter patterns are globs by default, rooted at the repository root.
204 For example, to match any file ending in ``.txt`` in the root
204 For example, to match any file ending in ``.txt`` in the root
205 directory only, use the pattern ``*.txt``. To match any file ending
205 directory only, use the pattern ``*.txt``. To match any file ending
206 in ``.c`` anywhere in the repository, use the pattern ``**.c``.
206 in ``.c`` anywhere in the repository, use the pattern ``**.c``.
207
207
208 The filter command can start with a specifier, either "pipe:" or
208 The filter command can start with a specifier, either "pipe:" or
209 "tempfile:". If no specifier is given, "pipe:" is used by default.
209 "tempfile:". If no specifier is given, "pipe:" is used by default.
210
210
211 A "pipe:" command must accept data on stdin and return the transformed
211 A "pipe:" command must accept data on stdin and return the transformed
212 data on stdout.
212 data on stdout.
213
213
214 Pipe example::
214 Pipe example::
215
215
216 [encode]
216 [encode]
217 # uncompress gzip files on checkin to improve delta compression
217 # uncompress gzip files on checkin to improve delta compression
218 # note: not necessarily a good idea, just an example
218 # note: not necessarily a good idea, just an example
219 *.gz = pipe: gunzip
219 *.gz = pipe: gunzip
220
220
221 [decode]
221 [decode]
222 # recompress gzip files when writing them to the working dir (we
222 # recompress gzip files when writing them to the working dir (we
223 # can safely omit "pipe:", because it's the default)
223 # can safely omit "pipe:", because it's the default)
224 *.gz = gzip
224 *.gz = gzip
225
225
226 A "tempfile:" command is a template. The string INFILE is replaced
226 A "tempfile:" command is a template. The string INFILE is replaced
227 with the name of a temporary file that contains the data to be
227 with the name of a temporary file that contains the data to be
228 filtered by the command. The string OUTFILE is replaced with the name
228 filtered by the command. The string OUTFILE is replaced with the name
229 of an empty temporary file, where the filtered data must be written by
229 of an empty temporary file, where the filtered data must be written by
230 the command.
230 the command.
231
231
232 .. note:: The tempfile mechanism is recommended for Windows systems,
232 .. note:: The tempfile mechanism is recommended for Windows systems,
233 where the standard shell I/O redirection operators often have
233 where the standard shell I/O redirection operators often have
234 strange effects and may corrupt the contents of your files.
234 strange effects and may corrupt the contents of your files.
235
235
236 The most common usage is for LF <-> CRLF translation on Windows. For
236 The most common usage is for LF <-> CRLF translation on Windows. For
237 this, use the "smart" converters which check for binary files::
237 this, use the "smart" converters which check for binary files::
238
238
239 [extensions]
239 [extensions]
240 hgext.win32text =
240 hgext.win32text =
241 [encode]
241 [encode]
242 ** = cleverencode:
242 ** = cleverencode:
243 [decode]
243 [decode]
244 ** = cleverdecode:
244 ** = cleverdecode:
245
245
246 or if you only want to translate certain files::
246 or if you only want to translate certain files::
247
247
248 [extensions]
248 [extensions]
249 hgext.win32text =
249 hgext.win32text =
250 [encode]
250 [encode]
251 **.txt = dumbencode:
251 **.txt = dumbencode:
252 [decode]
252 [decode]
253 **.txt = dumbdecode:
253 **.txt = dumbdecode:
254
254
255
255
256 ``defaults``
256 ``defaults``
257 """"""""""""
257 """"""""""""
258
258
259 (defaults are deprecated. Don't use them. Use aliases instead)
259 (defaults are deprecated. Don't use them. Use aliases instead)
260
260
261 Use the [defaults] section to define command defaults, i.e. the
261 Use the [defaults] section to define command defaults, i.e. the
262 default options/arguments to pass to the specified commands.
262 default options/arguments to pass to the specified commands.
263
263
264 The following example makes 'hg log' run in verbose mode, and 'hg
264 The following example makes ``hg log`` run in verbose mode, and ``hg
265 status' show only the modified files, by default::
265 status`` show only the modified files, by default::
266
266
267 [defaults]
267 [defaults]
268 log = -v
268 log = -v
269 status = -m
269 status = -m
270
270
271 The actual commands, instead of their aliases, must be used when
271 The actual commands, instead of their aliases, must be used when
272 defining command defaults. The command defaults will also be applied
272 defining command defaults. The command defaults will also be applied
273 to the aliases of the commands defined.
273 to the aliases of the commands defined.
274
274
275
275
276 ``diff``
276 ``diff``
277 """"""""
277 """"""""
278
278
279 Settings used when displaying diffs. They are all Boolean and
279 Settings used when displaying diffs. They are all Boolean and
280 defaults to False.
280 defaults to False.
281
281
282 ``git``
282 ``git``
283 Use git extended diff format.
283 Use git extended diff format.
284 ``nodates``
284 ``nodates``
285 Don't include dates in diff headers.
285 Don't include dates in diff headers.
286 ``showfunc``
286 ``showfunc``
287 Show which function each change is in.
287 Show which function each change is in.
288 ``ignorews``
288 ``ignorews``
289 Ignore white space when comparing lines.
289 Ignore white space when comparing lines.
290 ``ignorewsamount``
290 ``ignorewsamount``
291 Ignore changes in the amount of white space.
291 Ignore changes in the amount of white space.
292 ``ignoreblanklines``
292 ``ignoreblanklines``
293 Ignore changes whose lines are all blank.
293 Ignore changes whose lines are all blank.
294
294
295 ``email``
295 ``email``
296 """""""""
296 """""""""
297 Settings for extensions that send email messages.
297 Settings for extensions that send email messages.
298
298
299 ``from``
299 ``from``
300 Optional. Email address to use in "From" header and SMTP envelope
300 Optional. Email address to use in "From" header and SMTP envelope
301 of outgoing messages.
301 of outgoing messages.
302 ``to``
302 ``to``
303 Optional. Comma-separated list of recipients' email addresses.
303 Optional. Comma-separated list of recipients' email addresses.
304 ``cc``
304 ``cc``
305 Optional. Comma-separated list of carbon copy recipients'
305 Optional. Comma-separated list of carbon copy recipients'
306 email addresses.
306 email addresses.
307 ``bcc``
307 ``bcc``
308 Optional. Comma-separated list of blind carbon copy recipients'
308 Optional. Comma-separated list of blind carbon copy recipients'
309 email addresses. Cannot be set interactively.
309 email addresses. Cannot be set interactively.
310 ``method``
310 ``method``
311 Optional. Method to use to send email messages. If value is "smtp"
311 Optional. Method to use to send email messages. If value is "smtp"
312 (default), use SMTP (see the SMTP_ section for configuration).
312 (default), use SMTP (see the SMTP_ section for configuration).
313 Otherwise, use as name of program to run that acts like sendmail
313 Otherwise, use as name of program to run that acts like sendmail
314 (takes "-f" option for sender, list of recipients on command line,
314 (takes "-f" option for sender, list of recipients on command line,
315 message on stdin). Normally, setting this to "sendmail" or
315 message on stdin). Normally, setting this to "sendmail" or
316 "/usr/sbin/sendmail" is enough to use sendmail to send messages.
316 "/usr/sbin/sendmail" is enough to use sendmail to send messages.
317 ``charsets``
317 ``charsets``
318 Optional. Comma-separated list of character sets considered
318 Optional. Comma-separated list of character sets considered
319 convenient for recipients. Addresses, headers, and parts not
319 convenient for recipients. Addresses, headers, and parts not
320 containing patches of outgoing messages will be encoded in the
320 containing patches of outgoing messages will be encoded in the
321 first character set to which conversion from local encoding
321 first character set to which conversion from local encoding
322 (``$HGENCODING``, ``ui.fallbackencoding``) succeeds. If correct
322 (``$HGENCODING``, ``ui.fallbackencoding``) succeeds. If correct
323 conversion fails, the text in question is sent as is. Defaults to
323 conversion fails, the text in question is sent as is. Defaults to
324 empty (explicit) list.
324 empty (explicit) list.
325
325
326 Order of outgoing email character sets:
326 Order of outgoing email character sets:
327
327
328 1. ``us-ascii``: always first, regardless of settings
328 1. ``us-ascii``: always first, regardless of settings
329 2. ``email.charsets``: in order given by user
329 2. ``email.charsets``: in order given by user
330 3. ``ui.fallbackencoding``: if not in email.charsets
330 3. ``ui.fallbackencoding``: if not in email.charsets
331 4. ``$HGENCODING``: if not in email.charsets
331 4. ``$HGENCODING``: if not in email.charsets
332 5. ``utf-8``: always last, regardless of settings
332 5. ``utf-8``: always last, regardless of settings
333
333
334 Email example::
334 Email example::
335
335
336 [email]
336 [email]
337 from = Joseph User <joe.user@example.com>
337 from = Joseph User <joe.user@example.com>
338 method = /usr/sbin/sendmail
338 method = /usr/sbin/sendmail
339 # charsets for western Europeans
339 # charsets for western Europeans
340 # us-ascii, utf-8 omitted, as they are tried first and last
340 # us-ascii, utf-8 omitted, as they are tried first and last
341 charsets = iso-8859-1, iso-8859-15, windows-1252
341 charsets = iso-8859-1, iso-8859-15, windows-1252
342
342
343
343
344 ``extensions``
344 ``extensions``
345 """"""""""""""
345 """"""""""""""
346
346
347 Mercurial has an extension mechanism for adding new features. To
347 Mercurial has an extension mechanism for adding new features. To
348 enable an extension, create an entry for it in this section.
348 enable an extension, create an entry for it in this section.
349
349
350 If you know that the extension is already in Python's search path,
350 If you know that the extension is already in Python's search path,
351 you can give the name of the module, followed by ``=``, with nothing
351 you can give the name of the module, followed by ``=``, with nothing
352 after the ``=``.
352 after the ``=``.
353
353
354 Otherwise, give a name that you choose, followed by ``=``, followed by
354 Otherwise, give a name that you choose, followed by ``=``, followed by
355 the path to the ``.py`` file (including the file name extension) that
355 the path to the ``.py`` file (including the file name extension) that
356 defines the extension.
356 defines the extension.
357
357
358 To explicitly disable an extension that is enabled in an hgrc of
358 To explicitly disable an extension that is enabled in an hgrc of
359 broader scope, prepend its path with ``!``, as in
359 broader scope, prepend its path with ``!``, as in
360 ``hgext.foo = !/ext/path`` or ``hgext.foo = !`` when path is not
360 ``hgext.foo = !/ext/path`` or ``hgext.foo = !`` when path is not
361 supplied.
361 supplied.
362
362
363 Example for ``~/.hgrc``::
363 Example for ``~/.hgrc``::
364
364
365 [extensions]
365 [extensions]
366 # (the mq extension will get loaded from Mercurial's path)
366 # (the mq extension will get loaded from Mercurial's path)
367 hgext.mq =
367 hgext.mq =
368 # (this extension will get loaded from the file specified)
368 # (this extension will get loaded from the file specified)
369 myfeature = ~/.hgext/myfeature.py
369 myfeature = ~/.hgext/myfeature.py
370
370
371
371
372 ``format``
372 ``format``
373 """"""""""
373 """"""""""
374
374
375 ``usestore``
375 ``usestore``
376 Enable or disable the "store" repository format which improves
376 Enable or disable the "store" repository format which improves
377 compatibility with systems that fold case or otherwise mangle
377 compatibility with systems that fold case or otherwise mangle
378 filenames. Enabled by default. Disabling this option will allow
378 filenames. Enabled by default. Disabling this option will allow
379 you to store longer filenames in some situations at the expense of
379 you to store longer filenames in some situations at the expense of
380 compatibility and ensures that the on-disk format of newly created
380 compatibility and ensures that the on-disk format of newly created
381 repositories will be compatible with Mercurial before version 0.9.4.
381 repositories will be compatible with Mercurial before version 0.9.4.
382
382
383 ``usefncache``
383 ``usefncache``
384 Enable or disable the "fncache" repository format which enhances
384 Enable or disable the "fncache" repository format which enhances
385 the "store" repository format (which has to be enabled to use
385 the "store" repository format (which has to be enabled to use
386 fncache) to allow longer filenames and avoids using Windows
386 fncache) to allow longer filenames and avoids using Windows
387 reserved names, e.g. "nul". Enabled by default. Disabling this
387 reserved names, e.g. "nul". Enabled by default. Disabling this
388 option ensures that the on-disk format of newly created
388 option ensures that the on-disk format of newly created
389 repositories will be compatible with Mercurial before version 1.1.
389 repositories will be compatible with Mercurial before version 1.1.
390
390
391 ``merge-patterns``
391 ``merge-patterns``
392 """"""""""""""""""
392 """"""""""""""""""
393
393
394 This section specifies merge tools to associate with particular file
394 This section specifies merge tools to associate with particular file
395 patterns. Tools matched here will take precedence over the default
395 patterns. Tools matched here will take precedence over the default
396 merge tool. Patterns are globs by default, rooted at the repository
396 merge tool. Patterns are globs by default, rooted at the repository
397 root.
397 root.
398
398
399 Example::
399 Example::
400
400
401 [merge-patterns]
401 [merge-patterns]
402 **.c = kdiff3
402 **.c = kdiff3
403 **.jpg = myimgmerge
403 **.jpg = myimgmerge
404
404
405 ``merge-tools``
405 ``merge-tools``
406 """""""""""""""
406 """""""""""""""
407
407
408 This section configures external merge tools to use for file-level
408 This section configures external merge tools to use for file-level
409 merges.
409 merges.
410
410
411 Example ``~/.hgrc``::
411 Example ``~/.hgrc``::
412
412
413 [merge-tools]
413 [merge-tools]
414 # Override stock tool location
414 # Override stock tool location
415 kdiff3.executable = ~/bin/kdiff3
415 kdiff3.executable = ~/bin/kdiff3
416 # Specify command line
416 # Specify command line
417 kdiff3.args = $base $local $other -o $output
417 kdiff3.args = $base $local $other -o $output
418 # Give higher priority
418 # Give higher priority
419 kdiff3.priority = 1
419 kdiff3.priority = 1
420
420
421 # Define new tool
421 # Define new tool
422 myHtmlTool.args = -m $local $other $base $output
422 myHtmlTool.args = -m $local $other $base $output
423 myHtmlTool.regkey = Software\FooSoftware\HtmlMerge
423 myHtmlTool.regkey = Software\FooSoftware\HtmlMerge
424 myHtmlTool.priority = 1
424 myHtmlTool.priority = 1
425
425
426 Supported arguments:
426 Supported arguments:
427
427
428 ``priority``
428 ``priority``
429 The priority in which to evaluate this tool.
429 The priority in which to evaluate this tool.
430 Default: 0.
430 Default: 0.
431 ``executable``
431 ``executable``
432 Either just the name of the executable or its pathname.
432 Either just the name of the executable or its pathname.
433 Default: the tool name.
433 Default: the tool name.
434 ``args``
434 ``args``
435 The arguments to pass to the tool executable. You can refer to the
435 The arguments to pass to the tool executable. You can refer to the
436 files being merged as well as the output file through these
436 files being merged as well as the output file through these
437 variables: ``$base``, ``$local``, ``$other``, ``$output``.
437 variables: ``$base``, ``$local``, ``$other``, ``$output``.
438 Default: ``$local $base $other``
438 Default: ``$local $base $other``
439 ``premerge``
439 ``premerge``
440 Attempt to run internal non-interactive 3-way merge tool before
440 Attempt to run internal non-interactive 3-way merge tool before
441 launching external tool.
441 launching external tool.
442 Default: True
442 Default: True
443 ``binary``
443 ``binary``
444 This tool can merge binary files. Defaults to False, unless tool
444 This tool can merge binary files. Defaults to False, unless tool
445 was selected by file pattern match.
445 was selected by file pattern match.
446 ``symlink``
446 ``symlink``
447 This tool can merge symlinks. Defaults to False, even if tool was
447 This tool can merge symlinks. Defaults to False, even if tool was
448 selected by file pattern match.
448 selected by file pattern match.
449 ``checkconflicts``
449 ``checkconflicts``
450 Check whether there are conflicts even though the tool reported
450 Check whether there are conflicts even though the tool reported
451 success.
451 success.
452 Default: False
452 Default: False
453 ``checkchanged``
453 ``checkchanged``
454 Check whether outputs were written even though the tool reported
454 Check whether outputs were written even though the tool reported
455 success.
455 success.
456 Default: False
456 Default: False
457 ``fixeol``
457 ``fixeol``
458 Attempt to fix up EOL changes caused by the merge tool.
458 Attempt to fix up EOL changes caused by the merge tool.
459 Default: False
459 Default: False
460 ``gui``
460 ``gui``
461 This tool requires a graphical interface to run. Default: False
461 This tool requires a graphical interface to run. Default: False
462 ``regkey``
462 ``regkey``
463 Windows registry key which describes install location of this
463 Windows registry key which describes install location of this
464 tool. Mercurial will search for this key first under
464 tool. Mercurial will search for this key first under
465 ``HKEY_CURRENT_USER`` and then under ``HKEY_LOCAL_MACHINE``.
465 ``HKEY_CURRENT_USER`` and then under ``HKEY_LOCAL_MACHINE``.
466 Default: None
466 Default: None
467 ``regname``
467 ``regname``
468 Name of value to read from specified registry key. Defaults to the
468 Name of value to read from specified registry key. Defaults to the
469 unnamed (default) value.
469 unnamed (default) value.
470 ``regappend``
470 ``regappend``
471 String to append to the value read from the registry, typically
471 String to append to the value read from the registry, typically
472 the executable name of the tool.
472 the executable name of the tool.
473 Default: None
473 Default: None
474
474
475
475
476 ``hooks``
476 ``hooks``
477 """""""""
477 """""""""
478 Commands or Python functions that get automatically executed by
478 Commands or Python functions that get automatically executed by
479 various actions such as starting or finishing a commit. Multiple
479 various actions such as starting or finishing a commit. Multiple
480 hooks can be run for the same action by appending a suffix to the
480 hooks can be run for the same action by appending a suffix to the
481 action. Overriding a site-wide hook can be done by changing its
481 action. Overriding a site-wide hook can be done by changing its
482 value or setting it to an empty string.
482 value or setting it to an empty string.
483
483
484 Example ``.hg/hgrc``::
484 Example ``.hg/hgrc``::
485
485
486 [hooks]
486 [hooks]
487 # do not use the site-wide hook
487 # do not use the site-wide hook
488 incoming =
488 incoming =
489 incoming.email = /my/email/hook
489 incoming.email = /my/email/hook
490 incoming.autobuild = /my/build/hook
490 incoming.autobuild = /my/build/hook
491
491
492 Most hooks are run with environment variables set that give useful
492 Most hooks are run with environment variables set that give useful
493 additional information. For each hook below, the environment
493 additional information. For each hook below, the environment
494 variables it is passed are listed with names of the form "$HG_foo".
494 variables it is passed are listed with names of the form ``$HG_foo``.
495
495
496 ``changegroup``
496 ``changegroup``
497 Run after a changegroup has been added via push, pull or unbundle.
497 Run after a changegroup has been added via push, pull or unbundle.
498 ID of the first new changeset is in ``$HG_NODE``. URL from which
498 ID of the first new changeset is in ``$HG_NODE``. URL from which
499 changes came is in ``$HG_URL``.
499 changes came is in ``$HG_URL``.
500 ``commit``
500 ``commit``
501 Run after a changeset has been created in the local repository. ID
501 Run after a changeset has been created in the local repository. ID
502 of the newly created changeset is in ``$HG_NODE``. Parent changeset
502 of the newly created changeset is in ``$HG_NODE``. Parent changeset
503 IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``.
503 IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``.
504 ``incoming``
504 ``incoming``
505 Run after a changeset has been pulled, pushed, or unbundled into
505 Run after a changeset has been pulled, pushed, or unbundled into
506 the local repository. The ID of the newly arrived changeset is in
506 the local repository. The ID of the newly arrived changeset is in
507 ``$HG_NODE``. URL that was source of changes came is in ``$HG_URL``.
507 ``$HG_NODE``. URL that was source of changes came is in ``$HG_URL``.
508 ``outgoing``
508 ``outgoing``
509 Run after sending changes from local repository to another. ID of
509 Run after sending changes from local repository to another. ID of
510 first changeset sent is in ``$HG_NODE``. Source of operation is in
510 first changeset sent is in ``$HG_NODE``. Source of operation is in
511 ``$HG_SOURCE``; see "preoutgoing" hook for description.
511 ``$HG_SOURCE``; see "preoutgoing" hook for description.
512 ``post-<command>``
512 ``post-<command>``
513 Run after successful invocations of the associated command. The
513 Run after successful invocations of the associated command. The
514 contents of the command line are passed as ``$HG_ARGS`` and the result
514 contents of the command line are passed as ``$HG_ARGS`` and the result
515 code in ``$HG_RESULT``. Hook failure is ignored.
515 code in ``$HG_RESULT``. Hook failure is ignored.
516 ``pre-<command>``
516 ``pre-<command>``
517 Run before executing the associated command. The contents of the
517 Run before executing the associated command. The contents of the
518 command line are passed as ``$HG_ARGS``. If the hook returns failure,
518 command line are passed as ``$HG_ARGS``. If the hook returns failure,
519 the command doesn't execute and Mercurial returns the failure
519 the command doesn't execute and Mercurial returns the failure
520 code.
520 code.
521 ``prechangegroup``
521 ``prechangegroup``
522 Run before a changegroup is added via push, pull or unbundle. Exit
522 Run before a changegroup is added via push, pull or unbundle. Exit
523 status 0 allows the changegroup to proceed. Non-zero status will
523 status 0 allows the changegroup to proceed. Non-zero status will
524 cause the push, pull or unbundle to fail. URL from which changes
524 cause the push, pull or unbundle to fail. URL from which changes
525 will come is in ``$HG_URL``.
525 will come is in ``$HG_URL``.
526 ``precommit``
526 ``precommit``
527 Run before starting a local commit. Exit status 0 allows the
527 Run before starting a local commit. Exit status 0 allows the
528 commit to proceed. Non-zero status will cause the commit to fail.
528 commit to proceed. Non-zero status will cause the commit to fail.
529 Parent changeset IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``.
529 Parent changeset IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``.
530 ``preoutgoing``
530 ``preoutgoing``
531 Run before collecting changes to send from the local repository to
531 Run before collecting changes to send from the local repository to
532 another. Non-zero status will cause failure. This lets you prevent
532 another. Non-zero status will cause failure. This lets you prevent
533 pull over HTTP or SSH. Also prevents against local pull, push
533 pull over HTTP or SSH. Also prevents against local pull, push
534 (outbound) or bundle commands, but not effective, since you can
534 (outbound) or bundle commands, but not effective, since you can
535 just copy files instead then. Source of operation is in
535 just copy files instead then. Source of operation is in
536 ``$HG_SOURCE``. If "serve", operation is happening on behalf of remote
536 ``$HG_SOURCE``. If "serve", operation is happening on behalf of remote
537 SSH or HTTP repository. If "push", "pull" or "bundle", operation
537 SSH or HTTP repository. If "push", "pull" or "bundle", operation
538 is happening on behalf of repository on same system.
538 is happening on behalf of repository on same system.
539 ``pretag``
539 ``pretag``
540 Run before creating a tag. Exit status 0 allows the tag to be
540 Run before creating a tag. Exit status 0 allows the tag to be
541 created. Non-zero status will cause the tag to fail. ID of
541 created. Non-zero status will cause the tag to fail. ID of
542 changeset to tag is in ``$HG_NODE``. Name of tag is in ``$HG_TAG``. Tag is
542 changeset to tag is in ``$HG_NODE``. Name of tag is in ``$HG_TAG``. Tag is
543 local if ``$HG_LOCAL=1``, in repository if ``$HG_LOCAL=0``.
543 local if ``$HG_LOCAL=1``, in repository if ``$HG_LOCAL=0``.
544 ``pretxnchangegroup``
544 ``pretxnchangegroup``
545 Run after a changegroup has been added via push, pull or unbundle,
545 Run after a changegroup has been added via push, pull or unbundle,
546 but before the transaction has been committed. Changegroup is
546 but before the transaction has been committed. Changegroup is
547 visible to hook program. This lets you validate incoming changes
547 visible to hook program. This lets you validate incoming changes
548 before accepting them. Passed the ID of the first new changeset in
548 before accepting them. Passed the ID of the first new changeset in
549 ``$HG_NODE``. Exit status 0 allows the transaction to commit. Non-zero
549 ``$HG_NODE``. Exit status 0 allows the transaction to commit. Non-zero
550 status will cause the transaction to be rolled back and the push,
550 status will cause the transaction to be rolled back and the push,
551 pull or unbundle will fail. URL that was source of changes is in
551 pull or unbundle will fail. URL that was source of changes is in
552 ``$HG_URL``.
552 ``$HG_URL``.
553 ``pretxncommit``
553 ``pretxncommit``
554 Run after a changeset has been created but the transaction not yet
554 Run after a changeset has been created but the transaction not yet
555 committed. Changeset is visible to hook program. This lets you
555 committed. Changeset is visible to hook program. This lets you
556 validate commit message and changes. Exit status 0 allows the
556 validate commit message and changes. Exit status 0 allows the
557 commit to proceed. Non-zero status will cause the transaction to
557 commit to proceed. Non-zero status will cause the transaction to
558 be rolled back. ID of changeset is in ``$HG_NODE``. Parent changeset
558 be rolled back. ID of changeset is in ``$HG_NODE``. Parent changeset
559 IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``.
559 IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``.
560 ``preupdate``
560 ``preupdate``
561 Run before updating the working directory. Exit status 0 allows
561 Run before updating the working directory. Exit status 0 allows
562 the update to proceed. Non-zero status will prevent the update.
562 the update to proceed. Non-zero status will prevent the update.
563 Changeset ID of first new parent is in ``$HG_PARENT1``. If merge, ID
563 Changeset ID of first new parent is in ``$HG_PARENT1``. If merge, ID
564 of second new parent is in ``$HG_PARENT2``.
564 of second new parent is in ``$HG_PARENT2``.
565 ``tag``
565 ``tag``
566 Run after a tag is created. ID of tagged changeset is in ``$HG_NODE``.
566 Run after a tag is created. ID of tagged changeset is in ``$HG_NODE``.
567 Name of tag is in ``$HG_TAG``. Tag is local if ``$HG_LOCAL=1``, in
567 Name of tag is in ``$HG_TAG``. Tag is local if ``$HG_LOCAL=1``, in
568 repository if ``$HG_LOCAL=0``.
568 repository if ``$HG_LOCAL=0``.
569 ``update``
569 ``update``
570 Run after updating the working directory. Changeset ID of first
570 Run after updating the working directory. Changeset ID of first
571 new parent is in ``$HG_PARENT1``. If merge, ID of second new parent is
571 new parent is in ``$HG_PARENT1``. If merge, ID of second new parent is
572 in ``$HG_PARENT2``. If the update succeeded, ``$HG_ERROR=0``. If the
572 in ``$HG_PARENT2``. If the update succeeded, ``$HG_ERROR=0``. If the
573 update failed (e.g. because conflicts not resolved), ``$HG_ERROR=1``.
573 update failed (e.g. because conflicts not resolved), ``$HG_ERROR=1``.
574
574
575 .. note:: It is generally better to use standard hooks rather than the
575 .. note:: It is generally better to use standard hooks rather than the
576 generic pre- and post- command hooks as they are guaranteed to be
576 generic pre- and post- command hooks as they are guaranteed to be
577 called in the appropriate contexts for influencing transactions.
577 called in the appropriate contexts for influencing transactions.
578 Also, hooks like "commit" will be called in all contexts that
578 Also, hooks like "commit" will be called in all contexts that
579 generate a commit (e.g. tag) and not just the commit command.
579 generate a commit (e.g. tag) and not just the commit command.
580
580
581 .. note:: Environment variables with empty values may not be passed to
581 .. note:: Environment variables with empty values may not be passed to
582 hooks on platforms such as Windows. As an example, ``$HG_PARENT2``
582 hooks on platforms such as Windows. As an example, ``$HG_PARENT2``
583 will have an empty value under Unix-like platforms for non-merge
583 will have an empty value under Unix-like platforms for non-merge
584 changesets, while it will not be available at all under Windows.
584 changesets, while it will not be available at all under Windows.
585
585
586 The syntax for Python hooks is as follows::
586 The syntax for Python hooks is as follows::
587
587
588 hookname = python:modulename.submodule.callable
588 hookname = python:modulename.submodule.callable
589 hookname = python:/path/to/python/module.py:callable
589 hookname = python:/path/to/python/module.py:callable
590
590
591 Python hooks are run within the Mercurial process. Each hook is
591 Python hooks are run within the Mercurial process. Each hook is
592 called with at least three keyword arguments: a ui object (keyword
592 called with at least three keyword arguments: a ui object (keyword
593 "ui"), a repository object (keyword "repo"), and a "hooktype"
593 "ui"), a repository object (keyword "repo"), and a "hooktype"
594 keyword that tells what kind of hook is used. Arguments listed as
594 keyword that tells what kind of hook is used. Arguments listed as
595 environment variables above are passed as keyword arguments, with no
595 environment variables above are passed as keyword arguments, with no
596 ``HG_`` prefix, and names in lower case.
596 ``HG_`` prefix, and names in lower case.
597
597
598 If a Python hook returns a "true" value or raises an exception, this
598 If a Python hook returns a "true" value or raises an exception, this
599 is treated as a failure.
599 is treated as a failure.
600
600
601
601
602 ``http_proxy``
602 ``http_proxy``
603 """"""""""""""
603 """"""""""""""
604 Used to access web-based Mercurial repositories through a HTTP
604 Used to access web-based Mercurial repositories through a HTTP
605 proxy.
605 proxy.
606
606
607 ``host``
607 ``host``
608 Host name and (optional) port of the proxy server, for example
608 Host name and (optional) port of the proxy server, for example
609 "myproxy:8000".
609 "myproxy:8000".
610 ``no``
610 ``no``
611 Optional. Comma-separated list of host names that should bypass
611 Optional. Comma-separated list of host names that should bypass
612 the proxy.
612 the proxy.
613 ``passwd``
613 ``passwd``
614 Optional. Password to authenticate with at the proxy server.
614 Optional. Password to authenticate with at the proxy server.
615 ``user``
615 ``user``
616 Optional. User name to authenticate with at the proxy server.
616 Optional. User name to authenticate with at the proxy server.
617
617
618 ``smtp``
618 ``smtp``
619 """"""""
619 """"""""
620 Configuration for extensions that need to send email messages.
620 Configuration for extensions that need to send email messages.
621
621
622 ``host``
622 ``host``
623 Host name of mail server, e.g. "mail.example.com".
623 Host name of mail server, e.g. "mail.example.com".
624 ``port``
624 ``port``
625 Optional. Port to connect to on mail server. Default: 25.
625 Optional. Port to connect to on mail server. Default: 25.
626 ``tls``
626 ``tls``
627 Optional. Whether to connect to mail server using TLS. True or
627 Optional. Whether to connect to mail server using TLS. True or
628 False. Default: False.
628 False. Default: False.
629 ``username``
629 ``username``
630 Optional. User name to authenticate to SMTP server with. If
630 Optional. User name to authenticate to SMTP server with. If
631 username is specified, password must also be specified.
631 username is specified, password must also be specified.
632 Default: none.
632 Default: none.
633 ``password``
633 ``password``
634 Optional. Password to authenticate to SMTP server with. If
634 Optional. Password to authenticate to SMTP server with. If
635 username is specified, password must also be specified.
635 username is specified, password must also be specified.
636 Default: none.
636 Default: none.
637 ``local_hostname``
637 ``local_hostname``
638 Optional. It's the hostname that the sender can use to identify
638 Optional. It's the hostname that the sender can use to identify
639 itself to the MTA.
639 itself to the MTA.
640
640
641
641
642 ``patch``
642 ``patch``
643 """""""""
643 """""""""
644 Settings used when applying patches, for instance through the 'import'
644 Settings used when applying patches, for instance through the 'import'
645 command or with Mercurial Queues extension.
645 command or with Mercurial Queues extension.
646
646
647 ``eol``
647 ``eol``
648 When set to 'strict' patch content and patched files end of lines
648 When set to 'strict' patch content and patched files end of lines
649 are preserved. When set to 'lf' or 'crlf', both files end of lines
649 are preserved. When set to ``lf`` or ``crlf``, both files end of lines
650 are ignored when patching and the result line endings are
650 are ignored when patching and the result line endings are
651 normalized to either LF (Unix) or CRLF (Windows).
651 normalized to either LF (Unix) or CRLF (Windows).
652 Default: strict.
652 Default: strict.
653
653
654
654
655 ``paths``
655 ``paths``
656 """""""""
656 """""""""
657 Assigns symbolic names to repositories. The left side is the
657 Assigns symbolic names to repositories. The left side is the
658 symbolic name, and the right gives the directory or URL that is the
658 symbolic name, and the right gives the directory or URL that is the
659 location of the repository. Default paths can be declared by setting
659 location of the repository. Default paths can be declared by setting
660 the following entries.
660 the following entries.
661
661
662 ``default``
662 ``default``
663 Directory or URL to use when pulling if no source is specified.
663 Directory or URL to use when pulling if no source is specified.
664 Default is set to repository from which the current repository was
664 Default is set to repository from which the current repository was
665 cloned.
665 cloned.
666 ``default-push``
666 ``default-push``
667 Optional. Directory or URL to use when pushing if no destination
667 Optional. Directory or URL to use when pushing if no destination
668 is specified.
668 is specified.
669
669
670
670
671 ``profiling``
671 ``profiling``
672 """""""""""""
672 """""""""""""
673 Specifies profiling format and file output. In this section
673 Specifies profiling format and file output. In this section
674 description, 'profiling data' stands for the raw data collected
674 description, 'profiling data' stands for the raw data collected
675 during profiling, while 'profiling report' stands for a statistical
675 during profiling, while 'profiling report' stands for a statistical
676 text report generated from the profiling data. The profiling is done
676 text report generated from the profiling data. The profiling is done
677 using lsprof.
677 using lsprof.
678
678
679 ``format``
679 ``format``
680 Profiling format.
680 Profiling format.
681 Default: text.
681 Default: text.
682
682
683 ``text``
683 ``text``
684 Generate a profiling report. When saving to a file, it should be
684 Generate a profiling report. When saving to a file, it should be
685 noted that only the report is saved, and the profiling data is
685 noted that only the report is saved, and the profiling data is
686 not kept.
686 not kept.
687 ``kcachegrind``
687 ``kcachegrind``
688 Format profiling data for kcachegrind use: when saving to a
688 Format profiling data for kcachegrind use: when saving to a
689 file, the generated file can directly be loaded into
689 file, the generated file can directly be loaded into
690 kcachegrind.
690 kcachegrind.
691 ``output``
691 ``output``
692 File path where profiling data or report should be saved. If the
692 File path where profiling data or report should be saved. If the
693 file exists, it is replaced. Default: None, data is printed on
693 file exists, it is replaced. Default: None, data is printed on
694 stderr
694 stderr
695
695
696 ``server``
696 ``server``
697 """"""""""
697 """"""""""
698 Controls generic server settings.
698 Controls generic server settings.
699
699
700 ``uncompressed``
700 ``uncompressed``
701 Whether to allow clients to clone a repository using the
701 Whether to allow clients to clone a repository using the
702 uncompressed streaming protocol. This transfers about 40% more
702 uncompressed streaming protocol. This transfers about 40% more
703 data than a regular clone, but uses less memory and CPU on both
703 data than a regular clone, but uses less memory and CPU on both
704 server and client. Over a LAN (100 Mbps or better) or a very fast
704 server and client. Over a LAN (100 Mbps or better) or a very fast
705 WAN, an uncompressed streaming clone is a lot faster (~10x) than a
705 WAN, an uncompressed streaming clone is a lot faster (~10x) than a
706 regular clone. Over most WAN connections (anything slower than
706 regular clone. Over most WAN connections (anything slower than
707 about 6 Mbps), uncompressed streaming is slower, because of the
707 about 6 Mbps), uncompressed streaming is slower, because of the
708 extra data transfer overhead. Default is False.
708 extra data transfer overhead. Default is False.
709
709
710
710
711 ``trusted``
711 ``trusted``
712 """""""""""
712 """""""""""
713 For security reasons, Mercurial will not use the settings in the
713 For security reasons, Mercurial will not use the settings in the
714 ``.hg/hgrc`` file from a repository if it doesn't belong to a trusted
714 ``.hg/hgrc`` file from a repository if it doesn't belong to a trusted
715 user or to a trusted group. The main exception is the web interface,
715 user or to a trusted group. The main exception is the web interface,
716 which automatically uses some safe settings, since it's common to
716 which automatically uses some safe settings, since it's common to
717 serve repositories from different users.
717 serve repositories from different users.
718
718
719 This section specifies what users and groups are trusted. The
719 This section specifies what users and groups are trusted. The
720 current user is always trusted. To trust everybody, list a user or a
720 current user is always trusted. To trust everybody, list a user or a
721 group with name ``*``.
721 group with name ``*``.
722
722
723 ``users``
723 ``users``
724 Comma-separated list of trusted users.
724 Comma-separated list of trusted users.
725 ``groups``
725 ``groups``
726 Comma-separated list of trusted groups.
726 Comma-separated list of trusted groups.
727
727
728
728
729 ``ui``
729 ``ui``
730 """"""
730 """"""
731
731
732 User interface controls.
732 User interface controls.
733
733
734 ``archivemeta``
734 ``archivemeta``
735 Whether to include the .hg_archival.txt file containing meta data
735 Whether to include the .hg_archival.txt file containing meta data
736 (hashes for the repository base and for tip) in archives created
736 (hashes for the repository base and for tip) in archives created
737 by the hg archive command or downloaded via hgweb.
737 by the hg archive command or downloaded via hgweb.
738 Default is True.
738 Default is True.
739 ``askusername``
739 ``askusername``
740 Whether to prompt for a username when committing. If True, and
740 Whether to prompt for a username when committing. If True, and
741 neither ``$HGUSER`` nor ``$EMAIL`` has been specified, then the user will
741 neither ``$HGUSER`` nor ``$EMAIL`` has been specified, then the user will
742 be prompted to enter a username. If no username is entered, the
742 be prompted to enter a username. If no username is entered, the
743 default ``USER@HOST`` is used instead.
743 default ``USER@HOST`` is used instead.
744 Default is False.
744 Default is False.
745 ``debug``
745 ``debug``
746 Print debugging information. True or False. Default is False.
746 Print debugging information. True or False. Default is False.
747 ``editor``
747 ``editor``
748 The editor to use during a commit. Default is ``$EDITOR`` or "vi".
748 The editor to use during a commit. Default is ``$EDITOR`` or ``vi``.
749 ``fallbackencoding``
749 ``fallbackencoding``
750 Encoding to try if it's not possible to decode the changelog using
750 Encoding to try if it's not possible to decode the changelog using
751 UTF-8. Default is ISO-8859-1.
751 UTF-8. Default is ISO-8859-1.
752 ``ignore``
752 ``ignore``
753 A file to read per-user ignore patterns from. This file should be
753 A file to read per-user ignore patterns from. This file should be
754 in the same format as a repository-wide .hgignore file. This
754 in the same format as a repository-wide .hgignore file. This
755 option supports hook syntax, so if you want to specify multiple
755 option supports hook syntax, so if you want to specify multiple
756 ignore files, you can do so by setting something like
756 ignore files, you can do so by setting something like
757 ``ignore.other = ~/.hgignore2``. For details of the ignore file
757 ``ignore.other = ~/.hgignore2``. For details of the ignore file
758 format, see the |hgignore(5)|_ man page.
758 format, see the |hgignore(5)|_ man page.
759 ``interactive``
759 ``interactive``
760 Allow to prompt the user. True or False. Default is True.
760 Allow to prompt the user. True or False. Default is True.
761 ``logtemplate``
761 ``logtemplate``
762 Template string for commands that print changesets.
762 Template string for commands that print changesets.
763 ``merge``
763 ``merge``
764 The conflict resolution program to use during a manual merge.
764 The conflict resolution program to use during a manual merge.
765 There are some internal tools available:
765 There are some internal tools available:
766
766
767 ``internal:local``
767 ``internal:local``
768 keep the local version
768 keep the local version
769 ``internal:other``
769 ``internal:other``
770 use the other version
770 use the other version
771 ``internal:merge``
771 ``internal:merge``
772 use the internal non-interactive merge tool
772 use the internal non-interactive merge tool
773 ``internal:fail``
773 ``internal:fail``
774 fail to merge
774 fail to merge
775
775
776 For more information on configuring merge tools see the
776 For more information on configuring merge tools see the
777 merge-tools_ section.
777 merge-tools_ section.
778
778
779 ``patch``
779 ``patch``
780 command to use to apply patches. Look for 'gpatch' or 'patch' in
780 command to use to apply patches. Look for ``gpatch`` or ``patch`` in
781 PATH if unset.
781 PATH if unset.
782 ``quiet``
782 ``quiet``
783 Reduce the amount of output printed. True or False. Default is False.
783 Reduce the amount of output printed. True or False. Default is False.
784 ``remotecmd``
784 ``remotecmd``
785 remote command to use for clone/push/pull operations. Default is 'hg'.
785 remote command to use for clone/push/pull operations. Default is ``hg``.
786 ``report_untrusted``
786 ``report_untrusted``
787 Warn if a ``.hg/hgrc`` file is ignored due to not being owned by a
787 Warn if a ``.hg/hgrc`` file is ignored due to not being owned by a
788 trusted user or group. True or False. Default is True.
788 trusted user or group. True or False. Default is True.
789 ``slash``
789 ``slash``
790 Display paths using a slash (``/``) as the path separator. This
790 Display paths using a slash (``/``) as the path separator. This
791 only makes a difference on systems where the default path
791 only makes a difference on systems where the default path
792 separator is not the slash character (e.g. Windows uses the
792 separator is not the slash character (e.g. Windows uses the
793 backslash character (``\``)).
793 backslash character (``\``)).
794 Default is False.
794 Default is False.
795 ``ssh``
795 ``ssh``
796 command to use for SSH connections. Default is 'ssh'.
796 command to use for SSH connections. Default is ``ssh``.
797 ``strict``
797 ``strict``
798 Require exact command names, instead of allowing unambiguous
798 Require exact command names, instead of allowing unambiguous
799 abbreviations. True or False. Default is False.
799 abbreviations. True or False. Default is False.
800 ``style``
800 ``style``
801 Name of style to use for command output.
801 Name of style to use for command output.
802 ``timeout``
802 ``timeout``
803 The timeout used when a lock is held (in seconds), a negative value
803 The timeout used when a lock is held (in seconds), a negative value
804 means no timeout. Default is 600.
804 means no timeout. Default is 600.
805 ``traceback``
805 ``traceback``
806 Mercurial always prints a traceback when an unknown exception
806 Mercurial always prints a traceback when an unknown exception
807 occurs. Setting this to True will make Mercurial print a traceback
807 occurs. Setting this to True will make Mercurial print a traceback
808 on all exceptions, even those recognized by Mercurial (such as
808 on all exceptions, even those recognized by Mercurial (such as
809 IOError or MemoryError). Default is False.
809 IOError or MemoryError). Default is False.
810 ``username``
810 ``username``
811 The committer of a changeset created when running "commit".
811 The committer of a changeset created when running "commit".
812 Typically a person's name and email address, e.g. ``Fred Widget
812 Typically a person's name and email address, e.g. ``Fred Widget
813 <fred@example.com>``. Default is ``$EMAIL`` or ``username@hostname``. If
813 <fred@example.com>``. Default is ``$EMAIL`` or ``username@hostname``. If
814 the username in hgrc is empty, it has to be specified manually or
814 the username in hgrc is empty, it has to be specified manually or
815 in a different hgrc file (e.g. ``$HOME/.hgrc``, if the admin set
815 in a different hgrc file (e.g. ``$HOME/.hgrc``, if the admin set
816 "username =" in the system hgrc).
816 ``username =`` in the system hgrc).
817 ``verbose``
817 ``verbose``
818 Increase the amount of output printed. True or False. Default is False.
818 Increase the amount of output printed. True or False. Default is False.
819
819
820
820
821 ``web``
821 ``web``
822 """""""
822 """""""
823 Web interface configuration.
823 Web interface configuration.
824
824
825 ``accesslog``
825 ``accesslog``
826 Where to output the access log. Default is stdout.
826 Where to output the access log. Default is stdout.
827 ``address``
827 ``address``
828 Interface address to bind to. Default is all.
828 Interface address to bind to. Default is all.
829 ``allow_archive``
829 ``allow_archive``
830 List of archive format (bz2, gz, zip) allowed for downloading.
830 List of archive format (bz2, gz, zip) allowed for downloading.
831 Default is empty.
831 Default is empty.
832 ``allowbz2``
832 ``allowbz2``
833 (DEPRECATED) Whether to allow .tar.bz2 downloading of repository
833 (DEPRECATED) Whether to allow .tar.bz2 downloading of repository
834 revisions.
834 revisions.
835 Default is False.
835 Default is False.
836 ``allowgz``
836 ``allowgz``
837 (DEPRECATED) Whether to allow .tar.gz downloading of repository
837 (DEPRECATED) Whether to allow .tar.gz downloading of repository
838 revisions.
838 revisions.
839 Default is False.
839 Default is False.
840 ``allowpull``
840 ``allowpull``
841 Whether to allow pulling from the repository. Default is True.
841 Whether to allow pulling from the repository. Default is True.
842 ``allow_push``
842 ``allow_push``
843 Whether to allow pushing to the repository. If empty or not set,
843 Whether to allow pushing to the repository. If empty or not set,
844 push is not allowed. If the special value ``*``, any remote user can
844 push is not allowed. If the special value ``*``, any remote user can
845 push, including unauthenticated users. Otherwise, the remote user
845 push, including unauthenticated users. Otherwise, the remote user
846 must have been authenticated, and the authenticated user name must
846 must have been authenticated, and the authenticated user name must
847 be present in this list (separated by whitespace or ","). The
847 be present in this list (separated by whitespace or ``,``). The
848 contents of the allow_push list are examined after the deny_push
848 contents of the allow_push list are examined after the deny_push
849 list.
849 list.
850 ``allow_read``
850 ``allow_read``
851 If the user has not already been denied repository access due to
851 If the user has not already been denied repository access due to
852 the contents of deny_read, this list determines whether to grant
852 the contents of deny_read, this list determines whether to grant
853 repository access to the user. If this list is not empty, and the
853 repository access to the user. If this list is not empty, and the
854 user is unauthenticated or not present in the list (separated by
854 user is unauthenticated or not present in the list (separated by
855 whitespace or ","), then access is denied for the user. If the
855 whitespace or ``,``), then access is denied for the user. If the
856 list is empty or not set, then access is permitted to all users by
856 list is empty or not set, then access is permitted to all users by
857 default. Setting allow_read to the special value ``*`` is equivalent
857 default. Setting allow_read to the special value ``*`` is equivalent
858 to it not being set (i.e. access is permitted to all users). The
858 to it not being set (i.e. access is permitted to all users). The
859 contents of the allow_read list are examined after the deny_read
859 contents of the allow_read list are examined after the deny_read
860 list.
860 list.
861 ``allowzip``
861 ``allowzip``
862 (DEPRECATED) Whether to allow .zip downloading of repository
862 (DEPRECATED) Whether to allow .zip downloading of repository
863 revisions. Default is False. This feature creates temporary files.
863 revisions. Default is False. This feature creates temporary files.
864 ``baseurl``
864 ``baseurl``
865 Base URL to use when publishing URLs in other locations, so
865 Base URL to use when publishing URLs in other locations, so
866 third-party tools like email notification hooks can construct
866 third-party tools like email notification hooks can construct
867 URLs. Example: ``http://hgserver/repos/``.
867 URLs. Example: ``http://hgserver/repos/``.
868 ``contact``
868 ``contact``
869 Name or email address of the person in charge of the repository.
869 Name or email address of the person in charge of the repository.
870 Defaults to ui.username or ``$EMAIL`` or "unknown" if unset or empty.
870 Defaults to ui.username or ``$EMAIL`` or "unknown" if unset or empty.
871 ``deny_push``
871 ``deny_push``
872 Whether to deny pushing to the repository. If empty or not set,
872 Whether to deny pushing to the repository. If empty or not set,
873 push is not denied. If the special value ``*``, all remote users are
873 push is not denied. If the special value ``*``, all remote users are
874 denied push. Otherwise, unauthenticated users are all denied, and
874 denied push. Otherwise, unauthenticated users are all denied, and
875 any authenticated user name present in this list (separated by
875 any authenticated user name present in this list (separated by
876 whitespace or ",") is also denied. The contents of the deny_push
876 whitespace or ``,``) is also denied. The contents of the deny_push
877 list are examined before the allow_push list.
877 list are examined before the allow_push list.
878 ``deny_read``
878 ``deny_read``
879 Whether to deny reading/viewing of the repository. If this list is
879 Whether to deny reading/viewing of the repository. If this list is
880 not empty, unauthenticated users are all denied, and any
880 not empty, unauthenticated users are all denied, and any
881 authenticated user name present in this list (separated by
881 authenticated user name present in this list (separated by
882 whitespace or ",") is also denied access to the repository. If set
882 whitespace or ``,``) is also denied access to the repository. If set
883 to the special value ``*``, all remote users are denied access
883 to the special value ``*``, all remote users are denied access
884 (rarely needed ;). If deny_read is empty or not set, the
884 (rarely needed ;). If deny_read is empty or not set, the
885 determination of repository access depends on the presence and
885 determination of repository access depends on the presence and
886 content of the allow_read list (see description). If both
886 content of the allow_read list (see description). If both
887 deny_read and allow_read are empty or not set, then access is
887 deny_read and allow_read are empty or not set, then access is
888 permitted to all users by default. If the repository is being
888 permitted to all users by default. If the repository is being
889 served via hgwebdir, denied users will not be able to see it in
889 served via hgwebdir, denied users will not be able to see it in
890 the list of repositories. The contents of the deny_read list have
890 the list of repositories. The contents of the deny_read list have
891 priority over (are examined before) the contents of the allow_read
891 priority over (are examined before) the contents of the allow_read
892 list.
892 list.
893 ``descend``
893 ``descend``
894 hgwebdir indexes will not descend into subdirectories. Only repositories
894 hgwebdir indexes will not descend into subdirectories. Only repositories
895 directly in the current path will be shown (other repositories are still
895 directly in the current path will be shown (other repositories are still
896 available from the index corresponding to their containing path).
896 available from the index corresponding to their containing path).
897 ``description``
897 ``description``
898 Textual description of the repository's purpose or contents.
898 Textual description of the repository's purpose or contents.
899 Default is "unknown".
899 Default is "unknown".
900 ``encoding``
900 ``encoding``
901 Character encoding name.
901 Character encoding name.
902 Example: "UTF-8"
902 Example: "UTF-8"
903 ``errorlog``
903 ``errorlog``
904 Where to output the error log. Default is stderr.
904 Where to output the error log. Default is stderr.
905 ``hidden``
905 ``hidden``
906 Whether to hide the repository in the hgwebdir index.
906 Whether to hide the repository in the hgwebdir index.
907 Default is False.
907 Default is False.
908 ``ipv6``
908 ``ipv6``
909 Whether to use IPv6. Default is False.
909 Whether to use IPv6. Default is False.
910 ``name``
910 ``name``
911 Repository name to use in the web interface. Default is current
911 Repository name to use in the web interface. Default is current
912 working directory.
912 working directory.
913 ``maxchanges``
913 ``maxchanges``
914 Maximum number of changes to list on the changelog. Default is 10.
914 Maximum number of changes to list on the changelog. Default is 10.
915 ``maxfiles``
915 ``maxfiles``
916 Maximum number of files to list per changeset. Default is 10.
916 Maximum number of files to list per changeset. Default is 10.
917 ``port``
917 ``port``
918 Port to listen on. Default is 8000.
918 Port to listen on. Default is 8000.
919 ``prefix``
919 ``prefix``
920 Prefix path to serve from. Default is '' (server root).
920 Prefix path to serve from. Default is '' (server root).
921 ``push_ssl``
921 ``push_ssl``
922 Whether to require that inbound pushes be transported over SSL to
922 Whether to require that inbound pushes be transported over SSL to
923 prevent password sniffing. Default is True.
923 prevent password sniffing. Default is True.
924 ``staticurl``
924 ``staticurl``
925 Base URL to use for static files. If unset, static files (e.g. the
925 Base URL to use for static files. If unset, static files (e.g. the
926 hgicon.png favicon) will be served by the CGI script itself. Use
926 hgicon.png favicon) will be served by the CGI script itself. Use
927 this setting to serve them directly with the HTTP server.
927 this setting to serve them directly with the HTTP server.
928 Example: ``http://hgserver/static/``.
928 Example: ``http://hgserver/static/``.
929 ``stripes``
929 ``stripes``
930 How many lines a "zebra stripe" should span in multiline output.
930 How many lines a "zebra stripe" should span in multiline output.
931 Default is 1; set to 0 to disable.
931 Default is 1; set to 0 to disable.
932 ``style``
932 ``style``
933 Which template map style to use.
933 Which template map style to use.
934 ``templates``
934 ``templates``
935 Where to find the HTML templates. Default is install path.
935 Where to find the HTML templates. Default is install path.
936
936
937
937
938 AUTHOR
938 AUTHOR
939 ------
939 ------
940 Bryan O'Sullivan <bos@serpentine.com>.
940 Bryan O'Sullivan <bos@serpentine.com>.
941
941
942 Mercurial was written by Matt Mackall <mpm@selenic.com>.
942 Mercurial was written by Matt Mackall <mpm@selenic.com>.
943
943
944 SEE ALSO
944 SEE ALSO
945 --------
945 --------
946 |hg(1)|_, |hgignore(5)|_
946 |hg(1)|_, |hgignore(5)|_
947
947
948 COPYING
948 COPYING
949 -------
949 -------
950 This manual page is copyright 2005 Bryan O'Sullivan.
950 This manual page is copyright 2005 Bryan O'Sullivan.
951 Mercurial is copyright 2005-2009 Matt Mackall.
951 Mercurial is copyright 2005-2009 Matt Mackall.
952 Free use of this software is granted under the terms of the GNU General
952 Free use of this software is granted under the terms of the GNU General
953 Public License version 2.
953 Public License version 2.
954
954
955 .. include:: common.txt
955 .. include:: common.txt
General Comments 0
You need to be logged in to leave comments. Login now