# HG changeset patch # User mpm@selenic.com # Date 1124498725 28800 # Node ID 52d8d81e72ad780f79e93e811383e4b2c31769bd # Parent ffb0665028f00e00566cf07d9158f51be3a0234f# Parent dbfabfcb485e29022b71d44e7f634c93600430a3 Merge with TAH diff -r ffb0665028f0 -r 52d8d81e72ad .hgignore diff -r ffb0665028f0 -r 52d8d81e72ad MANIFEST.in --- a/MANIFEST.in Fri Aug 19 16:43:30 2005 -0800 +++ b/MANIFEST.in Fri Aug 19 16:45:25 2005 -0800 @@ -12,5 +12,4 @@ include README include CONTRIBUTORS include COPYING -include TODO include MANIFEST.in diff -r ffb0665028f0 -r 52d8d81e72ad contrib/bash_completion --- a/contrib/bash_completion Fri Aug 19 16:43:30 2005 -0800 +++ b/contrib/bash_completion Fri Aug 19 16:45:25 2005 -0800 @@ -1,7 +1,7 @@ _hg_commands() { local commands="$(hg -v help | sed -e '1,/^list of commands:/d' \ - -e '/^global options:/Q' \ + -e '/^global options:/,$d' \ -e '/^ [^ ]/!d; s/[,:]//g;')" # hide debug commands from users, but complete them if diff -r ffb0665028f0 -r 52d8d81e72ad doc/hg.1.txt --- a/doc/hg.1.txt Fri Aug 19 16:43:30 2005 -0800 +++ b/doc/hg.1.txt Fri Aug 19 16:45:25 2005 -0800 @@ -273,9 +273,8 @@ Show definition of symbolic path name NAME. If no name is given, show definition of available names. - Path names are defined in the [paths] section of the $HOME/.hgrc and - /.hg/hgrc configuration files. If run outside a repo, 'paths' - queries only $HOME/.hgrc. + Path names are defined in the [paths] section of /etc/mercurial/hgrc + and $HOME/.hgrc. If run inside a repository, .hg/hgrc is used, too. pull :: Pull changes from a remote repository to a local one. @@ -589,10 +588,11 @@ seperated by spaces) that correspond to tagged versions of the repository contents. - $HOME/.hgrc, .hg/hgrc:: + /etc/mercurial/hgrc, $HOME/.hgrc, .hg/hgrc:: This file contains defaults and configuration. Values in .hg/hgrc - override those in .hgrc. See hgrc(5) for details of the contents - and format of these files. + override those in $HOME/.hgrc, and these override settings made in the + global /etc/mercurial/hgrc configuration. See hgrc(5) for details of + the contents and format of these files. BUGS ---- diff -r ffb0665028f0 -r 52d8d81e72ad doc/hgrc.5.txt --- a/doc/hgrc.5.txt Fri Aug 19 16:43:30 2005 -0800 +++ b/doc/hgrc.5.txt Fri Aug 19 16:45:25 2005 -0800 @@ -15,17 +15,22 @@ FILES ----- -Mercurial reads configuration data from two files: +Mercurial reads configuration data from three files: + +/etc/mercurial/hgrc:: + Options in this global configuration file apply to all Mercurial + commands executed by any user in any directory. $HOME/.hgrc:: - Global configuration options that apply to all Mercurial commands, - no matter where they are run. + Per-user configuration options that apply to all Mercurial commands, + no matter from which directory they are run. Values in this file + override global settings. /.hg/hgrc:: Per-repository configuration options that only apply in a particular repository. This file is not version-controlled, and will not get transferred during a "clone" operation. Values in - this file override global values. + this file override global and per-user settings. SYNTAX ------ diff -r ffb0665028f0 -r 52d8d81e72ad mercurial/commands.py diff -r ffb0665028f0 -r 52d8d81e72ad mercurial/hgweb.py diff -r ffb0665028f0 -r 52d8d81e72ad mercurial/ui.py --- a/mercurial/ui.py Fri Aug 19 16:43:30 2005 -0800 +++ b/mercurial/ui.py Fri Aug 19 16:45:25 2005 -0800 @@ -13,7 +13,8 @@ def __init__(self, verbose=False, debug=False, quiet=False, interactive=True): self.cdata = ConfigParser.SafeConfigParser() - self.cdata.read(os.path.expanduser("~/.hgrc")) + self.cdata.read([os.path.normpath(hgrc) for hgrc in + "/etc/mercurial/hgrc", os.path.expanduser("~/.hgrc")]) self.quiet = self.configbool("ui", "quiet") self.verbose = self.configbool("ui", "verbose") diff -r ffb0665028f0 -r 52d8d81e72ad templates/map diff -r ffb0665028f0 -r 52d8d81e72ad tests/test-diffdir --- a/tests/test-diffdir Fri Aug 19 16:43:30 2005 -0800 +++ b/tests/test-diffdir Fri Aug 19 16:45:25 2005 -0800 @@ -7,6 +7,8 @@ echo 123 > b hg add b -hg diff | sed "s/\(\(---\|+++\) [a-zA-Z0-9_/.-]*\).*/\1/" +hg diff | sed -e "s/\(+++ [a-zA-Z0-9_/.-]*\).*/\1/" \ + -e "s/\(--- [a-zA-Z0-9_/.-]*\).*/\1/" -hg diff -r tip | sed "s/\(\(---\|+++\) [a-zA-Z0-9_/.-]*\).*/\1/" +hg diff -r tip | sed -e "s/\(+++ [a-zA-Z0-9_/.-]*\).*/\1/" \ + -e "s/\(--- [a-zA-Z0-9_/.-]*\).*/\1/" diff -r ffb0665028f0 -r 52d8d81e72ad tests/test-merge-revert2 --- a/tests/test-merge-revert2 Fri Aug 19 16:43:30 2005 -0800 +++ b/tests/test-merge-revert2 Fri Aug 19 16:45:25 2005 -0800 @@ -27,7 +27,8 @@ hg update -C 0 echo "changed file1 different" >> file1 HGMERGE=merge hg update -hg diff | sed -e "s/\(\(---\|+++\) [a-zA-Z0-9_/.-]*\).*/\1/" -e "s/\(<<<<<<<\|>>>>>>>\) .*/\1/" +hg diff | sed -e "s/\(+++ [a-zA-Z0-9_/.-]*\).*/\1/" -e "s/\(<<<<<<<\) .*/\1/" \ + -e "s/\(--- [a-zA-Z0-9_/.-]*\).*/\1/" -e "s/\(>>>>>>>\) .*/\1/" hg status hg id hg revert diff -r ffb0665028f0 -r 52d8d81e72ad tests/test-up-local-change --- a/tests/test-up-local-change Fri Aug 19 16:43:30 2005 -0800 +++ b/tests/test-up-local-change Fri Aug 19 16:45:25 2005 -0800 @@ -12,8 +12,8 @@ cd ../r2 hg up echo abc > a -hg diff > ../d -sed "s/\(\(---\|+++\) [a-zA-Z0-9_/.-]*\).*/\1/" < ../d +hg diff | sed -e "s/\(+++ [a-zA-Z0-9_/.-]*\).*/\1/" \ + -e "s/\(--- [a-zA-Z0-9_/.-]*\).*/\1/" cd ../r1 echo b > b @@ -28,6 +28,6 @@ hg --debug up -m hg parents hg -v history -hg diff > ../d -sed "s/\(\(---\|+++\) [a-zA-Z0-9_/.-]*\).*/\1/" < ../d +hg diff | sed -e "s/\(+++ [a-zA-Z0-9_/.-]*\).*/\1/" \ + -e "s/\(--- [a-zA-Z0-9_/.-]*\).*/\1/" diff -r ffb0665028f0 -r 52d8d81e72ad tests/test-walk.out