annotate mercurial/help/config.txt @ 14175:b452abffcb15

tests: add pyflakes checking for assigned to but never used
author timeless <timeless@mozdev.org>
date Sun, 01 May 2011 17:27:41 +0200
parents 86b5cc1e8be8
children ff4126ce9301
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
9785
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
1 Mercurial reads configuration data from several files, if they exist.
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
2 Below we list the most specific file first.
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
3
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
4 On Windows, these configuration files are read:
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
5
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
6 - ``<repo>\.hg\hgrc``
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
7 - ``%USERPROFILE%\.hgrc``
11016
6a539853d4c0 help config: update windows documentation to match implementation
Mads Kiilerich <mads@kiilerich.com>
parents: 10998
diff changeset
8 - ``%USERPROFILE%\mercurial.ini``
9785
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
9 - ``%HOME%\.hgrc``
11016
6a539853d4c0 help config: update windows documentation to match implementation
Mads Kiilerich <mads@kiilerich.com>
parents: 10998
diff changeset
10 - ``%HOME%\mercurial.ini``
6a539853d4c0 help config: update windows documentation to match implementation
Mads Kiilerich <mads@kiilerich.com>
parents: 10998
diff changeset
11 - ``C:\mercurial\mercurial.ini`` (unless regkey or hgrc.d\ or mercurial.ini found)
6a539853d4c0 help config: update windows documentation to match implementation
Mads Kiilerich <mads@kiilerich.com>
parents: 10998
diff changeset
12 - ``HKEY_LOCAL_MACHINE\SOFTWARE\Mercurial`` (unless hgrc.d\ or mercurial.ini found)
6a539853d4c0 help config: update windows documentation to match implementation
Mads Kiilerich <mads@kiilerich.com>
parents: 10998
diff changeset
13 - ``<hg.exe-dir>\hgrc.d\*.rc`` (unless mercurial.ini found)
6a539853d4c0 help config: update windows documentation to match implementation
Mads Kiilerich <mads@kiilerich.com>
parents: 10998
diff changeset
14 - ``<hg.exe-dir>\mercurial.ini``
9785
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
15
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
16 On Unix, these files are read:
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
17
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
18 - ``<repo>/.hg/hgrc``
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
19 - ``$HOME/.hgrc``
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
20 - ``/etc/mercurial/hgrc``
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
21 - ``/etc/mercurial/hgrc.d/*.rc``
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
22 - ``<install-root>/etc/mercurial/hgrc``
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
23 - ``<install-root>/etc/mercurial/hgrc.d/*.rc``
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
24
13955
86b5cc1e8be8 help config: explain that config files do not exist by default
Martin Geisler <mg@lazybytes.net>
parents: 11408
diff changeset
25 These files do not exist by default and you will have to create the
86b5cc1e8be8 help config: explain that config files do not exist by default
Martin Geisler <mg@lazybytes.net>
parents: 11408
diff changeset
26 appropriate configuration files yourself: global configuration like
86b5cc1e8be8 help config: explain that config files do not exist by default
Martin Geisler <mg@lazybytes.net>
parents: 11408
diff changeset
27 the username setting is typically put into
86b5cc1e8be8 help config: explain that config files do not exist by default
Martin Geisler <mg@lazybytes.net>
parents: 11408
diff changeset
28 ``%USERPROFILE%\mercurial.ini`` or ``$HOME/.hgrc`` and local
86b5cc1e8be8 help config: explain that config files do not exist by default
Martin Geisler <mg@lazybytes.net>
parents: 11408
diff changeset
29 configuration is put into the per-repository ``<repo>/.hg/hgrc`` file.
86b5cc1e8be8 help config: explain that config files do not exist by default
Martin Geisler <mg@lazybytes.net>
parents: 11408
diff changeset
30
11408
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
31 If there is a per-repository configuration file which is not owned by
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
32 the active user, Mercurial will warn you that the file is skipped::
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
33
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
34 not trusting file <repo>/.hg/hgrc from untrusted user USER, group GROUP
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
35
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
36 If this bothers you, the warning can be silenced (the file would still
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
37 be ignored) or trust can be established. Use one of the following
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
38 settings, the syntax is explained below:
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
39
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
40 - ``ui.report_untrusted = False``
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
41 - ``trusted.users = USER``
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
42 - ``trusted.groups = GROUP``
534c69494918 Explain trust near hgrc in config help
timeless <timeless@gmail.com>
parents: 11016
diff changeset
43
9785
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
44 The configuration files for Mercurial use a simple ini-file format. A
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
45 configuration file consists of sections, led by a ``[section]`` header
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
46 and followed by ``name = value`` entries::
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
47
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
48 [ui]
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
49 username = Firstname Lastname <firstname.lastname@example.net>
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
50 verbose = True
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
51
10998
2d4225faa61a help: config.txt typo
Matt Mackall <mpm@selenic.com>
parents: 9999
diff changeset
52 The above entries will be referred to as ``ui.username`` and
9785
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
53 ``ui.verbose``, respectively. Please see the hgrc man page for a full
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
54 description of the possible configuration values:
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
55
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
56 - on Unix-like systems: ``man hgrc``
b52f0f221325 help: add "hg help config" topic
Martin Geisler <mg@lazybytes.net>
parents:
diff changeset
57 - online: http://www.selenic.com/mercurial/hgrc.5.html