# HG changeset patch # User Matt Mackall # Date 1368484566 18000 # Node ID 012be6c12ad86b3110e92cbb96273ec12c02e427 # Parent 8bed40e02c3bb8f429c20ebbb25c68a734bc9bdc# Parent 36e0260867fb713aa9f4b7dfa3965785130889f3 merge with i18n diff -r 36e0260867fb -r 012be6c12ad8 mercurial/commands.py --- a/mercurial/commands.py Fri May 10 14:39:09 2013 -0300 +++ b/mercurial/commands.py Mon May 13 17:36:06 2013 -0500 @@ -943,6 +943,9 @@ Returns 0 on success. """ + if label: + label = label.strip() + if not opts.get('clean') and not label: ui.write("%s\n" % repo.dirstate.branch()) return diff -r 36e0260867fb -r 012be6c12ad8 mercurial/help/config.txt --- a/mercurial/help/config.txt Fri May 10 14:39:09 2013 -0300 +++ b/mercurial/help/config.txt Mon May 13 17:36:06 2013 -0500 @@ -85,6 +85,9 @@ be read. Mercurial checks each of these locations in the specified order until one or more configuration files are detected. +.. note:: The registry key ``HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Mercurial`` + is used when running 32-bit Python on 64-bit Windows. + Syntax ====== diff -r 36e0260867fb -r 012be6c12ad8 mercurial/pathencode.c --- a/mercurial/pathencode.c Fri May 10 14:39:09 2013 -0300 +++ b/mercurial/pathencode.c Mon May 13 17:36:06 2013 -0500 @@ -696,7 +696,7 @@ return 0; } -#define MAXENCODE 4096 * 3 +#define MAXENCODE 4096 * 4 static PyObject *hashencode(const char *src, Py_ssize_t len) { diff -r 36e0260867fb -r 012be6c12ad8 tests/test-branches.t --- a/tests/test-branches.t Fri May 10 14:39:09 2013 -0300 +++ b/tests/test-branches.t Mon May 13 17:36:06 2013 -0500 @@ -68,6 +68,18 @@ abort: '\n' cannot be used in a name [255] +trailing or leading spaces should be stripped before testing duplicates + + $ hg branch 'b ' + abort: a branch of the same name already exists + (use 'hg update' to switch to it) + [255] + + $ hg branch ' b' + abort: a branch of the same name already exists + (use 'hg update' to switch to it) + [255] + verify update will accept invalid legacy branch names $ hg init test-invalid-branch-name