view mercurial/help/config.txt @ 11322:3d6915f5a2bb

improve --branch processing (and differentiate from # syntax) Previously #foo and --branch foo were handled identically. The behavior of #foo hasn't changed, but --branch now works like this: 1) If branchmap is not supported on the remote, the operation fails. 2) If branch is '.', substitute with branch of the working dir parent. 3) If branch exists remotely, its heads are expanded. 4) Otherwise, the operation fails. Tests have been added for the new cases.
author Sune Foldager <cryo@cyanite.org>
date Thu, 10 Jun 2010 12:46:09 +0200
parents 6a539853d4c0
children 534c69494918
line wrap: on
line source

Mercurial reads configuration data from several files, if they exist.
Below we list the most specific file first.

On Windows, these configuration files are read:

- ``<repo>\.hg\hgrc``
- ``%USERPROFILE%\.hgrc``
- ``%USERPROFILE%\mercurial.ini``
- ``%HOME%\.hgrc``
- ``%HOME%\mercurial.ini``
- ``C:\mercurial\mercurial.ini`` (unless regkey or hgrc.d\ or mercurial.ini found)
- ``HKEY_LOCAL_MACHINE\SOFTWARE\Mercurial`` (unless hgrc.d\ or mercurial.ini found)
- ``<hg.exe-dir>\hgrc.d\*.rc`` (unless mercurial.ini found)
- ``<hg.exe-dir>\mercurial.ini``

On Unix, these files are read:

- ``<repo>/.hg/hgrc``
- ``$HOME/.hgrc``
- ``/etc/mercurial/hgrc``
- ``/etc/mercurial/hgrc.d/*.rc``
- ``<install-root>/etc/mercurial/hgrc``
- ``<install-root>/etc/mercurial/hgrc.d/*.rc``

The configuration files for Mercurial use a simple ini-file format. A
configuration file consists of sections, led by a ``[section]`` header
and followed by ``name = value`` entries::

  [ui]
  username = Firstname Lastname <firstname.lastname@example.net>
  verbose = True

The above entries will be referred to as ``ui.username`` and
``ui.verbose``, respectively. Please see the hgrc man page for a full
description of the possible configuration values:

- on Unix-like systems: ``man hgrc``
- online: http://www.selenic.com/mercurial/hgrc.5.html