changeset 11876:1fe94103c6ee

Merge with stable
author Martin Geisler <mg@lazybytes.net>
date Sat, 14 Aug 2010 03:30:35 +0200
parents 88f5b5c058b5 (diff) 85de44ae0238 (current diff)
children 8bb1481cf08f
files hgext/rebase.py mercurial/url.py
diffstat 293 files changed, 25593 insertions(+), 12687 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/bash_completion	Sat Aug 14 01:31:57 2010 +0200
+++ b/contrib/bash_completion	Sat Aug 14 03:30:35 2010 +0200
@@ -462,6 +462,17 @@
     return 1
 }
 
+_hg_cmd_qqueue()
+{
+    local q
+    local queues
+    local opts="--list --create --delete"
+
+    queues=$( _hg_cmd qqueue --quiet )
+
+    COMPREPLY=( $( compgen -W "${opts} ${queues}" "${cur}" ) )
+}
+
 
 # hbisect
 _hg_cmd_bisect()
--- a/contrib/check-code.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/contrib/check-code.py	Sat Aug 14 03:30:35 2010 +0200
@@ -7,7 +7,7 @@
 # This software may be used and distributed according to the terms of the
 # GNU General Public License version 2 or any later version.
 
-import re, glob
+import re, glob, os, sys
 import optparse
 
 def repquote(m):
@@ -70,12 +70,20 @@
 ]
 
 pypats = [
+    (r'^\s*def\s*\w+\s*\(.*,\s*\(',
+     "tuple parameter unpacking not available in Python 3+"),
+    (r'lambda\s*\(.*,.*\)',
+     "tuple parameter unpacking not available in Python 3+"),
+    (r'(?<!def)\s+(cmp)\(', "cmp is not available in Python 3+"),
+    (r'\breduce\s*\(.*', "reduce is not available in Python 3+"),
+    (r'\.has_key\b', "dict.has_key is not available in Python 3+"),
     (r'^\s*\t', "don't use tabs"),
     (r'\S;\s*\n', "semicolon"),
     (r'\w,\w', "missing whitespace after ,"),
     (r'\w[+/*\-<>]\w', "missing whitespace in expression"),
     (r'^\s+\w+=\w+[^,)]$', "missing whitespace in assignment"),
     (r'.{85}', "line too long"),
+    (r'.{81}', "warning: line over 80 characters"),
     (r'[^\n]\Z', "no trailing newline"),
 #    (r'^\s+[^_ ][^_. ]+_[^_]+\s*=', "don't use underbars in identifiers"),
 #    (r'\w*[a-z][A-Z]\w*\s*=', "don't use camelcase in identifiers"),
@@ -154,7 +162,7 @@
     def __init__(self):
         self._lastseen = None
 
-    def log(self, fname, lineno, line, msg):
+    def log(self, fname, lineno, line, msg, blame):
         """print error related a to given line of a given file.
 
         The faulty line will also be printed but only once in the case
@@ -167,14 +175,26 @@
         """
         msgid = fname, lineno, line
         if msgid != self._lastseen:
-            print "%s:%d:" % (fname, lineno)
+            if blame:
+                print "%s:%d (%s):" % (fname, lineno, blame)
+            else:
+                print "%s:%d:" % (fname, lineno)
             print " > %s" % line
             self._lastseen = msgid
         print " " + msg
 
 _defaultlogger = norepeatlogger()
 
-def checkfile(f, logfunc=_defaultlogger.log, maxerr=None, warnings=False):
+def getblame(f):
+    lines = []
+    for l in os.popen('hg annotate -un %s' % f):
+        start, line = l.split(':', 1)
+        user, rev = start.split()
+        lines.append((line[1:-1], user, rev))
+    return lines
+
+def checkfile(f, logfunc=_defaultlogger.log, maxerr=None, warnings=False,
+              blame=False):
     """checks style and portability of a given file
 
     :f: filepath
@@ -185,6 +205,7 @@
 
     return True if no error is found, False otherwise.
     """
+    blamecache = None
     result = True
     for name, match, filters, pats in checks:
         fc = 0
@@ -204,7 +225,16 @@
                 if not warnings and msg.startswith("warning"):
                     continue
                 if re.search(p, l[1]):
-                    logfunc(f, n + 1, l[0], msg)
+                    bd = ""
+                    if blame:
+                        bd = 'working directory'
+                        if not blamecache:
+                            blamecache = getblame(f)
+                        if n < len(blamecache):
+                            bl, bu, br = blamecache[n]
+                            if bl == l[0]:
+                                bd = '%s@%s' % (bu, br)
+                    logfunc(f, n + 1, l[0], msg, bd)
                     fc += 1
                     result = False
             if maxerr is not None and fc >= maxerr:
@@ -213,15 +243,16 @@
         break
     return result
 
-
 if __name__ == "__main__":
     parser = optparse.OptionParser("%prog [options] [files]")
     parser.add_option("-w", "--warnings", action="store_true",
                       help="include warning-level checks")
     parser.add_option("-p", "--per-file", type="int",
                       help="max warnings per file")
+    parser.add_option("-b", "--blame", action="store_true",
+                      help="use annotate to generate blame info")
 
-    parser.set_defaults(per_file=15, warnings=False)
+    parser.set_defaults(per_file=15, warnings=False, blame=False)
     (options, args) = parser.parse_args()
 
     if len(args) == 0:
@@ -230,4 +261,8 @@
         check = args
 
     for f in check:
-        checkfile(f, maxerr=options.per_file, warnings=options.warnings)
+        ret = 0
+        if not checkfile(f, maxerr=options.per_file, warnings=options.warnings,
+                         blame=options.blame):
+            ret = 1
+    sys.exit(ret)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/debugshell.py	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,21 @@
+# debugshell extension
+"""a python shell with repo, changelog & manifest objects"""
+
+import mercurial
+import code
+
+def debugshell(ui, repo, **opts):
+    objects = {
+        'mercurial': mercurial,
+        'repo': repo,
+        'cl': repo.changelog,
+        'mf': repo.manifest,
+    }
+    bannermsg = "loaded repo : %s\n" \
+                "using source: %s" % (repo.root,
+                                      mercurial.__path__[0])
+    code.interact(bannermsg, local=objects)
+
+cmdtable = {
+    "debugshell|dbsh": (debugshell, [])
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/hgfixes/fix_bytes.py	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,97 @@
+"""Fixer that changes plain strings to bytes strings."""
+
+import re
+
+from lib2to3 import fixer_base
+from lib2to3.pgen2 import token
+from lib2to3.fixer_util import Name
+from lib2to3.pygram import python_symbols as syms
+
+_re = re.compile(r'[rR]?[\'\"]')
+
+# XXX: Implementing a blacklist in 2to3 turned out to be more troublesome than
+# blacklisting some modules inside the fixers. So, this is what I came with.
+
+blacklist = ['mercurial/demandimport.py',
+             'mercurial/py3kcompat.py', # valid python 3 already
+             'mercurial/i18n.py',
+            ]
+
+def isdocstring(node):
+    def isclassorfunction(ancestor):
+        symbols = (syms.funcdef, syms.classdef)
+        # if the current node is a child of a function definition, a class
+        # definition or a file, then it is a docstring
+        if ancestor.type == syms.simple_stmt:
+            try:
+                while True:
+                    if ancestor.type in symbols:
+                        return True
+                    ancestor = ancestor.parent
+            except AttributeError:
+                return False
+        return False
+
+    def ismodule(ancestor):
+        # Our child is a docstring if we are a simple statement, and our
+        # ancestor is file_input. In other words, our child is a lone string in
+        # the source file.
+        try:
+            if (ancestor.type == syms.simple_stmt and
+                ancestor.parent.type == syms.file_input):
+                    return True
+        except AttributeError:
+            return False
+
+    def isdocassignment(ancestor):
+        # Assigning to __doc__, definitely a string
+        try:
+            while True:
+                if (ancestor.type == syms.expr_stmt and
+                    Name('__doc__') in ancestor.children):
+                        return True
+                ancestor = ancestor.parent
+        except AttributeError:
+            return False
+
+    if ismodule(node.parent) or \
+       isdocassignment(node.parent) or \
+       isclassorfunction(node.parent):
+        return True
+    return False
+
+def shouldtransform(node):
+    specialnames = ['__main__']
+
+    if node.value in specialnames:
+        return False
+
+    ggparent = node.parent.parent.parent
+    sggparent = str(ggparent)
+
+    if 'getattr' in sggparent or \
+       'hasattr' in sggparent or \
+       'setattr' in sggparent or \
+       'encode' in sggparent or \
+       'decode' in sggparent:
+           return False
+
+    return True
+
+class FixBytes(fixer_base.BaseFix):
+
+    PATTERN = 'STRING'
+
+    def transform(self, node, results):
+        if self.filename in blacklist:
+            return
+        if node.type == token.STRING:
+            if _re.match(node.value):
+                if isdocstring(node):
+                    return
+                if not shouldtransform(node):
+                    return
+                new = node.clone()
+                new.value = 'b' + new.value
+                return new
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/hgfixes/fix_bytesmod.py	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,63 @@
+"""Fixer that changes bytes % whatever to a function that actually formats
+it."""
+
+from lib2to3 import fixer_base
+from lib2to3.fixer_util import is_tuple, Call, Comma, Name, touch_import
+
+# XXX: Implementing a blacklist in 2to3 turned out to be more troublesome than
+# blacklisting some modules inside the fixers. So, this is what I came with.
+
+blacklist = ['mercurial/demandimport.py',
+             'mercurial/py3kcompat.py',
+             'mercurial/i18n.py',
+            ]
+
+def isnumberremainder(formatstr, data):
+    try:
+        if data.value.isdigit():
+            return True
+    except AttributeError:
+        return False
+
+class FixBytesmod(fixer_base.BaseFix):
+    # XXX: There's one case (I suppose) I can't handle: when a remainder
+    # operation like foo % bar is performed, I can't really know what the
+    # contents of foo and bar are. I believe the best approach is to "correct"
+    # the to-be-converted code and let bytesformatter handle that case in
+    # runtime.
+    PATTERN = '''
+              term< formatstr=STRING '%' data=STRING > |
+              term< formatstr=STRING '%' data=atom > |
+              term< formatstr=NAME '%' data=any > |
+              term< formatstr=any '%' data=any >
+              '''
+
+    def transform(self, node, results):
+        if self.filename in blacklist:
+            return
+        elif self.filename == 'mercurial/util.py':
+            touch_import('.', 'py3kcompat', node=node)
+
+        formatstr = results['formatstr'].clone()
+        data = results['data'].clone()
+        formatstr.prefix = '' # remove spaces from start
+
+        if isnumberremainder(formatstr, data):
+            return
+
+        # We have two possibilities:
+        # 1- An identifier or name is passed, it is going to be a leaf, thus, we
+        #    just need to copy its value as an argument to the formatter;
+        # 2- A tuple is explicitly passed. In this case, we're gonna explode it
+        # to pass to the formatter
+        # TODO: Check for normal strings. They don't need to be translated
+
+        if is_tuple(data):
+            args = [formatstr, Comma().clone()] + \
+                   [c.clone() for c in data.children[:]]
+        else:
+            args = [formatstr, Comma().clone(), data]
+
+        call = Call(Name('bytesformatter', prefix = ' '), args)
+        return call
+
--- a/contrib/mergetools.hgrc	Sat Aug 14 01:31:57 2010 +0200
+++ b/contrib/mergetools.hgrc	Sat Aug 14 03:30:35 2010 +0200
@@ -13,6 +13,9 @@
 gvimdiff.regname=path
 gvimdiff.priority=-9
 
+vimdiff.args=$local $other $base
+vimdiff.priority=-10
+
 merge.checkconflicts=True
 merge.priority=-100
 
--- a/contrib/perf.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/contrib/perf.py	Sat Aug 14 03:30:35 2010 +0200
@@ -133,6 +133,16 @@
         title = 'diffopts: %s' % (diffopt and ('-' + diffopt) or 'none')
         timer(d, title)
 
+def perfrevlog(ui, repo, file_, **opts):
+    from mercurial import revlog
+    dist = opts['dist']
+    def d():
+        r = revlog.revlog(lambda fn: open(fn, 'rb'), file_)
+        for x in xrange(0, len(r), dist):
+            r.revision(r.node(x))
+
+    timer(d)
+
 cmdtable = {
     'perflookup': (perflookup, []),
     'perfparents': (perfparents, []),
@@ -149,4 +159,7 @@
                 [('', 'rename', False, 'ask log to follow renames')]),
     'perftemplating': (perftemplating, []),
     'perfdiffwd': (perfdiffwd, []),
+    'perfrevlog': (perfrevlog,
+                   [('d', 'dist', 100, 'distance between the revisions')],
+                   "[INDEXFILE]"),
 }
--- a/contrib/zsh_completion	Sat Aug 14 01:31:57 2010 +0200
+++ b/contrib/zsh_completion	Sat Aug 14 03:30:35 2010 +0200
@@ -901,6 +901,7 @@
   '(--merge -m)'{-m+,--merge}'[merge from another queue]:' \
   '(--name -n)'{-n+,--name}'[merge queue name]:' \
   '(--force -f)'{-f,--force}'[apply if the patch has rejects]' \
+  '--move[reorder patch series and apply only the patch]' \
   ':patch:_hg_qunapplied'
 }
 
--- a/doc/hgrc.5.txt	Sat Aug 14 01:31:57 2010 +0200
+++ b/doc/hgrc.5.txt	Sat Aug 14 03:30:35 2010 +0200
@@ -232,16 +232,19 @@
     argument, q.v., is then subsequently consulted.
 ``username``
     Optional. Username to authenticate with. If not given, and the
-    remote site requires basic or digest authentication, the user
-    will be prompted for it.
+    remote site requires basic or digest authentication, the user will
+    be prompted for it. Environment variables are expanded in the
+    username letting you do ``foo.username = $USER``.
 ``password``
     Optional. Password to authenticate with. If not given, and the
     remote site requires basic or digest authentication, the user
     will be prompted for it.
 ``key``
-    Optional. PEM encoded client certificate key file.
+    Optional. PEM encoded client certificate key file. Environment
+    variables are expanded in the filename.
 ``cert``
-    Optional. PEM encoded client certificate chain file.
+    Optional. PEM encoded client certificate chain file. Environment
+    variables are expanded in the filename.
 ``schemes``
     Optional. Space separated list of URI schemes to use this
     authentication entry with. Only used if the prefix doesn't include
--- a/hgext/bookmarks.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/bookmarks.py	Sat Aug 14 03:30:35 2010 +0200
@@ -299,7 +299,7 @@
 
             self.ui.debug("checking for updated bookmarks\n")
             rb = remote.listkeys('bookmarks')
-            changes = 0
+            changed = False
             for k in rb.keys():
                 if k in self._bookmarks:
                     nr, nl = rb[k], self._bookmarks[k]
@@ -310,12 +310,12 @@
                             continue
                         if cr in cl.descendants():
                             self._bookmarks[k] = cr.node()
-                            changes += 1
+                            changed = True
                             self.ui.status(_("updating bookmark %s\n") % k)
                         else:
                             self.ui.warn(_("not updating divergent"
                                            " bookmark %s\n") % k)
-            if changes:
+            if changed:
                 write(repo)
 
             return result
@@ -460,7 +460,7 @@
     lmarks = repo.listkeys('bookmarks')
     rmarks = remote.listkeys('bookmarks')
 
-    diff = set(rmarks) - set(lmarks)
+    diff = sorted(set(rmarks) - set(lmarks))
     for k in diff:
         ui.write("   %-25s %s\n" % (k, rmarks[k][:12]))
 
--- a/hgext/bugzilla.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/bugzilla.py	Sat Aug 14 03:30:35 2010 +0200
@@ -437,5 +437,5 @@
                 bz.update(id, ctx)
             bz.notify(ids, util.email(ctx.user()))
     except MySQLdb.MySQLError, err:
-        raise util.Abort(_('database error: %s') % err[1])
+        raise util.Abort(_('database error: %s') % err.args[1])
 
--- a/hgext/churn.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/churn.py	Sat Aug 14 03:30:35 2010 +0200
@@ -149,7 +149,8 @@
 
     if opts.get('diffstat'):
         width -= 15
-        def format(name, (added, removed)):
+        def format(name, diffstat):
+            added, removed = diffstat
             return "%s %15s %s%s\n" % (pad(name, maxname),
                                        '+%d/-%d' % (added, removed),
                                        ui.label('+' * charnum(added),
--- a/hgext/color.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/color.py	Sat Aug 14 03:30:35 2010 +0200
@@ -216,35 +216,36 @@
                             _('TYPE')))
 
 try:
-    import re, pywintypes
-    from win32console import *
+    import re, pywintypes, win32console as win32c
 
     # http://msdn.microsoft.com/en-us/library/ms682088%28VS.85%29.aspx
     w32effects = {
         'none': 0,
         'black': 0,
-        'red': FOREGROUND_RED,
-        'green': FOREGROUND_GREEN,
-        'yellow': FOREGROUND_RED | FOREGROUND_GREEN,
-        'blue': FOREGROUND_BLUE,
-        'magenta': FOREGROUND_BLUE | FOREGROUND_RED,
-        'cyan': FOREGROUND_BLUE | FOREGROUND_GREEN,
-        'white': FOREGROUND_RED | FOREGROUND_GREEN | FOREGROUND_BLUE,
-        'bold': FOREGROUND_INTENSITY,
+        'red': win32c.FOREGROUND_RED,
+        'green': win32c.FOREGROUND_GREEN,
+        'yellow': win32c.FOREGROUND_RED | win32c.FOREGROUND_GREEN,
+        'blue': win32c.FOREGROUND_BLUE,
+        'magenta': win32c.FOREGROUND_BLUE | win32c.FOREGROUND_RED,
+        'cyan': win32c.FOREGROUND_BLUE | win32c.FOREGROUND_GREEN,
+        'white': (win32c.FOREGROUND_RED | win32c.FOREGROUND_GREEN |
+                  win32c.FOREGROUND_BLUE),
+        'bold': win32c.FOREGROUND_INTENSITY,
         'black_background': 0,
-        'red_background': BACKGROUND_RED,
-        'green_background': BACKGROUND_GREEN,
-        'yellow_background': BACKGROUND_RED | BACKGROUND_GREEN,
-        'blue_background': BACKGROUND_BLUE,
-        'purple_background': BACKGROUND_BLUE | BACKGROUND_RED,
-        'cyan_background': BACKGROUND_BLUE | BACKGROUND_GREEN,
-        'white_background': BACKGROUND_RED | BACKGROUND_GREEN | BACKGROUND_BLUE,
-        'bold_background': BACKGROUND_INTENSITY,
-        'underline': COMMON_LVB_UNDERSCORE,     # double-byte charsets only
-        'inverse': COMMON_LVB_REVERSE_VIDEO,    # double-byte charsets only
+        'red_background': win32c.BACKGROUND_RED,
+        'green_background': win32c.BACKGROUND_GREEN,
+        'yellow_background': win32c.BACKGROUND_RED | win32c.BACKGROUND_GREEN,
+        'blue_background': win32c.BACKGROUND_BLUE,
+        'purple_background': win32c.BACKGROUND_BLUE | win32c.BACKGROUND_RED,
+        'cyan_background': win32c.BACKGROUND_BLUE | win32c.BACKGROUND_GREEN,
+        'white_background': (win32c.BACKGROUND_RED | win32c.BACKGROUND_GREEN |
+                             win32c.BACKGROUND_BLUE),
+        'bold_background': win32c.BACKGROUND_INTENSITY,
+        'underline': win32c.COMMON_LVB_UNDERSCORE,  # double-byte charsets only
+        'inverse': win32c.COMMON_LVB_REVERSE_VIDEO, # double-byte charsets only
     }
 
-    stdout = GetStdHandle(STD_OUTPUT_HANDLE)
+    stdout = win32c.GetStdHandle(win32c.STD_OUTPUT_HANDLE)
     try:
         origattr = stdout.GetConsoleScreenBufferInfo()['Attributes']
     except pywintypes.error:
--- a/hgext/convert/__init__.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/convert/__init__.py	Sat Aug 14 03:30:35 2010 +0200
@@ -86,7 +86,7 @@
 
       rename path/to/source path/to/destination
 
-    Comment lines start with '#'. A specificed path matches if it
+    Comment lines start with '#'. A specified path matches if it
     equals the full relative name of a file or one of its parent
     directories. The 'include' or 'exclude' directive with the longest
     matching path applies, so line order does not matter.
@@ -96,8 +96,8 @@
     exclusion of all other files and directories not explicitly
     included. The 'exclude' directive causes files or directories to
     be omitted. The 'rename' directive renames a file or directory if
-    is converted. To rename from a subdirectory into the root of the
-    repository, use '.' as the path to rename to.
+    it is converted. To rename from a subdirectory into the root of
+    the repository, use '.' as the path to rename to.
 
     The splicemap is a file that allows insertion of synthetic
     history, letting you specify the parents of a revision. This is
--- a/hgext/convert/filemap.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/convert/filemap.py	Sat Aug 14 03:30:35 2010 +0200
@@ -33,10 +33,20 @@
     def parse(self, path):
         errs = 0
         def check(name, mapping, listname):
+            if not name:
+                self.ui.warn(_('%s:%d: path to %s is missing\n') %
+                             (lex.infile, lex.lineno, listname))
+                return 1
             if name in mapping:
                 self.ui.warn(_('%s:%d: %r already in %s list\n') %
                              (lex.infile, lex.lineno, name, listname))
                 return 1
+            if (name.startswith('/') or
+                name.endswith('/') or
+                '//' in name):
+                self.ui.warn(_('%s:%d: superfluous / in %s %r\n') %
+                             (lex.infile, lex.lineno, listname, name))
+                return 1
             return 0
         lex = shlex.shlex(open(path), path, True)
         lex.wordchars += '!@#$%^&*()-=+[]{}|;:,./<>?'
@@ -298,7 +308,9 @@
 
         self.origparents[rev] = parents
 
-        if len(mparents) < 2 and not self.wanted(rev, wp):
+        closed = 'close' in self.commits[rev].extra
+
+        if len(mparents) < 2 and not closed and not self.wanted(rev, wp):
             # We don't want this revision.
             # Update our state and tell the convert process to map this
             # revision to the same revision its parent as mapped to.
--- a/hgext/convert/hg.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/convert/hg.py	Sat Aug 14 03:30:35 2010 +0200
@@ -175,7 +175,8 @@
         if self.filemapmode and nparents == 1:
             man = self.repo.manifest
             mnode = self.repo.changelog.read(bin(p2))[0]
-            if not man.cmp(m1node, man.revision(mnode)):
+            closed = 'close' in commit.extra
+            if not closed and not man.cmp(m1node, man.revision(mnode)):
                 self.ui.status(_("filtering out empty revision\n"))
                 self.repo.rollback()
                 return parent
--- a/hgext/convert/transport.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/convert/transport.py	Sat Aug 14 03:30:35 2010 +0200
@@ -98,9 +98,8 @@
             svn.ra.reparent(self.ra, self.svn_url.encode('utf8'))
 
     class Reporter(object):
-        def __init__(self, (reporter, report_baton)):
-            self._reporter = reporter
-            self._baton = report_baton
+        def __init__(self, reporter_data):
+            self._reporter, self._baton = reporter_data
 
         def set_path(self, path, revnum, start_empty, lock_token, pool=None):
             svn.ra.reporter2_invoke_set_path(self._reporter, self._baton,
--- a/hgext/hgcia.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/hgcia.py	Sat Aug 14 03:30:35 2010 +0200
@@ -40,7 +40,7 @@
 """
 
 from mercurial.i18n import _
-from mercurial.node import *
+from mercurial.node import bin, short
 from mercurial import cmdutil, patch, templater, util, mail
 import email.Parser
 
--- a/hgext/inotify/client.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/inotify/client.py	Sat Aug 14 03:30:35 2010 +0200
@@ -27,11 +27,11 @@
         except (OSError, socket.error), err:
             autostart = self.ui.configbool('inotify', 'autostart', True)
 
-            if err[0] == errno.ECONNREFUSED:
+            if err.args[0] == errno.ECONNREFUSED:
                 self.ui.warn(_('inotify-client: found dead inotify server '
                                'socket; removing it\n'))
                 os.unlink(os.path.join(self.root, '.hg', 'inotify.sock'))
-            if err[0] in (errno.ECONNREFUSED, errno.ENOENT) and autostart:
+            if err.args[0] in (errno.ECONNREFUSED, errno.ENOENT) and autostart:
                 self.ui.debug('(starting inotify server)\n')
                 try:
                     try:
@@ -49,13 +49,13 @@
                         return function(self, *args)
                     except socket.error, err:
                         self.ui.warn(_('inotify-client: could not talk to new '
-                                       'inotify server: %s\n') % err[-1])
-            elif err[0] in (errno.ECONNREFUSED, errno.ENOENT):
+                                       'inotify server: %s\n') % err.args[-1])
+            elif err.args[0] in (errno.ECONNREFUSED, errno.ENOENT):
                 # silently ignore normal errors if autostart is False
                 self.ui.debug('(inotify server not running)\n')
             else:
                 self.ui.warn(_('inotify-client: failed to contact inotify '
-                               'server: %s\n') % err[-1])
+                               'server: %s\n') % err.args[-1])
 
         self.ui.traceback()
         raise QueryFailed('inotify query failed')
@@ -75,7 +75,7 @@
         try:
             self.sock.connect(sockpath)
         except socket.error, err:
-            if err[0] == "AF_UNIX path too long":
+            if err.args[0] == "AF_UNIX path too long":
                 sockpath = os.readlink(sockpath)
                 self.sock.connect(sockpath)
             else:
--- a/hgext/inotify/linux/_inotify.c	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/inotify/linux/_inotify.c	Sat Aug 14 03:30:35 2010 +0200
@@ -15,6 +15,15 @@
 #include <sys/ioctl.h>
 #include <unistd.h>
 
+#include <util.h>
+
+/* Variables used in the event string representation */
+static PyObject *join;
+static PyObject *er_wm;
+static PyObject *er_wmc;
+static PyObject *er_wmn;
+static PyObject *er_wmcn;
+
 static PyObject *init(PyObject *self, PyObject *args)
 {
 	PyObject *ret = NULL;
@@ -312,8 +321,8 @@
 };
 
 PyDoc_STRVAR(
-    event_doc,
-    "event: Structure describing an inotify event.");
+	event_doc,
+	"event: Structure describing an inotify event.");
 
 static PyObject *event_new(PyTypeObject *t, PyObject *a, PyObject *k)
 {
@@ -327,20 +336,14 @@
 	Py_XDECREF(evt->cookie);
 	Py_XDECREF(evt->name);
 
-	(*evt->ob_type->tp_free)(evt);
+	Py_TYPE(evt)->tp_free(evt);
 }
 
 static PyObject *event_repr(struct event *evt)
 {
-	int wd = PyInt_AsLong(evt->wd);
 	int cookie = evt->cookie == Py_None ? -1 : PyInt_AsLong(evt->cookie);
 	PyObject *ret = NULL, *pymasks = NULL, *pymask = NULL;
-	PyObject *join = NULL;
-	char *maskstr;
-
-	join = PyString_FromString("|");
-	if (join == NULL)
-		goto bail;
+	PyObject *tuple = NULL, *formatstr = NULL;
 
 	pymasks = decode_mask(PyInt_AsLong(evt->mask));
 	if (pymasks == NULL)
@@ -350,33 +353,35 @@
 	if (pymask == NULL)
 		goto bail;
 
-	maskstr = PyString_AsString(pymask);
-
 	if (evt->name != Py_None) {
-		PyObject *pyname = PyString_Repr(evt->name, 1);
-		char *name = pyname ? PyString_AsString(pyname) : "???";
-
-		if (cookie == -1)
-			ret = PyString_FromFormat(
-				"event(wd=%d, mask=%s, name=%s)",
-				wd, maskstr, name);
-		else
-			ret = PyString_FromFormat("event(wd=%d, mask=%s, "
-						  "cookie=0x%x, name=%s)",
-						  wd, maskstr, cookie, name);
-
-		Py_XDECREF(pyname);
+		if (cookie == -1) {
+			formatstr = er_wmn;
+			tuple = PyTuple_Pack(3, evt->wd, pymask, evt->name);
+		}
+		else {
+			formatstr = er_wmcn;
+			tuple = PyTuple_Pack(4, evt->wd, pymask,
+					     evt->cookie, evt->name);
+		}
 	} else {
-		if (cookie == -1)
-			ret = PyString_FromFormat("event(wd=%d, mask=%s)",
-						  wd, maskstr);
+		if (cookie == -1) {
+			formatstr = er_wm;
+			tuple = PyTuple_Pack(2, evt->wd, pymask);
+		}
 		else {
-			ret = PyString_FromFormat(
-				"event(wd=%d, mask=%s, cookie=0x%x)",
-				wd, maskstr, cookie);
+			formatstr = er_wmc;
+			tuple = PyTuple_Pack(3, evt->wd, pymask, evt->cookie);
 		}
 	}
 
+	if (tuple == NULL)
+		goto bail;
+
+	ret = PyNumber_Remainder(formatstr, tuple);
+
+	if (ret == NULL)
+		goto bail;
+
 	goto done;
 bail:
 	Py_CLEAR(ret);
@@ -384,14 +389,13 @@
 done:
 	Py_XDECREF(pymask);
 	Py_XDECREF(pymasks);
-	Py_XDECREF(join);
+	Py_XDECREF(tuple);
 
 	return ret;
 }
 
 static PyTypeObject event_type = {
-	PyObject_HEAD_INIT(NULL)
-	0,                         /*ob_size*/
+	PyVarObject_HEAD_INIT(NULL, 0)
 	"_inotify.event",             /*tp_name*/
 	sizeof(struct event), /*tp_basicsize*/
 	0,                         /*tp_itemsize*/
@@ -561,6 +565,17 @@
 	return ret;
 }
 
+static int init_globals(void)
+{
+	join = PyString_FromString("|");
+	er_wm = PyString_FromString("event(wd=%d, mask=%s)");
+	er_wmn = PyString_FromString("event(wd=%d, mask=%s, name=%s)");
+	er_wmc = PyString_FromString("event(wd=%d, mask=%s, cookie=0x%x)");
+	er_wmcn = PyString_FromString("event(wd=%d, mask=%s, cookie=0x%x, name=%s)");
+
+	return join && er_wm && er_wmn && er_wmc && er_wmcn;
+}
+
 PyDoc_STRVAR(
 	read_doc,
 	"read(fd, bufsize[=65536]) -> list_of_events\n"
@@ -585,6 +600,35 @@
 	{NULL},
 };
 
+#ifdef IS_PY3K
+static struct PyModuleDef _inotify_module = {
+	PyModuleDef_HEAD_INIT,
+	"_inotify",
+	doc,
+	-1,
+	methods
+};
+
+PyMODINIT_FUNC PyInit__inotify(void)
+{
+	PyObject *mod, *dict;
+
+	mod = PyModule_Create(&_inotify_module);
+
+	if (mod == NULL)
+		return NULL;
+
+	if (!init_globals())
+		return;
+
+	dict = PyModule_GetDict(mod);
+
+	if (dict)
+		define_consts(dict);
+
+	return mod;
+}
+#else
 void init_inotify(void)
 {
 	PyObject *mod, *dict;
@@ -592,6 +636,9 @@
 	if (PyType_Ready(&event_type) == -1)
 		return;
 
+	if (!init_globals())
+		return;
+
 	mod = Py_InitModule3("_inotify", methods, doc);
 
 	dict = PyModule_GetDict(mod);
@@ -599,3 +646,4 @@
 	if (dict)
 		define_consts(dict);
 }
+#endif
--- a/hgext/inotify/linuxserver.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/inotify/linuxserver.py	Sat Aug 14 03:30:35 2010 +0200
@@ -117,7 +117,7 @@
             try:
                 events = cls.poll.poll(timeout)
             except select.error, err:
-                if err[0] == errno.EINTR:
+                if err.args[0] == errno.EINTR:
                     continue
                 raise
             if events:
--- a/hgext/inotify/server.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/inotify/server.py	Sat Aug 14 03:30:35 2010 +0200
@@ -336,10 +336,10 @@
         try:
             self.sock.bind(self.sockpath)
         except socket.error, err:
-            if err[0] == errno.EADDRINUSE:
+            if err.args[0] == errno.EADDRINUSE:
                 raise AlreadyStartedException(_('cannot start: socket is '
                                                 'already bound'))
-            if err[0] == "AF_UNIX path too long":
+            if err.args[0] == "AF_UNIX path too long":
                 if os.path.islink(self.sockpath) and \
                         not os.path.exists(self.sockpath):
                     raise util.Abort('inotify-server: cannot start: '
@@ -437,7 +437,7 @@
             finally:
                 sock.shutdown(socket.SHUT_WR)
         except socket.error, err:
-            if err[0] != errno.EPIPE:
+            if err.args[0] != errno.EPIPE:
                 raise
 
 if sys.platform == 'linux2':
--- a/hgext/keyword.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/keyword.py	Sat Aug 14 03:30:35 2010 +0200
@@ -158,9 +158,9 @@
         kwpat = r'\$(%s)(: [^$\n\r]*? )??\$' % '|'.join(escaped)
         self.re_kw = re.compile(kwpat)
 
-        templatefilters.filters['utcdate'] = utcdate
-        templatefilters.filters['svnisodate'] = svnisodate
-        templatefilters.filters['svnutcdate'] = svnutcdate
+        templatefilters.filters.update({'utcdate': utcdate,
+                                        'svnisodate': svnisodate,
+                                        'svnutcdate': svnutcdate})
 
     def substitute(self, data, path, ctx, subfunc):
         '''Replaces keywords in data with expanded template.'''
--- a/hgext/mq.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/mq.py	Sat Aug 14 03:30:35 2010 +0200
@@ -513,7 +513,7 @@
 
         # apply failed, strip away that rev and merge.
         hg.clean(repo, head)
-        self.strip(repo, n, update=False, backup='strip')
+        self.strip(repo, [n], update=False, backup='strip')
 
         ctx = repo[rev]
         ret = hg.merge(repo, rev)
@@ -895,7 +895,7 @@
         finally:
             release(wlock)
 
-    def strip(self, repo, rev, update=True, backup="all", force=None):
+    def strip(self, repo, revs, update=True, backup="all", force=None):
         wlock = lock = None
         try:
             wlock = repo.wlock()
@@ -903,12 +903,13 @@
 
             if update:
                 self.check_localchanges(repo, force=force, refresh=False)
-                urev = self.qparents(repo, rev)
+                urev = self.qparents(repo, revs[0])
                 hg.clean(repo, urev)
                 repo.dirstate.write()
 
             self.removeundo(repo)
-            repair.strip(self.ui, repo, rev, backup)
+            for rev in revs:
+                repair.strip(self.ui, repo, rev, backup)
             # strip may have unbundled a set of backed up revisions after
             # the actual strip
             self.removeundo(repo)
@@ -1197,7 +1198,7 @@
             for patch in reversed(self.applied[start:end]):
                 self.ui.status(_("popping %s\n") % patch.name)
             del self.applied[start:end]
-            self.strip(repo, rev, update=False, backup='strip')
+            self.strip(repo, [rev], update=False, backup='strip')
             if self.applied:
                 self.ui.write(_("now at: %s\n") % self.applied[-1].name)
             else:
@@ -1377,7 +1378,7 @@
                 repo.dirstate.setparents(*cparents)
                 self.applied.pop()
                 self.applied_dirty = 1
-                self.strip(repo, top, update=False,
+                self.strip(repo, [top], update=False,
                            backup='strip')
             except:
                 repo.dirstate.invalidate()
@@ -1532,7 +1533,7 @@
                     update = True
                 else:
                     update = False
-                self.strip(repo, rev, update=update, backup='strip')
+                self.strip(repo, [rev], update=update, backup='strip')
         if qpp:
             self.ui.warn(_("saved queue repository parents: %s %s\n") %
                          (short(qpp[0]), short(qpp[1])))
@@ -1691,11 +1692,22 @@
             if existing:
                 if filename == '-':
                     raise util.Abort(_('-e is incompatible with import from -'))
-                if not patchname:
-                    patchname = normname(filename)
-                self.check_reserved_name(patchname)
-                if not os.path.isfile(self.join(patchname)):
-                    raise util.Abort(_("patch %s does not exist") % patchname)
+                filename = normname(filename)
+                self.check_reserved_name(filename)
+                originpath = self.join(filename)
+                if not os.path.isfile(originpath):
+                    raise util.Abort(_("patch %s does not exist") % filename)
+
+                if patchname:
+                    self.check_reserved_name(patchname)
+                    checkfile(patchname)
+
+                    self.ui.write(_('renaming %s to %s\n')
+                                        % (filename, patchname))
+                    util.rename(originpath, self.join(patchname))
+                else:
+                    patchname = filename
+
             else:
                 try:
                     if filename == '-':
@@ -1810,6 +1822,10 @@
     To import a patch from standard input, pass - as the patch file.
     When importing from standard input, a patch name must be specified
     using the --name flag.
+
+    To import an existing patch while renaming it::
+
+      hg qimport -e existing-patch -n new-name
     """
     q = repo.mq
     try:
@@ -1919,7 +1935,7 @@
         if qbase:
             ui.note(_('stripping applied patches from destination '
                       'repository\n'))
-            dr.mq.strip(dr, qbase, update=False, backup=None)
+            dr.mq.strip(dr, [qbase], update=False, backup=None)
         if not opts['noupdate']:
             ui.note(_('updating destination repository\n'))
             hg.update(dr, dr.changelog.tip())
@@ -2003,7 +2019,7 @@
     """
     msg = cmdutil.logmessage(opts)
     def getmsg():
-        return ui.edit(msg, ui.username())
+        return ui.edit(msg, opts['user'] or ui.username())
     q = repo.mq
     opts['msg'] = msg
     if opts.get('edit'):
@@ -2156,7 +2172,15 @@
     '''
     def status(idx):
         guards = q.series_guards[idx] or ['unguarded']
-        ui.write('%s: ' % ui.label(q.series[idx], 'qguard.patch'))
+        if q.series[idx] in applied:
+            state = 'applied'
+        elif q.pushable(idx)[0]:
+            state = 'unapplied'
+        else:
+            state = 'guarded'
+        label = 'qguard.patch qguard.%s qseries.%s' % (state, state)
+        ui.write('%s: ' % ui.label(q.series[idx], label))
+
         for i, guard in enumerate(guards):
             if guard.startswith('+'):
                 ui.write(guard, label='qguard.positive')
@@ -2168,6 +2192,7 @@
                 ui.write(' ')
         ui.write('\n')
     q = repo.mq
+    applied = set(p.name for p in q.applied)
     patch = None
     args = list(args)
     if opts['list']:
@@ -2381,14 +2406,12 @@
             pass
     return 0
 
-def strip(ui, repo, rev, **opts):
-    """strip a changeset and all its descendants from the repository
-
-    The strip command removes all changesets whose local revision
-    number is greater than or equal to REV, and then restores any
-    changesets that are not descendants of REV. If the working
-    directory has uncommitted changes, the operation is aborted unless
-    the --force flag is supplied.
+def strip(ui, repo, *revs, **opts):
+    """strip changesets and all their descendants from the repository
+
+    The strip command removes the specified changesets and all their
+    descendants. If the working directory has uncommitted changes,
+    the operation is aborted unless the --force flag is supplied.
 
     If a parent of the working directory is stripped, then the working
     directory will automatically be updated to the most recent
@@ -2411,30 +2434,42 @@
     elif opts['nobackup']:
         backup = 'none'
 
-    rev = repo.lookup(rev)
-    p = repo.dirstate.parents()
     cl = repo.changelog
-    update = True
-    if p[0] == nullid:
-        update = False
-    elif p[1] == nullid and rev != cl.ancestor(p[0], rev):
-        update = False
-    elif rev not in (cl.ancestor(p[0], rev), cl.ancestor(p[1], rev)):
-        update = False
+    revs = set(cl.rev(repo.lookup(r)) for r in revs)
+
+    descendants = set(cl.descendants(*revs))
+    strippedrevs = revs.union(descendants)
+    roots = revs.difference(descendants)
+
+    update = False
+    # if one of the wdir parent is stripped we'll need
+    # to update away to an earlier revision
+    for p in repo.dirstate.parents():
+        if p != nullid and cl.rev(p) in strippedrevs:
+            update = True
+            break
+
+    rootnodes = set(cl.node(r) for r in roots)
 
     q = repo.mq
     if q.applied:
-        if rev == cl.ancestor(repo.lookup('qtip'), rev):
+        # refresh queue state if we're about to strip
+        # applied patches
+        if cl.rev(repo.lookup('qtip')) in strippedrevs:
             q.applied_dirty = True
             start = 0
             end = len(q.applied)
-            applied_list = [i.node for i in q.applied]
-            if rev in applied_list:
-                start = applied_list.index(rev)
+            for i, statusentry in enumerate(q.applied):
+                if statusentry.node in rootnodes:
+                    # if one of the stripped roots is an applied
+                    # patch, only part of the queue is stripped
+                    start = i
+                    break
             del q.applied[start:end]
             q.save_dirty()
 
-    repo.mq.strip(repo, rev, backup=backup, update=update, force=opts['force'])
+    repo.mq.strip(repo, list(rootnodes), backup=backup, update=update,
+                  force=opts['force'])
     return 0
 
 def select(ui, repo, *args, **opts):
@@ -2559,7 +2594,7 @@
     if not opts['applied'] and not revrange:
         raise util.Abort(_('no revisions specified'))
     elif opts['applied']:
-        revrange = ('qbase:qtip',) + revrange
+        revrange = ('qbase::qtip',) + revrange
 
     q = repo.mq
     if not q.applied:
@@ -2648,7 +2683,7 @@
         current = _getcurrent()
         for queue in _getqueues():
             ui.write('%s' % (queue,))
-            if queue == current:
+            if queue == current and not ui.quiet:
                 ui.write(_(' (active)\n'))
             else:
                 ui.write('\n')
@@ -2993,7 +3028,7 @@
                                   ' number greater than REV which are not'
                                   ' descendants of REV (DEPRECATED)')),
            ('n', 'nobackup', None, _('no backups'))],
-          _('hg strip [-f] [-n] REV')),
+          _('hg strip [-f] [-n] REV...')),
      "qtop": (top, [] + seriesopts, _('hg qtop [-s]')),
     "qunapplied":
         (unapplied,
--- a/hgext/rebase.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/rebase.py	Sat Aug 14 03:30:35 2010 +0200
@@ -148,9 +148,14 @@
             targetancestors = set(repo.changelog.ancestors(target))
             targetancestors.add(target)
 
-        for rev in sorted(state):
+        sortedstate = sorted(state)
+        total = len(sortedstate)
+        pos = 0
+        for rev in sortedstate:
+            pos += 1
             if state[rev] == -1:
-                ui.debug("rebasing %d:%s\n" % (rev, repo[rev]))
+                ui.progress(_("rebasing"), pos, ("%d:%s" % (rev, repo[rev])),
+                            _(' changesets'), total)
                 storestatus(repo, originalwd, target, state, collapsef, keepf,
                                                     keepbranchesf, external)
                 p1, p2 = defineparents(repo, rev, target, state,
@@ -179,6 +184,7 @@
                         skipped.add(rev)
                     state[rev] = p1
 
+        ui.progress(_('rebasing'), None)
         ui.note(_('rebase merging completed\n'))
 
         if collapsef and not keepopen:
--- a/hgext/record.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/hgext/record.py	Sat Aug 14 03:30:35 2010 +0200
@@ -10,7 +10,7 @@
 from mercurial.i18n import gettext, _
 from mercurial import cmdutil, commands, extensions, hg, mdiff, patch
 from mercurial import util
-import copy, cStringIO, errno, operator, os, re, tempfile
+import copy, cStringIO, errno, os, re, tempfile
 
 lines_re = re.compile(r'@@ -(\d+),(\d+) \+(\d+),(\d+) @@\s*(.*)')
 
@@ -97,7 +97,7 @@
             if h.startswith('---'):
                 fp.write(_('%d hunks, %d lines changed\n') %
                          (len(self.hunks),
-                          sum([h.added + h.removed for h in self.hunks])))
+                          sum([max(h.added, h.removed) for h in self.hunks])))
                 break
             fp.write(h)
 
@@ -186,7 +186,8 @@
             self.hunk = []
             self.stream = []
 
-        def addrange(self, (fromstart, fromend, tostart, toend, proc)):
+        def addrange(self, limits):
+            fromstart, fromend, tostart, toend, proc = limits
             self.fromline = int(fromstart)
             self.toline = int(tostart)
             self.proc = proc
@@ -354,8 +355,8 @@
                 applied[chunk.filename()].append(chunk)
             else:
                 fixoffset += chunk.removed - chunk.added
-    return reduce(operator.add, [h for h in applied.itervalues()
-                                 if h[0].special() or len(h) > 1], [])
+    return sum([h for h in applied.itervalues()
+               if h[0].special() or len(h) > 1], [])
 
 def record(ui, repo, *pats, **opts):
     '''interactively select changes to commit
@@ -485,7 +486,8 @@
 
             # 3a. apply filtered patch to clean repo  (clean)
             if backups:
-                hg.revert(repo, repo.dirstate.parents()[0], backups.has_key)
+                hg.revert(repo, repo.dirstate.parents()[0],
+                          lambda key: key in backups)
 
             # 3b. (apply)
             if dopatch:
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/i18n/ro.po	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,12277 @@
+# Romanian translation for Mercurial
+# Traducerea în limba română pentru Mercurial
+#
+# Copyright (C) 2010 Matt Mackall <mpm@selenic.com> and others
+#
+#
+# Glosar de traduceri
+# ===================
+# abort		a întrerupe, a renunța
+# branch	ramură
+# bundle	pachet (fascicul), a crea un pachet
+# change	modificare
+# changeset	set de modificări
+# changegroup	grup de modificări
+# check out	a actualiza, a extrage, checkout
+# commit	depozitare, predare, încredințare, commit
+# commit (v)	a depozita, a preda, a încredința, commit
+# consistency	consistență (termen informatic; sens general: coerență)
+# deprecated	învechit
+# discard	a înlătura, a renunța la
+# head		capăt
+# hook		hook, acțiune, ancoră
+# merge		a fuziona (a contopi, a îmbina)
+# notation	notație
+# remove	a elimina
+# repository	depozit (magazie)
+# resolve	a determina [[a rezolva]]
+# manage	a gestiona
+# manifest	manifest (și în română, ca "declarație/listă de mărfuri")
+# pull		(pull), a aduce, a trage, a extrage,
+# push		(push), a duce, a împinge, a difuza, a distribui
+# retrieve	a recupera, a regăsi
+# switch	a comuta
+# tag		etichetă / a eticheta
+# tip		vârf
+# track		a urmări
+# update	a actualiza
+#
+#
+# NOTĂ: - Terminologia de mai sus este departe de a fi completă sau perfectă.
+#         De completat și ameliorat
+# 	- Primul termen este cel considerat momentan cel mai potrivit.
+# 	- Măcar pentru primele versiuni, se recomandă păstrarea în paranteze
+# 	  a termenului englezesc, mai ales în cazul comenzilor.
+#
+# Câteva reguli:
+# - în ajutorul pentru o comandă, primul rând începe cu un verb
+#   la prezent fără majusculă
+# - în ajutorul pentru o comandă, descrierea opțiunilor se face
+#   printr-un verb la prezent, pers. a 3-a singular
+#
+# Dicționar de termeni curenți:
+#  - a   patch queue/stack    o stivă de patch-uri (mq)
+#  - the patch series         seria/suita (completă) de patch-uri
+#  -     rejects              respingeri, rejectări
+#  - to  revert               a reveni
+#  - the topmost patch        ultimul patch aplicat
+#  - an  unrelated repository un depozit neînrudit
+#  -     unversioned			neversionat
+#        unmanaged			negestionat
+#        untracked			neurmărit
+#  - the working directory    directorul de lucru
+#
+# Termeni de păstrat din engleză:
+#  - a   diff                 un diff
+#  - a   hook                 un hook
+#  - a   patch                un patch
+#
+# Daniel Dumitriu <daniel.dumitriu@gmail.com>, 2010.
+msgid ""
+msgstr ""
+"Project-Id-Version: Mercurial\n"
+"Report-Msgid-Bugs-To: <mercurial-devel@selenic.com>\n"
+"POT-Creation-Date: 2010-08-05 16:06+0200\n"
+"PO-Revision-Date: 2010-08-05 15:49+0200\n"
+"Last-Translator: Daniel Dumitriu <daniel.dumitriu@gmail.com>\n"
+"Language-Team: Romanian <>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: Plural-Forms: nplurals=3; plural=n==1 ? 0 : (n==0 || (n%100 > "
+"0 && n%100 < 20)) ? 1 : 2;\n"
+"X-Generator: Lokalize 1.0\n"
+
+#, python-format
+msgid " (default: %s)"
+msgstr "(implicit: %s)"
+
+msgid "Options"
+msgstr "Opțiuni"
+
+msgid "Commands"
+msgstr "Comenzi"
+
+msgid "    options:"
+msgstr "    opțiuni:"
+
+#, python-format
+msgid "    aliases: %s"
+msgstr "    alias: %s"
+
+msgid "hooks for controlling repository access"
+msgstr "hook-uri pentru controlul accesului la depozit"
+
+msgid ""
+"This hook makes it possible to allow or deny write access to given\n"
+"branches and paths of a repository when receiving incoming changesets\n"
+"via pretxnchangegroup and pretxncommit."
+msgstr ""
+"Acest hook realizează permiterea sau interzicerea accesului\n"
+"în scriere la anumite ramuri și căi ale unui depozit, atunci când \n"
+"se primesc seturi de modificări prin pretxnchangegroup și pretxncommit."
+
+msgid ""
+"The authorization is matched based on the local user name on the\n"
+"system where the hook runs, and not the committer of the original\n"
+"changeset (since the latter is merely informative)."
+msgstr ""
+"Autorizația este căutată pe baza numelui de utilizator local\n"
+"de pe sistemul unde rulează hook-ul, nu pe baza numelui celui care a\n"
+"publicat setul de modificări original (pentru că acesta e pur informativ)."
+
+msgid ""
+"The acl hook is best used along with a restricted shell like hgsh,\n"
+"preventing authenticating users from doing anything other than pushing\n"
+"or pulling. The hook is not safe to use if users have interactive\n"
+"shell access, as they can then disable the hook. Nor is it safe if\n"
+"remote users share an account, because then there is no way to\n"
+"distinguish them."
+msgstr ""
+"Hook-ul acl e folosit optim împreună cu un shell restrictiv precum\n"
+"hgsh, care împiedică utilizatorii care doresc să se autentifice să aibă "
+"alte\n"
+"acțiuni în afară de push și pull. Hook-ul nu prezintă siguranță dacă\n"
+"utilizatorii au acces la shell interactiv, deoarece astfel ei pot dezactiva\n"
+"hook-ul. De asemenea, nu prezintă siguranță situația în care utilizatorii\n"
+"de la distanță partajează un cont, deoarece nu există posibilitatea de\n"
+"a-i distinge."
+
+msgid "The order in which access checks are performed is:"
+msgstr "Ordinea în care se fac verificările de acces este:"
+
+msgid ""
+"1) Deny  list for branches (section ``acl.deny.branches``)\n"
+"2) Allow list for branches (section ``acl.allow.branches``)\n"
+"3) Deny  list for paths    (section ``acl.deny``)\n"
+"4) Allow list for paths    (section ``acl.allow``)"
+msgstr ""
+"1) Lista cu interdicții pentru ramuri (secțiunea ``acl.deny.branches``)\n"
+"2) Lista cu permisiuni  pentru ramuri (secțiunea ``acl.allow.branches``)\n"
+"3) Lista cu interdicții pentru căi    (secțiunea ``acl.deny``)\n"
+"4) Lista cu permisiuni  pentru căi    (secțiunea ``acl.allow``)"
+
+msgid "The allow and deny sections take key-value pairs."
+msgstr "Secțiunile cu permisiuni și interdicții conțin perechi cheie-valoare."
+
+msgid ""
+"Branch-based Access Control\n"
+"---------------------------"
+msgstr ""
+"Controlul accesului pe bază de ramură\n"
+"-------------------------------------"
+
+msgid ""
+"Use the ``acl.deny.branches`` and ``acl.allow.branches`` sections to\n"
+"have branch-based access control. Keys in these sections can be\n"
+"either:"
+msgstr ""
+"Utilizați secțiunile ``acl.deny.branches`` și ``acl.allow.branches``\n"
+"pentru a avea controlul accesului pe baza ramurii. În aceste secțiuni,\n"
+"cheile pot fi:"
+
+msgid ""
+"- a branch name, or\n"
+"- an asterisk, to match any branch;"
+msgstr ""
+"- un nume de ramură, sau\n"
+"- un asterisc, însemnând orice ramură;"
+
+msgid "The corresponding values can be either:"
+msgstr "Valorile corespunzatoare pot fi:"
+
+msgid ""
+"- a comma-separated list containing users and groups, or\n"
+"- an asterisk, to match anyone;"
+msgstr ""
+"- o listă separată prin virgule conținând utilizatori și grupuri, sau\n"
+"- un asterisc, însemnând oricine;"
+
+msgid ""
+"Path-based Access Control\n"
+"-------------------------"
+msgstr ""
+
+msgid ""
+"Use the ``acl.deny`` and ``acl.allow`` sections to have path-based\n"
+"access control. Keys in these sections accept a subtree pattern (with\n"
+"a glob syntax by default). The corresponding values follow the same\n"
+"syntax as the other sections above."
+msgstr ""
+
+msgid ""
+"Groups\n"
+"------"
+msgstr ""
+
+msgid ""
+"Group names must be prefixed with an ``@`` symbol. Specifying a group\n"
+"name has the same effect as specifying all the users in that group."
+msgstr ""
+
+msgid ""
+"You can define group members in the ``acl.groups`` section.\n"
+"If a group name is not defined there, and Mercurial is running under\n"
+"a Unix-like system, the list of users will be taken from the OS.\n"
+"Otherwise, an exception will be raised."
+msgstr ""
+
+msgid ""
+"Example Configuration\n"
+"---------------------"
+msgstr ""
+
+msgid "::"
+msgstr ""
+
+msgid "  [hooks]"
+msgstr ""
+
+msgid ""
+"  # Use this if you want to check access restrictions at commit time\n"
+"  pretxncommit.acl = python:hgext.acl.hook"
+msgstr ""
+
+msgid ""
+"  # Use this if you want to check access restrictions for pull, push,\n"
+"  # bundle and serve.\n"
+"  pretxnchangegroup.acl = python:hgext.acl.hook"
+msgstr ""
+
+msgid ""
+"  [acl]\n"
+"  # Allow or deny access for incoming changes only if their source is\n"
+"  # listed here, let them pass otherwise. Source is \"serve\" for all\n"
+"  # remote access (http or ssh), \"push\", \"pull\" or \"bundle\" when the\n"
+"  # related commands are run locally.\n"
+"  # Default: serve\n"
+"  sources = serve"
+msgstr ""
+
+msgid "  [acl.deny.branches]"
+msgstr ""
+
+msgid ""
+"  # Everyone is denied to the frozen branch:\n"
+"  frozen-branch = *"
+msgstr ""
+
+msgid ""
+"  # A bad user is denied on all branches:\n"
+"  * = bad-user"
+msgstr ""
+
+msgid "  [acl.allow.branches]"
+msgstr ""
+
+msgid ""
+"  # A few users are allowed on branch-a:\n"
+"  branch-a = user-1, user-2, user-3"
+msgstr ""
+
+msgid ""
+"  # Only one user is allowed on branch-b:\n"
+"  branch-b = user-1"
+msgstr ""
+
+msgid ""
+"  # The super user is allowed on any branch:\n"
+"  * = super-user"
+msgstr ""
+
+msgid ""
+"  # Everyone is allowed on branch-for-tests:\n"
+"  branch-for-tests = *"
+msgstr ""
+
+msgid ""
+"  [acl.deny]\n"
+"  # This list is checked first. If a match is found, acl.allow is not\n"
+"  # checked. All users are granted access if acl.deny is not present.\n"
+"  # Format for both lists: glob pattern = user, ..., @group, ..."
+msgstr ""
+
+msgid ""
+"  # To match everyone, use an asterisk for the user:\n"
+"  # my/glob/pattern = *"
+msgstr ""
+
+msgid ""
+"  # user6 will not have write access to any file:\n"
+"  ** = user6"
+msgstr ""
+
+msgid ""
+"  # Group \"hg-denied\" will not have write access to any file:\n"
+"  ** = @hg-denied"
+msgstr ""
+
+msgid ""
+"  # Nobody will be able to change \"DONT-TOUCH-THIS.txt\", despite\n"
+"  # everyone being able to change all other files. See below.\n"
+"  src/main/resources/DONT-TOUCH-THIS.txt = *"
+msgstr ""
+
+msgid ""
+"  [acl.allow]\n"
+"  # if acl.allow is not present, all users are allowed by default\n"
+"  # empty acl.allow = no users allowed"
+msgstr ""
+
+msgid ""
+"  # User \"doc_writer\" has write access to any file under the \"docs\"\n"
+"  # folder:\n"
+"  docs/** = doc_writer"
+msgstr ""
+
+msgid ""
+"  # User \"jack\" and group \"designers\" have write access to any file\n"
+"  # under the \"images\" folder:\n"
+"  images/** = jack, @designers"
+msgstr ""
+
+msgid ""
+"  # Everyone (except for \"user6\" - see acl.deny above) will have write\n"
+"  # access to any file under the \"resources\" folder (except for 1\n"
+"  # file. See acl.deny):\n"
+"  src/main/resources/** = *"
+msgstr ""
+
+msgid "  .hgtags = release_engineer"
+msgstr ""
+
+#, python-format
+msgid "group '%s' is undefined"
+msgstr ""
+
+#, python-format
+msgid ""
+"config error - hook type \"%s\" cannot stop incoming changesets nor commits"
+msgstr ""
+
+#, python-format
+msgid "acl: user \"%s\" denied on branch \"%s\" (changeset \"%s\")"
+msgstr ""
+
+#, python-format
+msgid "acl: user \"%s\" not allowed on branch \"%s\" (changeset \"%s\")"
+msgstr ""
+
+#, python-format
+msgid "acl: access denied for changeset %s"
+msgstr ""
+
+msgid "track a line of development with movable markers"
+msgstr ""
+
+msgid ""
+"Bookmarks are local movable markers to changesets. Every bookmark\n"
+"points to a changeset identified by its hash. If you commit a\n"
+"changeset that is based on a changeset that has a bookmark on it, the\n"
+"bookmark shifts to the new changeset."
+msgstr ""
+
+msgid ""
+"It is possible to use bookmark names in every revision lookup (e.g.\n"
+":hg:`merge`, :hg:`update`)."
+msgstr ""
+
+msgid ""
+"By default, when several bookmarks point to the same changeset, they\n"
+"will all move forward together. It is possible to obtain a more\n"
+"git-like experience by adding the following configuration option to\n"
+"your .hgrc::"
+msgstr ""
+
+msgid ""
+"  [bookmarks]\n"
+"  track.current = True"
+msgstr ""
+
+msgid ""
+"This will cause Mercurial to track the bookmark that you are currently\n"
+"using, and only update it. This is similar to git's approach to\n"
+"branching.\n"
+msgstr ""
+
+msgid ""
+"    Bookmarks are pointers to certain commits that move when\n"
+"    committing. Bookmarks are local. They can be renamed, copied and\n"
+"    deleted. It is possible to use bookmark names in :hg:`merge` and\n"
+"    :hg:`update` to merge and update respectively to a given bookmark."
+msgstr ""
+
+msgid ""
+"    You can use :hg:`bookmark NAME` to set a bookmark on the working\n"
+"    directory's parent revision with the given name. If you specify\n"
+"    a revision using -r REV (where REV may be an existing bookmark),\n"
+"    the bookmark is assigned to that revision.\n"
+"    "
+msgstr ""
+
+msgid "a bookmark of this name does not exist"
+msgstr ""
+
+msgid "a bookmark of the same name already exists"
+msgstr ""
+
+msgid "new bookmark name required"
+msgstr ""
+
+msgid "bookmark name required"
+msgstr ""
+
+msgid "bookmark name cannot contain newlines"
+msgstr ""
+
+msgid "bookmark names cannot consist entirely of whitespace"
+msgstr ""
+
+msgid "a bookmark cannot have the name of an existing branch"
+msgstr ""
+
+msgid "no bookmarks set\n"
+msgstr ""
+
+#, python-format
+msgid "updating bookmark %s\n"
+msgstr ""
+
+#, python-format
+msgid "not updating divergent bookmark %s\n"
+msgstr ""
+
+#, python-format
+msgid "updating bookmark %s failed!\n"
+msgstr ""
+
+#, python-format
+msgid "remote bookmark %s not found!"
+msgstr ""
+
+#, python-format
+msgid "importing bookmark %s\n"
+msgstr ""
+
+#, python-format
+msgid "exporting bookmark %s\n"
+msgstr ""
+
+#, python-format
+msgid "deleting remote bookmark %s\n"
+msgstr ""
+
+msgid "searching for changes\n"
+msgstr "se caută modificări\n"
+
+msgid "no changes found\n"
+msgstr ""
+
+#, python-format
+msgid "comparing with %s\n"
+msgstr ""
+
+msgid "bookmark to import"
+msgstr ""
+
+msgid "bookmark to export"
+msgstr ""
+
+msgid "compare bookmark"
+msgstr ""
+
+msgid "force"
+msgstr ""
+
+msgid "REV"
+msgstr "REV"
+
+msgid "revision"
+msgstr "revizia"
+
+msgid "delete a given bookmark"
+msgstr ""
+
+msgid "NAME"
+msgstr "NUME"
+
+msgid "rename a given bookmark"
+msgstr ""
+
+msgid "hg bookmarks [-f] [-d] [-m NAME] [-r REV] [NAME]"
+msgstr ""
+
+msgid "hooks for integrating with the Bugzilla bug tracker"
+msgstr ""
+
+msgid ""
+"This hook extension adds comments on bugs in Bugzilla when changesets\n"
+"that refer to bugs by Bugzilla ID are seen. The hook does not change\n"
+"bug status."
+msgstr ""
+
+msgid ""
+"The hook updates the Bugzilla database directly. Only Bugzilla\n"
+"installations using MySQL are supported."
+msgstr ""
+
+msgid ""
+"The hook relies on a Bugzilla script to send bug change notification\n"
+"emails. That script changes between Bugzilla versions; the\n"
+"'processmail' script used prior to 2.18 is replaced in 2.18 and\n"
+"subsequent versions by 'config/sendbugmail.pl'. Note that these will\n"
+"be run by Mercurial as the user pushing the change; you will need to\n"
+"ensure the Bugzilla install file permissions are set appropriately."
+msgstr ""
+
+msgid ""
+"The extension is configured through three different configuration\n"
+"sections. These keys are recognized in the [bugzilla] section:"
+msgstr ""
+
+msgid ""
+"host\n"
+"  Hostname of the MySQL server holding the Bugzilla database."
+msgstr ""
+
+msgid ""
+"db\n"
+"  Name of the Bugzilla database in MySQL. Default 'bugs'."
+msgstr ""
+
+msgid ""
+"user\n"
+"  Username to use to access MySQL server. Default 'bugs'."
+msgstr ""
+
+msgid ""
+"password\n"
+"  Password to use to access MySQL server."
+msgstr ""
+
+msgid ""
+"timeout\n"
+"  Database connection timeout (seconds). Default 5."
+msgstr ""
+
+msgid ""
+"version\n"
+"  Bugzilla version. Specify '3.0' for Bugzilla versions 3.0 and later,\n"
+"  '2.18' for Bugzilla versions from 2.18 and '2.16' for versions prior\n"
+"  to 2.18."
+msgstr ""
+
+msgid ""
+"bzuser\n"
+"  Fallback Bugzilla user name to record comments with, if changeset\n"
+"  committer cannot be found as a Bugzilla user."
+msgstr ""
+
+msgid ""
+"bzdir\n"
+"   Bugzilla install directory. Used by default notify. Default\n"
+"   '/var/www/html/bugzilla'."
+msgstr ""
+
+msgid ""
+"notify\n"
+"  The command to run to get Bugzilla to send bug change notification\n"
+"  emails. Substitutes from a map with 3 keys, 'bzdir', 'id' (bug id)\n"
+"  and 'user' (committer bugzilla email). Default depends on version;\n"
+"  from 2.18 it is \"cd %(bzdir)s && perl -T contrib/sendbugmail.pl\n"
+"  %(id)s %(user)s\"."
+msgstr ""
+
+msgid ""
+"regexp\n"
+"  Regular expression to match bug IDs in changeset commit message.\n"
+"  Must contain one \"()\" group. The default expression matches 'Bug\n"
+"  1234', 'Bug no. 1234', 'Bug number 1234', 'Bugs 1234,5678', 'Bug\n"
+"  1234 and 5678' and variations thereof. Matching is case insensitive."
+msgstr ""
+
+msgid ""
+"style\n"
+"  The style file to use when formatting comments."
+msgstr ""
+
+msgid ""
+"template\n"
+"  Template to use when formatting comments. Overrides style if\n"
+"  specified. In addition to the usual Mercurial keywords, the\n"
+"  extension specifies::"
+msgstr ""
+
+msgid ""
+"    {bug}       The Bugzilla bug ID.\n"
+"    {root}      The full pathname of the Mercurial repository.\n"
+"    {webroot}   Stripped pathname of the Mercurial repository.\n"
+"    {hgweb}     Base URL for browsing Mercurial repositories."
+msgstr ""
+
+msgid ""
+"  Default 'changeset {node|short} in repo {root} refers '\n"
+"          'to bug {bug}.\\ndetails:\\n\\t{desc|tabindent}'"
+msgstr ""
+
+msgid ""
+"strip\n"
+"  The number of slashes to strip from the front of {root} to produce\n"
+"  {webroot}. Default 0."
+msgstr ""
+
+msgid ""
+"usermap\n"
+"  Path of file containing Mercurial committer ID to Bugzilla user ID\n"
+"  mappings. If specified, the file should contain one mapping per\n"
+"  line, \"committer\"=\"Bugzilla user\". See also the [usermap] section."
+msgstr ""
+
+msgid ""
+"The [usermap] section is used to specify mappings of Mercurial\n"
+"committer ID to Bugzilla user ID. See also [bugzilla].usermap.\n"
+"\"committer\"=\"Bugzilla user\""
+msgstr ""
+
+msgid "Finally, the [web] section supports one entry:"
+msgstr ""
+
+msgid ""
+"baseurl\n"
+"  Base URL for browsing Mercurial repositories. Reference from\n"
+"  templates as {hgweb}."
+msgstr ""
+
+msgid "Activating the extension::"
+msgstr ""
+
+msgid ""
+"    [extensions]\n"
+"    bugzilla ="
+msgstr ""
+
+msgid ""
+"    [hooks]\n"
+"    # run bugzilla hook on every change pulled or pushed in here\n"
+"    incoming.bugzilla = python:hgext.bugzilla.hook"
+msgstr ""
+
+msgid "Example configuration:"
+msgstr ""
+
+msgid ""
+"This example configuration is for a collection of Mercurial\n"
+"repositories in /var/local/hg/repos/ used with a local Bugzilla 3.2\n"
+"installation in /opt/bugzilla-3.2. ::"
+msgstr ""
+
+msgid ""
+"    [bugzilla]\n"
+"    host=localhost\n"
+"    password=XYZZY\n"
+"    version=3.0\n"
+"    bzuser=unknown@domain.com\n"
+"    bzdir=/opt/bugzilla-3.2\n"
+"    template=Changeset {node|short} in {root|basename}.\n"
+"             {hgweb}/{webroot}/rev/{node|short}\\n\n"
+"             {desc}\\n\n"
+"    strip=5"
+msgstr ""
+
+msgid ""
+"    [web]\n"
+"    baseurl=http://dev.domain.com/hg"
+msgstr ""
+
+msgid ""
+"    [usermap]\n"
+"    user@emaildomain.com=user.name@bugzilladomain.com"
+msgstr ""
+
+msgid "Commits add a comment to the Bugzilla bug record of the form::"
+msgstr ""
+
+msgid ""
+"    Changeset 3b16791d6642 in repository-name.\n"
+"    http://dev.domain.com/hg/repository-name/rev/3b16791d6642"
+msgstr ""
+
+msgid "    Changeset commit comment. Bug 1234.\n"
+msgstr ""
+
+#, python-format
+msgid "connecting to %s:%s as %s, password %s\n"
+msgstr ""
+
+#, python-format
+msgid "query: %s %s\n"
+msgstr ""
+
+#, python-format
+msgid "failed query: %s %s\n"
+msgstr ""
+
+msgid "unknown database schema"
+msgstr ""
+
+#, python-format
+msgid "bug %d already knows about changeset %s\n"
+msgstr ""
+
+msgid "telling bugzilla to send mail:\n"
+msgstr ""
+
+#, python-format
+msgid "  bug %s\n"
+msgstr ""
+
+#, python-format
+msgid "running notify command %s\n"
+msgstr ""
+
+#, python-format
+msgid "bugzilla notify command %s"
+msgstr ""
+
+msgid "done\n"
+msgstr ""
+
+#, python-format
+msgid "looking up user %s\n"
+msgstr ""
+
+#, python-format
+msgid "cannot find bugzilla user id for %s"
+msgstr ""
+
+#, python-format
+msgid "cannot find bugzilla user id for %s or %s"
+msgstr ""
+
+#, python-format
+msgid "bugzilla version %s not supported"
+msgstr ""
+
+msgid ""
+"changeset {node|short} in repo {root} refers to bug {bug}.\n"
+"details:\n"
+"\t{desc|tabindent}"
+msgstr ""
+
+#, python-format
+msgid "python mysql support not available: %s"
+msgstr ""
+
+#, python-format
+msgid "hook type %s does not pass a changeset id"
+msgstr ""
+
+#, python-format
+msgid "database error: %s"
+msgstr ""
+
+msgid "command to display child changesets"
+msgstr ""
+
+msgid "show the children of the given or working directory revision"
+msgstr ""
+
+msgid ""
+"    Print the children of the working directory's revisions. If a\n"
+"    revision is given via -r/--rev, the children of that revision will\n"
+"    be printed. If a file argument is given, revision in which the\n"
+"    file was last changed (after the working directory revision or the\n"
+"    argument to --rev if given) is printed.\n"
+"    "
+msgstr ""
+
+msgid "show children of the specified revision"
+msgstr ""
+
+msgid "hg children [-r REV] [FILE]"
+msgstr ""
+
+msgid "command to display statistics about repository history"
+msgstr ""
+
+#, python-format
+msgid "Revision %d is a merge, ignoring...\n"
+msgstr ""
+
+msgid "analyzing"
+msgstr ""
+
+msgid "histogram of changes to the repository"
+msgstr ""
+
+msgid ""
+"    This command will display a histogram representing the number\n"
+"    of changed lines or revisions, grouped according to the given\n"
+"    template. The default template will group changes by author.\n"
+"    The --dateformat option may be used to group the results by\n"
+"    date instead."
+msgstr ""
+
+msgid ""
+"    Statistics are based on the number of changed lines, or\n"
+"    alternatively the number of matching revisions if the\n"
+"    --changesets option is specified."
+msgstr ""
+
+msgid "    Examples::"
+msgstr ""
+
+msgid ""
+"      # display count of changed lines for every committer\n"
+"      hg churn -t '{author|email}'"
+msgstr ""
+
+msgid ""
+"      # display daily activity graph\n"
+"      hg churn -f '%H' -s -c"
+msgstr ""
+
+msgid ""
+"      # display activity of developers by month\n"
+"      hg churn -f '%Y-%m' -s -c"
+msgstr ""
+
+msgid ""
+"      # display count of lines changed in every year\n"
+"      hg churn -f '%Y' -s"
+msgstr ""
+
+msgid ""
+"    It is possible to map alternate email addresses to a main address\n"
+"    by providing a file using the following format::"
+msgstr ""
+
+msgid "      <alias email> = <actual email>"
+msgstr "      <email alias> = <email actual>"
+
+msgid ""
+"    Such a file may be specified with the --aliases option, otherwise\n"
+"    a .hgchurn file will be looked for in the working directory root.\n"
+"    "
+msgstr ""
+
+msgid "count rate for the specified revision or range"
+msgstr ""
+
+msgid "DATE"
+msgstr ""
+
+msgid "count rate for revisions matching date spec"
+msgstr ""
+
+msgid "TEMPLATE"
+msgstr ""
+
+msgid "template to group changesets"
+msgstr ""
+
+msgid "FORMAT"
+msgstr ""
+
+msgid "strftime-compatible format for grouping by date"
+msgstr ""
+
+msgid "count rate by number of changesets"
+msgstr ""
+
+msgid "sort by key (default: sort by count)"
+msgstr ""
+
+msgid "display added/removed lines separately"
+msgstr ""
+
+msgid "FILE"
+msgstr ""
+
+msgid "file with email aliases"
+msgstr ""
+
+msgid "hg churn [-d DATE] [-r REV] [--aliases FILE] [FILE]"
+msgstr ""
+
+msgid "colorize output from some commands"
+msgstr ""
+
+msgid ""
+"This extension modifies the status and resolve commands to add color to "
+"their\n"
+"output to reflect file status, the qseries command to add color to reflect\n"
+"patch status (applied, unapplied, missing), and to diff-related\n"
+"commands to highlight additions, removals, diff headers, and trailing\n"
+"whitespace."
+msgstr ""
+
+msgid ""
+"Other effects in addition to color, like bold and underlined text, are\n"
+"also available. Effects are rendered with the ECMA-48 SGR control\n"
+"function (aka ANSI escape codes). This module also provides the\n"
+"render_text function, which can be used to add effects to any text."
+msgstr ""
+
+msgid "Default effects may be overridden from the .hgrc file::"
+msgstr ""
+
+msgid ""
+"  [color]\n"
+"  status.modified = blue bold underline red_background\n"
+"  status.added = green bold\n"
+"  status.removed = red bold blue_background\n"
+"  status.deleted = cyan bold underline\n"
+"  status.unknown = magenta bold underline\n"
+"  status.ignored = black bold"
+msgstr ""
+
+msgid ""
+"  # 'none' turns off all effects\n"
+"  status.clean = none\n"
+"  status.copied = none"
+msgstr ""
+
+msgid ""
+"  qseries.applied = blue bold underline\n"
+"  qseries.unapplied = black bold\n"
+"  qseries.missing = red bold"
+msgstr ""
+
+msgid ""
+"  diff.diffline = bold\n"
+"  diff.extended = cyan bold\n"
+"  diff.file_a = red bold\n"
+"  diff.file_b = green bold\n"
+"  diff.hunk = magenta\n"
+"  diff.deleted = red\n"
+"  diff.inserted = green\n"
+"  diff.changed = white\n"
+"  diff.trailingwhitespace = bold red_background"
+msgstr ""
+
+msgid ""
+"  resolve.unresolved = red bold\n"
+"  resolve.resolved = green bold"
+msgstr ""
+
+msgid "  bookmarks.current = green"
+msgstr ""
+
+msgid ""
+"The color extension will try to detect whether to use ANSI codes or\n"
+"Win32 console APIs, unless it is made explicit::"
+msgstr ""
+
+msgid ""
+"  [color]\n"
+"  mode = ansi"
+msgstr ""
+
+msgid "Any value other than 'ansi', 'win32', or 'auto' will disable color."
+msgstr ""
+
+#, python-format
+msgid "ignoring unknown color/effect %r (configured in color.%s)\n"
+msgstr ""
+
+msgid "win32console not found, please install pywin32\n"
+msgstr ""
+
+msgid "when to colorize (always, auto, or never)"
+msgstr "când să se coloreze (întotdeauna, auto, sau niciodată)"
+
+msgid "TYPE"
+msgstr ""
+
+msgid "import revisions from foreign VCS repositories into Mercurial"
+msgstr ""
+
+msgid "convert a foreign SCM repository to a Mercurial one."
+msgstr ""
+
+msgid "    Accepted source formats [identifiers]:"
+msgstr ""
+
+msgid ""
+"    - Mercurial [hg]\n"
+"    - CVS [cvs]\n"
+"    - Darcs [darcs]\n"
+"    - git [git]\n"
+"    - Subversion [svn]\n"
+"    - Monotone [mtn]\n"
+"    - GNU Arch [gnuarch]\n"
+"    - Bazaar [bzr]\n"
+"    - Perforce [p4]"
+msgstr ""
+
+msgid "    Accepted destination formats [identifiers]:"
+msgstr ""
+
+msgid ""
+"    - Mercurial [hg]\n"
+"    - Subversion [svn] (history on branches is not preserved)"
+msgstr ""
+
+msgid ""
+"    If no revision is given, all revisions will be converted.\n"
+"    Otherwise, convert will only import up to the named revision\n"
+"    (given in a format understood by the source)."
+msgstr ""
+
+msgid ""
+"    If no destination directory name is specified, it defaults to the\n"
+"    basename of the source with '-hg' appended. If the destination\n"
+"    repository doesn't exist, it will be created."
+msgstr ""
+
+msgid ""
+"    By default, all sources except Mercurial will use --branchsort.\n"
+"    Mercurial uses --sourcesort to preserve original revision numbers\n"
+"    order. Sort modes have the following effects:"
+msgstr ""
+
+msgid ""
+"    --branchsort  convert from parent to child revision when possible,\n"
+"                  which means branches are usually converted one after\n"
+"                  the other. It generates more compact repositories."
+msgstr ""
+
+msgid ""
+"    --datesort    sort revisions by date. Converted repositories have\n"
+"                  good-looking changelogs but are often an order of\n"
+"                  magnitude larger than the same ones generated by\n"
+"                  --branchsort."
+msgstr ""
+
+msgid ""
+"    --sourcesort  try to preserve source revisions order, only\n"
+"                  supported by Mercurial sources."
+msgstr ""
+
+msgid ""
+"    If <REVMAP> isn't given, it will be put in a default location\n"
+"    (<dest>/.hg/shamap by default). The <REVMAP> is a simple text file\n"
+"    that maps each source commit ID to the destination ID for that\n"
+"    revision, like so::"
+msgstr ""
+
+msgid "      <source ID> <destination ID>"
+msgstr ""
+
+msgid ""
+"    If the file doesn't exist, it's automatically created. It's\n"
+"    updated on each commit copied, so convert-repo can be interrupted\n"
+"    and can be run repeatedly to copy new commits."
+msgstr ""
+
+msgid ""
+"    The [username mapping] file is a simple text file that maps each\n"
+"    source commit author to a destination commit author. It is handy\n"
+"    for source SCMs that use unix logins to identify authors (eg:\n"
+"    CVS). One line per author mapping and the line format is:\n"
+"    srcauthor=whatever string you want"
+msgstr ""
+
+msgid ""
+"    The filemap is a file that allows filtering and remapping of files\n"
+"    and directories. Each line can contain one of the following\n"
+"    directives::"
+msgstr ""
+
+msgid "      include path/to/file-or-dir"
+msgstr ""
+
+msgid "      exclude path/to/file-or-dir"
+msgstr ""
+
+msgid "      rename path/to/source path/to/destination"
+msgstr ""
+
+msgid ""
+"    Comment lines start with '#'. A specified path matches if it\n"
+"    equals the full relative name of a file or one of its parent\n"
+"    directories. The 'include' or 'exclude' directive with the longest\n"
+"    matching path applies, so line order does not matter."
+msgstr ""
+
+msgid ""
+"    The 'include' directive causes a file, or all files under a\n"
+"    directory, to be included in the destination repository, and the\n"
+"    exclusion of all other files and directories not explicitly\n"
+"    included. The 'exclude' directive causes files or directories to\n"
+"    be omitted. The 'rename' directive renames a file or directory if\n"
+"    it is converted. To rename from a subdirectory into the root of\n"
+"    the repository, use '.' as the path to rename to."
+msgstr ""
+
+msgid ""
+"    The splicemap is a file that allows insertion of synthetic\n"
+"    history, letting you specify the parents of a revision. This is\n"
+"    useful if you want to e.g. give a Subversion merge two parents, or\n"
+"    graft two disconnected series of history together. Each entry\n"
+"    contains a key, followed by a space, followed by one or two\n"
+"    comma-separated values. The key is the revision ID in the source\n"
+"    revision control system whose parents should be modified (same\n"
+"    format as a key in .hg/shamap). The values are the revision IDs\n"
+"    (in either the source or destination revision control system) that\n"
+"    should be used as the new parents for that node. For example, if\n"
+"    you have merged \"release-1.0\" into \"trunk\", then you should\n"
+"    specify the revision on \"trunk\" as the first parent and the one on\n"
+"    the \"release-1.0\" branch as the second."
+msgstr ""
+
+msgid ""
+"    The branchmap is a file that allows you to rename a branch when it is\n"
+"    being brought in from whatever external repository. When used in\n"
+"    conjunction with a splicemap, it allows for a powerful combination\n"
+"    to help fix even the most badly mismanaged repositories and turn them\n"
+"    into nicely structured Mercurial repositories. The branchmap contains\n"
+"    lines of the form \"original_branch_name new_branch_name\".\n"
+"    \"original_branch_name\" is the name of the branch in the source\n"
+"    repository, and \"new_branch_name\" is the name of the branch is the\n"
+"    destination repository. This can be used to (for instance) move code\n"
+"    in one repository from \"default\" to a named branch."
+msgstr ""
+
+msgid ""
+"    Mercurial Source\n"
+"    ----------------"
+msgstr ""
+
+msgid ""
+"    --config convert.hg.ignoreerrors=False    (boolean)\n"
+"        ignore integrity errors when reading. Use it to fix Mercurial\n"
+"        repositories with missing revlogs, by converting from and to\n"
+"        Mercurial.\n"
+"    --config convert.hg.saverev=False         (boolean)\n"
+"        store original revision ID in changeset (forces target IDs to\n"
+"        change)\n"
+"    --config convert.hg.startrev=0            (hg revision identifier)\n"
+"        convert start revision and its descendants"
+msgstr ""
+
+msgid ""
+"    CVS Source\n"
+"    ----------"
+msgstr ""
+
+msgid ""
+"    CVS source will use a sandbox (i.e. a checked-out copy) from CVS\n"
+"    to indicate the starting point of what will be converted. Direct\n"
+"    access to the repository files is not needed, unless of course the\n"
+"    repository is :local:. The conversion uses the top level directory\n"
+"    in the sandbox to find the CVS repository, and then uses CVS rlog\n"
+"    commands to find files to convert. This means that unless a\n"
+"    filemap is given, all files under the starting directory will be\n"
+"    converted, and that any directory reorganization in the CVS\n"
+"    sandbox is ignored."
+msgstr ""
+
+msgid "    The options shown are the defaults."
+msgstr ""
+
+msgid ""
+"    --config convert.cvsps.cache=True         (boolean)\n"
+"        Set to False to disable remote log caching, for testing and\n"
+"        debugging purposes.\n"
+"    --config convert.cvsps.fuzz=60            (integer)\n"
+"        Specify the maximum time (in seconds) that is allowed between\n"
+"        commits with identical user and log message in a single\n"
+"        changeset. When very large files were checked in as part of a\n"
+"        changeset then the default may not be long enough.\n"
+"    --config convert.cvsps.mergeto='{{mergetobranch ([-\\w]+)}}'\n"
+"        Specify a regular expression to which commit log messages are\n"
+"        matched. If a match occurs, then the conversion process will\n"
+"        insert a dummy revision merging the branch on which this log\n"
+"        message occurs to the branch indicated in the regex.\n"
+"    --config convert.cvsps.mergefrom='{{mergefrombranch ([-\\w]+)}}'\n"
+"        Specify a regular expression to which commit log messages are\n"
+"        matched. If a match occurs, then the conversion process will\n"
+"        add the most recent revision on the branch indicated in the\n"
+"        regex as the second parent of the changeset.\n"
+"    --config hook.cvslog\n"
+"        Specify a Python function to be called at the end of gathering\n"
+"        the CVS log. The function is passed a list with the log entries,\n"
+"        and can modify the entries in-place, or add or delete them.\n"
+"    --config hook.cvschangesets\n"
+"        Specify a Python function to be called after the changesets\n"
+"        are calculated from the the CVS log. The function is passed\n"
+"        a list with the changeset entries, and can modify the changesets\n"
+"        in-place, or add or delete them."
+msgstr ""
+
+msgid ""
+"    An additional \"debugcvsps\" Mercurial command allows the builtin\n"
+"    changeset merging code to be run without doing a conversion. Its\n"
+"    parameters and output are similar to that of cvsps 2.1. Please see\n"
+"    the command help for more details."
+msgstr ""
+
+msgid ""
+"    Subversion Source\n"
+"    -----------------"
+msgstr ""
+
+msgid ""
+"    Subversion source detects classical trunk/branches/tags layouts.\n"
+"    By default, the supplied \"svn://repo/path/\" source URL is\n"
+"    converted as a single branch. If \"svn://repo/path/trunk\" exists it\n"
+"    replaces the default branch. If \"svn://repo/path/branches\" exists,\n"
+"    its subdirectories are listed as possible branches. If\n"
+"    \"svn://repo/path/tags\" exists, it is looked for tags referencing\n"
+"    converted branches. Default \"trunk\", \"branches\" and \"tags\" values\n"
+"    can be overridden with following options. Set them to paths\n"
+"    relative to the source URL, or leave them blank to disable auto\n"
+"    detection."
+msgstr ""
+
+msgid ""
+"    --config convert.svn.branches=branches    (directory name)\n"
+"        specify the directory containing branches\n"
+"    --config convert.svn.tags=tags            (directory name)\n"
+"        specify the directory containing tags\n"
+"    --config convert.svn.trunk=trunk          (directory name)\n"
+"        specify the name of the trunk branch"
+msgstr ""
+
+msgid ""
+"    Source history can be retrieved starting at a specific revision,\n"
+"    instead of being integrally converted. Only single branch\n"
+"    conversions are supported."
+msgstr ""
+
+msgid ""
+"    --config convert.svn.startrev=0           (svn revision number)\n"
+"        specify start Subversion revision."
+msgstr ""
+
+msgid ""
+"    Perforce Source\n"
+"    ---------------"
+msgstr ""
+
+msgid ""
+"    The Perforce (P4) importer can be given a p4 depot path or a\n"
+"    client specification as source. It will convert all files in the\n"
+"    source to a flat Mercurial repository, ignoring labels, branches\n"
+"    and integrations. Note that when a depot path is given you then\n"
+"    usually should specify a target directory, because otherwise the\n"
+"    target may be named ...-hg."
+msgstr ""
+
+msgid ""
+"    It is possible to limit the amount of source history to be\n"
+"    converted by specifying an initial Perforce revision."
+msgstr ""
+
+msgid ""
+"    --config convert.p4.startrev=0            (perforce changelist number)\n"
+"        specify initial Perforce revision."
+msgstr ""
+
+msgid ""
+"    Mercurial Destination\n"
+"    ---------------------"
+msgstr ""
+
+msgid ""
+"    --config convert.hg.clonebranches=False   (boolean)\n"
+"        dispatch source branches in separate clones.\n"
+"    --config convert.hg.tagsbranch=default    (branch name)\n"
+"        tag revisions branch name\n"
+"    --config convert.hg.usebranchnames=True   (boolean)\n"
+"        preserve branch names"
+msgstr ""
+
+msgid "    "
+msgstr ""
+
+msgid "create changeset information from CVS"
+msgstr ""
+
+msgid ""
+"    This command is intended as a debugging tool for the CVS to\n"
+"    Mercurial converter, and can be used as a direct replacement for\n"
+"    cvsps."
+msgstr ""
+
+msgid ""
+"    Hg debugcvsps reads the CVS rlog for current directory (or any\n"
+"    named directory) in the CVS repository, and converts the log to a\n"
+"    series of changesets based on matching commit log entries and\n"
+"    dates."
+msgstr ""
+
+msgid "username mapping filename"
+msgstr ""
+
+msgid "destination repository type"
+msgstr ""
+
+msgid "remap file names using contents of file"
+msgstr ""
+
+msgid "import up to target revision REV"
+msgstr ""
+
+msgid "source repository type"
+msgstr ""
+
+msgid "splice synthesized history into place"
+msgstr ""
+
+msgid "change branch names while converting"
+msgstr ""
+
+msgid "try to sort changesets by branches"
+msgstr ""
+
+msgid "try to sort changesets by date"
+msgstr ""
+
+msgid "preserve source changesets order"
+msgstr ""
+
+msgid "hg convert [OPTION]... SOURCE [DEST [REVMAP]]"
+msgstr ""
+
+msgid "only return changes on specified branches"
+msgstr ""
+
+msgid "prefix to remove from file names"
+msgstr ""
+
+msgid "only return changes after or between specified tags"
+msgstr ""
+
+msgid "update cvs log cache"
+msgstr ""
+
+msgid "create new cvs log cache"
+msgstr ""
+
+msgid "set commit time fuzz in seconds"
+msgstr ""
+
+msgid "specify cvsroot"
+msgstr ""
+
+msgid "show parent changesets"
+msgstr ""
+
+msgid "show current changeset in ancestor branches"
+msgstr ""
+
+msgid "ignored for compatibility"
+msgstr ""
+
+msgid "hg debugcvsps [OPTION]... [PATH]..."
+msgstr ""
+
+#, python-format
+msgid "%s does not look like a Bazaar repository"
+msgstr ""
+
+msgid "Bazaar modules could not be loaded"
+msgstr ""
+
+msgid ""
+"warning: lightweight checkouts may cause conversion failures, try with a "
+"regular branch instead.\n"
+msgstr ""
+
+msgid "bzr source type could not be determined\n"
+msgstr ""
+
+#, python-format
+msgid "%s is not a valid revision in current branch"
+msgstr ""
+
+#, python-format
+msgid "%s is not available in %s anymore"
+msgstr ""
+
+#, python-format
+msgid "%s.%s symlink has no target"
+msgstr ""
+
+#, python-format
+msgid "cannot find required \"%s\" tool"
+msgstr ""
+
+#, python-format
+msgid "%s error:\n"
+msgstr ""
+
+#, python-format
+msgid "syntax error in %s(%d): key/value pair expected"
+msgstr ""
+
+#, python-format
+msgid "could not open map file %r: %s"
+msgstr ""
+
+#, python-format
+msgid "%s: invalid source repository type"
+msgstr ""
+
+#, python-format
+msgid "%s: missing or unsupported repository"
+msgstr ""
+
+#, python-format
+msgid "%s: invalid destination repository type"
+msgstr ""
+
+#, python-format
+msgid "convert: %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s: unknown repository type"
+msgstr ""
+
+#, fuzzy
+msgid "getting files"
+msgstr "se primește %s\n"
+
+msgid "revisions"
+msgstr ""
+
+msgid "scanning"
+msgstr ""
+
+#, python-format
+msgid "unknown sort mode: %s"
+msgstr ""
+
+#, python-format
+msgid "cycle detected between %s and %s"
+msgstr ""
+
+msgid "not all revisions were sorted"
+msgstr ""
+
+#, python-format
+msgid "Writing author map file %s\n"
+msgstr ""
+
+#, python-format
+msgid "Ignoring bad line in author map file %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "mapping author %s to %s\n"
+msgstr ""
+
+#, python-format
+msgid "overriding mapping for author %s, was %s, will be %s\n"
+msgstr ""
+
+#, python-format
+msgid "spliced in %s as parents of %s\n"
+msgstr ""
+
+msgid "scanning source...\n"
+msgstr ""
+
+msgid "sorting...\n"
+msgstr ""
+
+msgid "converting...\n"
+msgstr ""
+
+#, python-format
+msgid "source: %s\n"
+msgstr ""
+
+msgid "converting"
+msgstr ""
+
+#, python-format
+msgid "assuming destination %s\n"
+msgstr ""
+
+msgid "more than one sort mode specified"
+msgstr ""
+
+msgid "--sourcesort is not supported by this data source"
+msgstr ""
+
+#, python-format
+msgid "%s does not look like a CVS checkout"
+msgstr ""
+
+#, python-format
+msgid "revision %s is not a patchset number"
+msgstr ""
+
+#, python-format
+msgid "connecting to %s\n"
+msgstr ""
+
+msgid "CVS pserver authentication failed"
+msgstr ""
+
+#, python-format
+msgid ""
+"unexpected response from CVS server (expected \"Valid-requests\", but got %r)"
+msgstr ""
+
+#, python-format
+msgid "%d bytes missing from remote file"
+msgstr ""
+
+msgid "malformed response from CVS"
+msgstr ""
+
+#, python-format
+msgid "cvs server: %s\n"
+msgstr ""
+
+#, python-format
+msgid "unknown CVS response: %s"
+msgstr ""
+
+msgid "collecting CVS rlog\n"
+msgstr ""
+
+msgid "not a CVS sandbox"
+msgstr ""
+
+#, python-format
+msgid "reading cvs log cache %s\n"
+msgstr ""
+
+#, python-format
+msgid "cache has %d log entries\n"
+msgstr ""
+
+#, python-format
+msgid "error reading cache: %r\n"
+msgstr ""
+
+#, python-format
+msgid "running %s\n"
+msgstr ""
+
+msgid "RCS file must be followed by working file"
+msgstr ""
+
+msgid "must have at least some revisions"
+msgstr ""
+
+msgid "expected revision number"
+msgstr ""
+
+msgid "revision must be followed by date line"
+msgstr ""
+
+msgid "log cache overlaps with new log entries, re-run without cache."
+msgstr ""
+
+#, python-format
+msgid "writing cvs log cache %s\n"
+msgstr ""
+
+#, python-format
+msgid "%d log entries\n"
+msgstr ""
+
+msgid "creating changesets\n"
+msgstr ""
+
+msgid "synthetic changeset cannot have multiple parents"
+msgstr ""
+
+#, python-format
+msgid ""
+"warning: CVS commit message references non-existent branch %r:\n"
+"%s\n"
+msgstr ""
+
+#, python-format
+msgid "%d changeset entries\n"
+msgstr ""
+
+#, python-format
+msgid "%s does not look like a darcs repository"
+msgstr ""
+
+#, python-format
+msgid "darcs version 2.1 or newer needed (found %r)"
+msgstr ""
+
+msgid "Python ElementTree module is not available"
+msgstr ""
+
+msgid "internal calling inconsistency"
+msgstr ""
+
+msgid "errors in filemap"
+msgstr ""
+
+#, python-format
+msgid "%s:%d: path to %s is missing\n"
+msgstr ""
+
+#, python-format
+msgid "%s:%d: %r already in %s list\n"
+msgstr ""
+
+#, python-format
+msgid "%s:%d: superfluous / in %s %r\n"
+msgstr ""
+
+#, python-format
+msgid "%s:%d: unknown directive %r\n"
+msgstr ""
+
+msgid "source repository doesn't support --filemap"
+msgstr ""
+
+#, python-format
+msgid "%s does not look like a Git repository"
+msgstr ""
+
+msgid "cannot retrieve git heads"
+msgstr ""
+
+#, python-format
+msgid "cannot read %r object at %s"
+msgstr ""
+
+#, python-format
+msgid "cannot read changes in %s"
+msgstr ""
+
+#, python-format
+msgid "cannot read tags from %s"
+msgstr ""
+
+#, python-format
+msgid "%s does not look like a GNU Arch repository"
+msgstr ""
+
+msgid "cannot find a GNU Arch tool"
+msgstr ""
+
+#, python-format
+msgid "analyzing tree version %s...\n"
+msgstr ""
+
+#, python-format
+msgid ""
+"tree analysis stopped because it points to an unregistered archive %s...\n"
+msgstr ""
+
+#, python-format
+msgid "could not parse cat-log of %s"
+msgstr ""
+
+#, python-format
+msgid "%s is not a local Mercurial repository"
+msgstr ""
+
+#, python-format
+msgid "initializing destination %s repository\n"
+msgstr ""
+
+#, python-format
+msgid "could not create hg repository %s as sink"
+msgstr ""
+
+#, python-format
+msgid "pulling from %s into %s\n"
+msgstr ""
+
+msgid "filtering out empty revision\n"
+msgstr ""
+
+msgid "updating tags\n"
+msgstr ""
+
+#, python-format
+msgid "%s is not a valid start revision"
+msgstr ""
+
+#, python-format
+msgid "ignoring: %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s does not look like a monotone repository"
+msgstr ""
+
+#, python-format
+msgid "copying file in renamed directory from '%s' to '%s'"
+msgstr ""
+
+#, python-format
+msgid "%s does not look like a P4 repository"
+msgstr ""
+
+msgid "reading p4 views\n"
+msgstr ""
+
+msgid "collecting p4 changelists\n"
+msgstr ""
+
+msgid "Mercurial failed to run itself, check hg executable is in PATH"
+msgstr ""
+
+msgid ""
+"svn: cannot probe remote repository, assume it could be a subversion "
+"repository. Use --source-type if you know better.\n"
+msgstr ""
+
+#, python-format
+msgid "%s does not look like a Subversion repository"
+msgstr ""
+
+msgid "Subversion python bindings could not be loaded"
+msgstr ""
+
+#, python-format
+msgid "Subversion python bindings %d.%d found, 1.4 or later required"
+msgstr ""
+
+msgid "Subversion python bindings are too old, 1.4 or later required"
+msgstr ""
+
+#, python-format
+msgid "svn: revision %s is not an integer"
+msgstr ""
+
+#, python-format
+msgid "svn: start revision %s is not an integer"
+msgstr ""
+
+#, python-format
+msgid "no revision found in module %s"
+msgstr ""
+
+#, python-format
+msgid "expected %s to be at %r, but not found"
+msgstr ""
+
+#, python-format
+msgid "found %s at %r\n"
+msgstr ""
+
+#, python-format
+msgid "ignoring empty branch %s\n"
+msgstr ""
+
+#, python-format
+msgid "found branch %s at %d\n"
+msgstr ""
+
+msgid "svn: start revision is not supported with more than one branch"
+msgstr ""
+
+#, python-format
+msgid "svn: no revision found after start revision %d"
+msgstr ""
+
+#, python-format
+msgid "%s not found up to revision %d"
+msgstr ""
+
+msgid "scanning paths"
+msgstr ""
+
+#, python-format
+msgid "found parent of branch %s at %d: %s\n"
+msgstr ""
+
+#, python-format
+msgid "fetching revision log for \"%s\" from %d to %d\n"
+msgstr ""
+
+#, python-format
+msgid "svn: branch has no revision %s"
+msgstr ""
+
+#, python-format
+msgid "initializing svn repository %r\n"
+msgstr ""
+
+#, python-format
+msgid "initializing svn working copy %r\n"
+msgstr ""
+
+msgid "unexpected svn output:\n"
+msgstr ""
+
+msgid "unable to cope with svn output"
+msgstr ""
+
+msgid "XXX TAGS NOT IMPLEMENTED YET\n"
+msgstr ""
+
+msgid "automatically manage newlines in repository files"
+msgstr ""
+
+msgid ""
+"This extension allows you to manage the type of line endings (CRLF or\n"
+"LF) that are used in the repository and in the local working\n"
+"directory. That way you can get CRLF line endings on Windows and LF on\n"
+"Unix/Mac, thereby letting everybody use their OS native line endings."
+msgstr ""
+
+msgid ""
+"The extension reads its configuration from a versioned ``.hgeol``\n"
+"configuration file every time you run an ``hg`` command. The\n"
+"``.hgeol`` file use the same syntax as all other Mercurial\n"
+"configuration files. It uses two sections, ``[patterns]`` and\n"
+"``[repository]``."
+msgstr ""
+
+msgid ""
+"The ``[patterns]`` section specifies the line endings used in the\n"
+"working directory. The format is specified by a file pattern. The\n"
+"first match is used, so put more specific patterns first. The\n"
+"available line endings are ``LF``, ``CRLF``, and ``BIN``."
+msgstr ""
+
+msgid ""
+"Files with the declared format of ``CRLF`` or ``LF`` are always\n"
+"checked out in that format and files declared to be binary (``BIN``)\n"
+"are left unchanged. Additionally, ``native`` is an alias for the\n"
+"platform's default line ending: ``LF`` on Unix (including Mac OS X)\n"
+"and ``CRLF`` on Windows. Note that ``BIN`` (do nothing to line\n"
+"endings) is Mercurial's default behaviour; it is only needed if you\n"
+"need to override a later, more general pattern."
+msgstr ""
+
+msgid ""
+"The optional ``[repository]`` section specifies the line endings to\n"
+"use for files stored in the repository. It has a single setting,\n"
+"``native``, which determines the storage line endings for files\n"
+"declared as ``native`` in the ``[patterns]`` section. It can be set to\n"
+"``LF`` or ``CRLF``. The default is ``LF``. For example, this means\n"
+"that on Windows, files configured as ``native`` (``CRLF`` by default)\n"
+"will be converted to ``LF`` when stored in the repository. Files\n"
+"declared as ``LF``, ``CRLF``, or ``BIN`` in the ``[patterns]`` section\n"
+"are always stored as-is in the repository."
+msgstr ""
+
+msgid "Example versioned ``.hgeol`` file::"
+msgstr ""
+
+msgid ""
+"  [patterns]\n"
+"  **.py = native\n"
+"  **.vcproj = CRLF\n"
+"  **.txt = native\n"
+"  Makefile = LF\n"
+"  **.jpg = BIN"
+msgstr ""
+
+msgid ""
+"  [repository]\n"
+"  native = LF"
+msgstr ""
+
+msgid ""
+"The extension uses an optional ``[eol]`` section in your hgrc file\n"
+"(not the ``.hgeol`` file) for settings that control the overall\n"
+"behavior. There are two settings:"
+msgstr ""
+
+msgid ""
+"- ``eol.native`` (default ``os.linesep``) can be set to ``LF`` or\n"
+"  ``CRLF`` override the default interpretation of ``native`` for\n"
+"  checkout. This can be used with :hg:`archive` on Unix, say, to\n"
+"  generate an archive where files have line endings for Windows."
+msgstr ""
+
+msgid ""
+"- ``eol.only-consistent`` (default True) can be set to False to make\n"
+"  the extension convert files with inconsistent EOLs. Inconsistent\n"
+"  means that there is both ``CRLF`` and ``LF`` present in the file.\n"
+"  Such files are normally not touched under the assumption that they\n"
+"  have mixed EOLs on purpose."
+msgstr ""
+
+msgid ""
+"See :hg:`help patterns` for more information about the glob patterns\n"
+"used.\n"
+msgstr ""
+
+#, python-format
+msgid "%s should not have CRLF line endings"
+msgstr ""
+
+#, python-format
+msgid "%s should not have LF line endings"
+msgstr ""
+
+msgid "the eol extension is incompatible with the win32text extension"
+msgstr ""
+
+#, python-format
+msgid "ignoring unknown EOL style '%s' from %s\n"
+msgstr ""
+
+#, python-format
+msgid "inconsistent newline style in %s\n"
+msgstr ""
+
+msgid "command to allow external programs to compare revisions"
+msgstr ""
+
+msgid ""
+"The extdiff Mercurial extension allows you to use external programs\n"
+"to compare revisions, or revision with working directory. The external\n"
+"diff programs are called with a configurable set of options and two\n"
+"non-option arguments: paths to directories containing snapshots of\n"
+"files to compare."
+msgstr ""
+
+msgid ""
+"The extdiff extension also allows to configure new diff commands, so\n"
+"you do not need to type :hg:`extdiff -p kdiff3` always. ::"
+msgstr ""
+
+msgid ""
+"  [extdiff]\n"
+"  # add new command that runs GNU diff(1) in 'context diff' mode\n"
+"  cdiff = gdiff -Nprc5\n"
+"  ## or the old way:\n"
+"  #cmd.cdiff = gdiff\n"
+"  #opts.cdiff = -Nprc5"
+msgstr ""
+
+msgid ""
+"  # add new command called vdiff, runs kdiff3\n"
+"  vdiff = kdiff3"
+msgstr ""
+
+msgid ""
+"  # add new command called meld, runs meld (no need to name twice)\n"
+"  meld ="
+msgstr ""
+
+msgid ""
+"  # add new command called vimdiff, runs gvimdiff with DirDiff plugin\n"
+"  # (see http://www.vim.org/scripts/script.php?script_id=102) Non\n"
+"  # English user, be sure to put \"let g:DirDiffDynamicDiffText = 1\" in\n"
+"  # your .vimrc\n"
+"  vimdiff = gvim -f '+next' '+execute \"DirDiff\" argv(0) argv(1)'"
+msgstr ""
+
+msgid "Tool arguments can include variables that are expanded at runtime::"
+msgstr ""
+
+msgid ""
+"  $parent1, $plabel1 - filename, descriptive label of first parent\n"
+"  $child,   $clabel  - filename, descriptive label of child revision\n"
+"  $parent2, $plabel2 - filename, descriptive label of second parent\n"
+"  $parent is an alias for $parent1."
+msgstr ""
+
+msgid ""
+"The extdiff extension will look in your [diff-tools] and [merge-tools]\n"
+"sections for diff tool arguments, when none are specified in [extdiff]."
+msgstr ""
+
+msgid ""
+"  [extdiff]\n"
+"  kdiff3 ="
+msgstr ""
+
+msgid ""
+"  [diff-tools]\n"
+"  kdiff3.diffargs=--L1 '$plabel1' --L2 '$clabel' $parent $child"
+msgstr ""
+
+msgid ""
+"You can use -I/-X and list of file or directory names like normal\n"
+":hg:`diff` command. The extdiff extension makes snapshots of only\n"
+"needed files, so running the external diff program will actually be\n"
+"pretty fast (at least faster than having to compare the entire tree).\n"
+msgstr ""
+
+#, python-format
+msgid "making snapshot of %d files from rev %s\n"
+msgstr ""
+
+#, python-format
+msgid "making snapshot of %d files from working directory\n"
+msgstr ""
+
+msgid "cannot specify --rev and --change at the same time"
+msgstr ""
+
+msgid "cleaning up temp directory\n"
+msgstr ""
+
+msgid "use external program to diff repository (or selected files)"
+msgstr ""
+
+msgid ""
+"    Show differences between revisions for the specified files, using\n"
+"    an external program. The default program used is diff, with\n"
+"    default options \"-Npru\"."
+msgstr ""
+
+msgid ""
+"    To select a different program, use the -p/--program option. The\n"
+"    program will be passed the names of two directories to compare. To\n"
+"    pass additional options to the program, use -o/--option. These\n"
+"    will be passed before the names of the directories to compare."
+msgstr ""
+
+msgid ""
+"    When two revision arguments are given, then changes are shown\n"
+"    between those revisions. If only one revision is specified then\n"
+"    that revision is compared to the working directory, and, when no\n"
+"    revisions are specified, the working directory files are compared\n"
+"    to its parent."
+msgstr ""
+
+msgid "CMD"
+msgstr "CMD"
+
+msgid "comparison program to run"
+msgstr ""
+
+msgid "OPT"
+msgstr ""
+
+msgid "pass option to comparison program"
+msgstr ""
+
+msgid "change made by revision"
+msgstr ""
+
+msgid "hg extdiff [OPT]... [FILE]..."
+msgstr ""
+
+#, python-format
+msgid "use %(path)s to diff repository (or selected files)"
+msgstr ""
+
+#, python-format
+msgid ""
+"    Show differences between revisions for the specified files, using\n"
+"    the %(path)s program."
+msgstr ""
+
+#, python-format
+msgid "hg %s [OPTION]... [FILE]..."
+msgstr ""
+
+msgid "pull, update and merge in one command"
+msgstr ""
+
+msgid "pull changes from a remote repository, merge new changes if needed."
+msgstr ""
+
+msgid ""
+"    This finds all changes from the repository at the specified path\n"
+"    or URL and adds them to the local repository."
+msgstr ""
+
+msgid ""
+"    If the pulled changes add a new branch head, the head is\n"
+"    automatically merged, and the result of the merge is committed.\n"
+"    Otherwise, the working directory is updated to include the new\n"
+"    changes."
+msgstr ""
+
+msgid ""
+"    When a merge occurs, the newly pulled changes are assumed to be\n"
+"    \"authoritative\". The head of the new changes is used as the first\n"
+"    parent, with local changes as the second. To switch the merge\n"
+"    order, use --switch-parent."
+msgstr ""
+
+msgid ""
+"    See :hg:`help dates` for a list of formats valid for -d/--date.\n"
+"    "
+msgstr ""
+"    Vezi :hg:`help dates` pentru o listă de formate valide cu d/--date.\n"
+"    "
+
+msgid ""
+"working dir not at branch tip (use \"hg update\" to check out branch tip)"
+msgstr ""
+
+msgid "outstanding uncommitted merge"
+msgstr ""
+
+msgid "outstanding uncommitted changes"
+msgstr ""
+
+msgid "working directory is missing some files"
+msgstr ""
+
+msgid ""
+"multiple heads in this branch (use \"hg heads .\" and \"hg merge\" to merge)"
+msgstr ""
+
+#, python-format
+msgid "pulling from %s\n"
+msgstr ""
+
+msgid ""
+"Other repository doesn't support revision lookup, so a rev cannot be "
+"specified."
+msgstr ""
+
+#, python-format
+msgid ""
+"not merging with %d other new branch heads (use \"hg heads .\" and \"hg merge"
+"\" to merge them)\n"
+msgstr ""
+
+#, python-format
+msgid "updating to %d:%s\n"
+msgstr ""
+
+#, python-format
+msgid "merging with %d:%s\n"
+msgstr ""
+
+#, python-format
+msgid "new changeset %d:%s merges remote changes with local\n"
+msgstr ""
+
+msgid "a specific revision you would like to pull"
+msgstr ""
+
+msgid "edit commit message"
+msgstr ""
+
+msgid "edit commit message (DEPRECATED)"
+msgstr ""
+
+msgid "switch parents when merging"
+msgstr ""
+
+msgid "hg fetch [SOURCE]"
+msgstr ""
+
+msgid "commands to sign and verify changesets"
+msgstr ""
+
+msgid "error while verifying signature"
+msgstr ""
+
+#, python-format
+msgid "%s Bad signature from \"%s\"\n"
+msgstr ""
+
+#, python-format
+msgid "%s Note: Signature has expired (signed by: \"%s\")\n"
+msgstr ""
+
+#, python-format
+msgid "%s Note: This key has expired (signed by: \"%s\")\n"
+msgstr ""
+
+msgid "list signed changesets"
+msgstr ""
+
+#, python-format
+msgid "%s:%d node does not exist\n"
+msgstr ""
+
+msgid "verify all the signatures there may be for a particular revision"
+msgstr ""
+
+#, python-format
+msgid "No valid signature for %s\n"
+msgstr ""
+
+msgid "add a signature for the current or given revision"
+msgstr ""
+
+msgid ""
+"    If no revision is given, the parent of the working directory is used,\n"
+"    or tip if no revision is checked out."
+msgstr ""
+
+msgid "uncommitted merge - please provide a specific revision"
+msgstr ""
+
+#, python-format
+msgid "Signing %d:%s\n"
+msgstr ""
+
+msgid "Error while signing"
+msgstr ""
+
+msgid ""
+"working copy of .hgsigs is changed (please commit .hgsigs manually or use --"
+"force)"
+msgstr ""
+
+msgid "unknown signature version"
+msgstr ""
+
+msgid "make the signature local"
+msgstr ""
+
+msgid "sign even if the sigfile is modified"
+msgstr ""
+
+msgid "do not commit the sigfile after signing"
+msgstr ""
+
+msgid "ID"
+msgstr ""
+
+msgid "the key id to sign with"
+msgstr ""
+
+msgid "TEXT"
+msgstr ""
+
+msgid "commit message"
+msgstr ""
+
+msgid "hg sign [OPTION]... [REVISION]..."
+msgstr ""
+
+msgid "hg sigcheck REVISION"
+msgstr ""
+
+msgid "hg sigs"
+msgstr ""
+
+msgid "command to view revision graphs from a shell"
+msgstr ""
+
+msgid ""
+"This extension adds a --graph option to the incoming, outgoing and log\n"
+"commands. When this options is given, an ASCII representation of the\n"
+"revision graph is also shown.\n"
+msgstr ""
+
+#, python-format
+msgid "--graph option is incompatible with --%s"
+msgstr ""
+
+msgid "show revision history alongside an ASCII revision graph"
+msgstr ""
+
+msgid ""
+"    Print a revision history alongside a revision graph drawn with\n"
+"    ASCII characters."
+msgstr ""
+
+msgid ""
+"    Nodes printed as an @ character are parents of the working\n"
+"    directory.\n"
+"    "
+msgstr ""
+
+msgid "show the revision DAG"
+msgstr "afișează graful (DAG) reviziilor"
+
+msgid "NUM"
+msgstr ""
+
+msgid "limit number of changes displayed"
+msgstr "limitează numărul de modificări afișat"
+
+msgid "show patch"
+msgstr "afișează patch-ul"
+
+msgid "show the specified revision or range"
+msgstr "afișează revizia sau intervalul specificat"
+
+msgid "hg glog [OPTION]... [FILE]"
+msgstr ""
+
+msgid "hooks for integrating with the CIA.vc notification service"
+msgstr ""
+
+msgid ""
+"This is meant to be run as a changegroup or incoming hook. To\n"
+"configure it, set the following options in your hgrc::"
+msgstr ""
+
+msgid ""
+"  [cia]\n"
+"  # your registered CIA user name\n"
+"  user = foo\n"
+"  # the name of the project in CIA\n"
+"  project = foo\n"
+"  # the module (subproject) (optional)\n"
+"  #module = foo\n"
+"  # Append a diffstat to the log message (optional)\n"
+"  #diffstat = False\n"
+"  # Template to use for log messages (optional)\n"
+"  #template = {desc}\\n{baseurl}/rev/{node}-- {diffstat}\n"
+"  # Style to use (optional)\n"
+"  #style = foo\n"
+"  # The URL of the CIA notification service (optional)\n"
+"  # You can use mailto: URLs to send by email, eg\n"
+"  # mailto:cia@cia.vc\n"
+"  # Make sure to set email.from if you do this.\n"
+"  #url = http://cia.vc/\n"
+"  # print message instead of sending it (optional)\n"
+"  #test = False"
+msgstr ""
+
+msgid ""
+"  [hooks]\n"
+"  # one of these:\n"
+"  changegroup.cia = python:hgcia.hook\n"
+"  #incoming.cia = python:hgcia.hook"
+msgstr ""
+
+msgid ""
+"  [web]\n"
+"  # If you want hyperlinks (optional)\n"
+"  baseurl = http://server/path/to/repo\n"
+msgstr ""
+
+#, python-format
+msgid "%s returned an error: %s"
+msgstr ""
+
+#, python-format
+msgid "hgcia: sending update to %s\n"
+msgstr ""
+
+msgid "email.from must be defined when sending by email"
+msgstr ""
+
+msgid "browse the repository in a graphical way"
+msgstr ""
+
+msgid ""
+"The hgk extension allows browsing the history of a repository in a\n"
+"graphical way. It requires Tcl/Tk version 8.4 or later. (Tcl/Tk is not\n"
+"distributed with Mercurial.)"
+msgstr ""
+
+msgid ""
+"hgk consists of two parts: a Tcl script that does the displaying and\n"
+"querying of information, and an extension to Mercurial named hgk.py,\n"
+"which provides hooks for hgk to get information. hgk can be found in\n"
+"the contrib directory, and the extension is shipped in the hgext\n"
+"repository, and needs to be enabled."
+msgstr ""
+
+msgid ""
+"The :hg:`view` command will launch the hgk Tcl script. For this command\n"
+"to work, hgk must be in your search path. Alternately, you can specify\n"
+"the path to hgk in your .hgrc file::"
+msgstr ""
+
+msgid ""
+"  [hgk]\n"
+"  path=/location/of/hgk"
+msgstr ""
+
+msgid ""
+"hgk can make use of the extdiff extension to visualize revisions.\n"
+"Assuming you had already configured extdiff vdiff command, just add::"
+msgstr ""
+
+msgid ""
+"  [hgk]\n"
+"  vdiff=vdiff"
+msgstr ""
+
+msgid ""
+"Revisions context menu will now display additional entries to fire\n"
+"vdiff on hovered and selected revisions.\n"
+msgstr ""
+
+msgid "diff trees from two commits"
+msgstr ""
+
+msgid "output common ancestor information"
+msgstr ""
+
+msgid "cat a specific revision"
+msgstr ""
+
+msgid "cat-file: type or revision not supplied\n"
+msgstr ""
+
+msgid "aborting hg cat-file only understands commits\n"
+msgstr ""
+
+msgid "parse given revisions"
+msgstr ""
+
+msgid "print revisions"
+msgstr ""
+
+msgid "print extension options"
+msgstr ""
+
+msgid "start interactive history viewer"
+msgstr ""
+
+msgid "hg view [-l LIMIT] [REVRANGE]"
+msgstr ""
+
+msgid "generate patch"
+msgstr ""
+
+msgid "recursive"
+msgstr ""
+
+msgid "pretty"
+msgstr ""
+
+msgid "stdin"
+msgstr ""
+
+msgid "detect copies"
+msgstr ""
+
+msgid "search"
+msgstr ""
+
+msgid "hg git-diff-tree [OPTION]... NODE1 NODE2 [FILE]..."
+msgstr ""
+
+msgid "hg debug-cat-file [OPTION]... TYPE FILE"
+msgstr ""
+
+msgid "hg debug-config"
+msgstr ""
+
+msgid "hg debug-merge-base REV REV"
+msgstr ""
+
+msgid "ignored"
+msgstr ""
+
+msgid "hg debug-rev-parse REV"
+msgstr ""
+
+msgid "header"
+msgstr ""
+
+msgid "topo-order"
+msgstr ""
+
+msgid "parents"
+msgstr ""
+
+msgid "max-count"
+msgstr ""
+
+msgid "hg debug-rev-list [OPTION]... REV..."
+msgstr ""
+
+msgid "syntax highlighting for hgweb (requires Pygments)"
+msgstr ""
+
+msgid ""
+"It depends on the Pygments syntax highlighting library:\n"
+"http://pygments.org/"
+msgstr ""
+
+msgid "There is a single configuration option::"
+msgstr ""
+
+msgid ""
+"  [web]\n"
+"  pygments_style = <style>"
+msgstr ""
+
+msgid "The default is 'colorful'.\n"
+msgstr ""
+
+msgid "accelerate status report using Linux's inotify service"
+msgstr ""
+
+msgid "start an inotify server for this repository"
+msgstr ""
+
+msgid "debugging information for inotify extension"
+msgstr ""
+
+msgid ""
+"    Prints the list of directories being watched by the inotify server.\n"
+"    "
+msgstr ""
+
+msgid "directories being watched:\n"
+msgstr ""
+
+msgid "run server in background"
+msgstr ""
+
+msgid "used internally by daemon mode"
+msgstr ""
+
+msgid "minutes to sit idle before exiting"
+msgstr ""
+
+msgid "name of file to write process ID to"
+msgstr ""
+
+msgid "hg inserve [OPTION]..."
+msgstr ""
+
+msgid "inotify-client: found dead inotify server socket; removing it\n"
+msgstr ""
+
+#, python-format
+msgid "inotify-client: could not start inotify server: %s\n"
+msgstr ""
+
+#, python-format
+msgid "inotify-client: could not talk to new inotify server: %s\n"
+msgstr ""
+
+#, python-format
+msgid "inotify-client: failed to contact inotify server: %s\n"
+msgstr ""
+
+msgid "inotify-client: received empty answer from inotify server"
+msgstr ""
+
+#, python-format
+msgid "(inotify: received response from incompatible server version %d)\n"
+msgstr ""
+
+#, python-format
+msgid "(inotify: received '%s' response when expecting '%s')\n"
+msgstr ""
+
+msgid "this system does not seem to support inotify"
+msgstr ""
+
+#, python-format
+msgid "*** the current per-user limit on the number of inotify watches is %s\n"
+msgstr ""
+
+msgid "*** this limit is too low to watch every directory in this repository\n"
+msgstr ""
+
+msgid "*** counting directories: "
+msgstr ""
+
+#, python-format
+msgid "found %d\n"
+msgstr ""
+
+#, python-format
+msgid "*** to raise the limit from %d to %d (run as root):\n"
+msgstr ""
+
+#, python-format
+msgid "***  echo %d > %s\n"
+msgstr ""
+
+#, python-format
+msgid "cannot watch %s until inotify watch limit is raised"
+msgstr ""
+
+#, python-format
+msgid "inotify service not available: %s"
+msgstr ""
+
+#, python-format
+msgid "watching %r\n"
+msgstr ""
+
+#, python-format
+msgid "watching directories under %r\n"
+msgstr ""
+
+#, python-format
+msgid "%s event: created %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s event: deleted %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s event: modified %s\n"
+msgstr ""
+
+#, python-format
+msgid "filesystem containing %s was unmounted\n"
+msgstr ""
+
+#, python-format
+msgid "%s readable: %d bytes\n"
+msgstr ""
+
+#, python-format
+msgid "%s below threshold - unhooking\n"
+msgstr ""
+
+#, python-format
+msgid "%s reading %d events\n"
+msgstr ""
+
+#, python-format
+msgid "%s hooking back up with %d bytes readable\n"
+msgstr ""
+
+msgid "finished setup\n"
+msgstr ""
+
+#, python-format
+msgid "status: %r %s -> %s\n"
+msgstr ""
+
+msgid "rescanning due to .hgignore change\n"
+msgstr ""
+
+msgid "cannot start: socket is already bound"
+msgstr ""
+
+msgid ""
+"cannot start: tried linking .hg/inotify.sock to a temporary socket but .hg/"
+"inotify.sock already exists"
+msgstr ""
+
+#, python-format
+msgid "answering query for %r\n"
+msgstr ""
+
+#, python-format
+msgid "received query from incompatible client version %d\n"
+msgstr ""
+
+#, python-format
+msgid "unrecognized query type: %s\n"
+msgstr ""
+
+msgid "expand expressions into changelog and summaries"
+msgstr ""
+
+msgid ""
+"This extension allows the use of a special syntax in summaries, which\n"
+"will be automatically expanded into links or any other arbitrary\n"
+"expression, much like InterWiki does."
+msgstr ""
+
+msgid ""
+"A few example patterns (link to bug tracking, etc.) that may be used\n"
+"in your hgrc::"
+msgstr ""
+
+msgid ""
+"  [interhg]\n"
+"  issues = s!issue(\\d+)!<a href=\"http://bts/issue\\1\">issue\\1</a>!\n"
+"  bugzilla = s!((?:bug|b=|(?=#?\\d{4,}))(?:\\s*#?)(\\d+))!<a..=\\2\">\\1</a>!"
+"i\n"
+"  boldify = s!(^|\\s)#(\\d+)\\b! <b>#\\2</b>!\n"
+msgstr ""
+
+#, python-format
+msgid "interhg: invalid pattern for %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "interhg: invalid regexp for %s: %s\n"
+msgstr ""
+
+msgid "expand keywords in tracked files"
+msgstr ""
+
+msgid ""
+"This extension expands RCS/CVS-like or self-customized $Keywords$ in\n"
+"tracked text files selected by your configuration."
+msgstr ""
+
+msgid ""
+"Keywords are only expanded in local repositories and not stored in the\n"
+"change history. The mechanism can be regarded as a convenience for the\n"
+"current user or for archive distribution."
+msgstr ""
+
+msgid ""
+"Configuration is done in the [keyword], [keywordset] and [keywordmaps]\n"
+"sections of hgrc files."
+msgstr ""
+
+msgid "Example::"
+msgstr ""
+
+msgid ""
+"    [keyword]\n"
+"    # expand keywords in every python file except those matching \"x*\"\n"
+"    **.py =\n"
+"    x*    = ignore"
+msgstr ""
+
+msgid ""
+"    [keywordset]\n"
+"    # prefer svn- over cvs-like default keywordmaps\n"
+"    svn = True"
+msgstr ""
+
+msgid ""
+"NOTE: the more specific you are in your filename patterns the less you\n"
+"lose speed in huge repositories."
+msgstr ""
+
+msgid ""
+"For [keywordmaps] template mapping and expansion demonstration and\n"
+"control run :hg:`kwdemo`. See :hg:`help templates` for a list of\n"
+"available templates and filters."
+msgstr ""
+
+msgid "Three additional date template filters are provided::"
+msgstr ""
+
+msgid ""
+"    utcdate      \"2006/09/18 15:13:13\"\n"
+"    svnutcdate   \"2006-09-18 15:13:13Z\"\n"
+"    svnisodate   \"2006-09-18 08:13:13 -700 (Mon, 18 Sep 2006)\""
+msgstr ""
+
+msgid ""
+"The default template mappings (view with :hg:`kwdemo -d`) can be\n"
+"replaced with customized keywords and templates. Again, run\n"
+":hg:`kwdemo` to control the results of your config changes."
+msgstr ""
+
+msgid ""
+"Before changing/disabling active keywords, run :hg:`kwshrink` to avoid\n"
+"the risk of inadvertently storing expanded keywords in the change\n"
+"history."
+msgstr ""
+
+msgid ""
+"To force expansion after enabling it, or a configuration change, run\n"
+":hg:`kwexpand`."
+msgstr ""
+
+msgid ""
+"Expansions spanning more than one line and incremental expansions,\n"
+"like CVS' $Log$, are not supported. A keyword template map \"Log =\n"
+"{desc}\" expands to the first line of the changeset description.\n"
+msgstr ""
+
+#, python-format
+msgid "overwriting %s expanding keywords\n"
+msgstr ""
+
+#, python-format
+msgid "overwriting %s shrinking keywords\n"
+msgstr ""
+
+msgid "[keyword] patterns cannot match"
+msgstr ""
+
+msgid "no [keyword] patterns configured"
+msgstr ""
+
+msgid "print [keywordmaps] configuration and an expansion example"
+msgstr ""
+
+msgid ""
+"    Show current, custom, or default keyword template maps and their\n"
+"    expansions."
+msgstr ""
+
+msgid ""
+"    Extend the current configuration by specifying maps as arguments\n"
+"    and using -f/--rcfile to source an external hgrc file."
+msgstr ""
+
+msgid "    Use -d/--default to disable current configuration."
+msgstr ""
+
+msgid ""
+"    See :hg:`help templates` for information on templates and filters.\n"
+"    "
+msgstr ""
+
+#, python-format
+msgid "creating temporary repository at %s\n"
+msgstr ""
+
+msgid ""
+"\n"
+"\tconfiguration using custom keyword template maps\n"
+msgstr ""
+
+msgid "\textending current template maps\n"
+msgstr ""
+
+msgid "\toverriding default template maps\n"
+msgstr ""
+
+msgid ""
+"\n"
+"\tconfiguration using default keyword template maps\n"
+msgstr ""
+
+msgid "\tdisabling current template maps\n"
+msgstr ""
+
+msgid ""
+"\n"
+"\tconfiguration using current keyword template maps\n"
+msgstr ""
+
+#, python-format
+msgid ""
+"\n"
+"keywords written to %s:\n"
+msgstr ""
+
+msgid "hg keyword configuration and expansion example"
+msgstr ""
+
+msgid ""
+"\n"
+"\tkeywords expanded\n"
+msgstr ""
+
+msgid "expand keywords in the working directory"
+msgstr ""
+
+msgid "    Run after (re)enabling keyword expansion."
+msgstr ""
+
+msgid ""
+"    kwexpand refuses to run if given files contain local changes.\n"
+"    "
+msgstr ""
+
+msgid "show files configured for keyword expansion"
+msgstr ""
+
+msgid ""
+"    List which files in the working directory are matched by the\n"
+"    [keyword] configuration patterns."
+msgstr ""
+
+msgid ""
+"    Useful to prevent inadvertent keyword expansion and to speed up\n"
+"    execution by including only files that are actual candidates for\n"
+"    expansion."
+msgstr ""
+
+msgid ""
+"    See :hg:`help keyword` on how to construct patterns both for\n"
+"    inclusion and exclusion of files."
+msgstr ""
+
+msgid ""
+"    With -A/--all and -v/--verbose the codes used to show the status\n"
+"    of files are::"
+msgstr ""
+
+msgid ""
+"      K = keyword expansion candidate\n"
+"      k = keyword expansion candidate (not tracked)\n"
+"      I = ignored\n"
+"      i = ignored (not tracked)\n"
+"    "
+msgstr ""
+
+msgid "revert expanded keywords in the working directory"
+msgstr ""
+
+msgid ""
+"    Run before changing/disabling active keywords or if you experience\n"
+"    problems with :hg:`import` or :hg:`merge`."
+msgstr ""
+
+msgid ""
+"    kwshrink refuses to run if given files contain local changes.\n"
+"    "
+msgstr ""
+
+msgid "show default keyword template maps"
+msgstr ""
+
+msgid "read maps from rcfile"
+msgstr ""
+
+msgid "hg kwdemo [-d] [-f RCFILE] [TEMPLATEMAP]..."
+msgstr ""
+
+msgid "hg kwexpand [OPTION]... [FILE]..."
+msgstr ""
+
+msgid "show keyword status flags of all files"
+msgstr ""
+
+msgid "show files excluded from expansion"
+msgstr ""
+
+msgid "only show unknown (not tracked) files"
+msgstr ""
+
+msgid "hg kwfiles [OPTION]... [FILE]..."
+msgstr ""
+
+msgid "hg kwshrink [OPTION]... [FILE]..."
+msgstr ""
+
+msgid "manage a stack of patches"
+msgstr ""
+
+msgid ""
+"This extension lets you work with a stack of patches in a Mercurial\n"
+"repository. It manages two stacks of patches - all known patches, and\n"
+"applied patches (subset of known patches)."
+msgstr ""
+
+msgid ""
+"Known patches are represented as patch files in the .hg/patches\n"
+"directory. Applied patches are both patch files and changesets."
+msgstr ""
+
+msgid "Common tasks (use :hg:`help command` for more details)::"
+msgstr ""
+
+msgid ""
+"  create new patch                          qnew\n"
+"  import existing patch                     qimport"
+msgstr ""
+
+msgid ""
+"  print patch series                        qseries\n"
+"  print applied patches                     qapplied"
+msgstr ""
+
+msgid ""
+"  add known patch to applied stack          qpush\n"
+"  remove patch from applied stack           qpop\n"
+"  refresh contents of top applied patch     qrefresh"
+msgstr ""
+
+msgid ""
+"By default, mq will automatically use git patches when required to\n"
+"avoid losing file mode changes, copy records, binary files or empty\n"
+"files creations or deletions. This behaviour can be configured with::"
+msgstr ""
+
+msgid ""
+"  [mq]\n"
+"  git = auto/keep/yes/no"
+msgstr ""
+
+msgid ""
+"If set to 'keep', mq will obey the [diff] section configuration while\n"
+"preserving existing git patches upon qrefresh. If set to 'yes' or\n"
+"'no', mq will override the [diff] section and always generate git or\n"
+"regular patches, possibly losing data in the second case."
+msgstr ""
+
+msgid ""
+"You will by default be managing a patch queue named \"patches\". You can\n"
+"create other, independent patch queues with the :hg:`qqueue` command.\n"
+msgstr ""
+
+#, python-format
+msgid "mq.git option can be auto/keep/yes/no got %s"
+msgstr ""
+
+#, python-format
+msgid "%s appears more than once in %s"
+msgstr ""
+
+msgid "guard cannot be an empty string"
+msgstr ""
+
+#, python-format
+msgid "guard %r starts with invalid character: %r"
+msgstr ""
+
+#, python-format
+msgid "invalid character in guard %r: %r"
+msgstr ""
+
+#, python-format
+msgid "guard %r too short"
+msgstr ""
+
+#, python-format
+msgid "guard %r starts with invalid char"
+msgstr ""
+
+#, python-format
+msgid "allowing %s - no guards in effect\n"
+msgstr ""
+
+#, python-format
+msgid "allowing %s - no matching negative guards\n"
+msgstr ""
+
+#, python-format
+msgid "allowing %s - guarded by %r\n"
+msgstr ""
+
+#, python-format
+msgid "skipping %s - guarded by %r\n"
+msgstr ""
+
+#, python-format
+msgid "skipping %s - no matching guards\n"
+msgstr ""
+
+#, python-format
+msgid "error removing undo: %s\n"
+msgstr ""
+
+#, python-format
+msgid "apply failed for patch %s"
+msgstr ""
+
+#, python-format
+msgid "patch didn't work out, merging %s\n"
+msgstr ""
+
+#, python-format
+msgid "update returned %d"
+msgstr ""
+
+msgid "repo commit failed"
+msgstr ""
+
+#, python-format
+msgid "unable to read %s"
+msgstr ""
+
+#, python-format
+msgid "patch %s does not exist\n"
+msgstr ""
+
+#, python-format
+msgid "patch %s is not applied\n"
+msgstr ""
+
+msgid "patch failed, unable to continue (try -v)\n"
+msgstr ""
+
+#, python-format
+msgid "applying %s\n"
+msgstr ""
+
+#, python-format
+msgid "unable to read %s\n"
+msgstr ""
+
+#, python-format
+msgid "patch %s is empty\n"
+msgstr ""
+
+msgid "patch failed, rejects left in working dir\n"
+msgstr ""
+
+msgid "fuzz found when applying patch, stopping\n"
+msgstr ""
+
+#, python-format
+msgid "revision %d is not managed"
+msgstr ""
+
+#, python-format
+msgid "cannot delete revision %d above applied patches"
+msgstr ""
+
+#, python-format
+msgid "patch %s finalized without changeset message\n"
+msgstr ""
+
+msgid "qdelete requires at least one revision or patch name"
+msgstr ""
+
+#, python-format
+msgid "cannot delete applied patch %s"
+msgstr ""
+
+#, python-format
+msgid "patch %s not in series file"
+msgstr ""
+
+msgid "no patches applied"
+msgstr ""
+
+msgid "working directory revision is not qtip"
+msgstr ""
+
+msgid "local changes found, refresh first"
+msgstr ""
+
+msgid "local changes found"
+msgstr ""
+
+#, python-format
+msgid "\"%s\" cannot be used as the name of a patch"
+msgstr ""
+
+#, python-format
+msgid "patch \"%s\" already exists"
+msgstr ""
+
+msgid "cannot manage merge changesets"
+msgstr ""
+
+#, python-format
+msgid "error unlinking %s\n"
+msgstr ""
+
+#, python-format
+msgid "patch name \"%s\" is ambiguous:\n"
+msgstr ""
+
+#, python-format
+msgid "patch %s not in series"
+msgstr ""
+
+msgid "(working directory not at a head)\n"
+msgstr ""
+
+msgid "no patches in series\n"
+msgstr ""
+
+#, python-format
+msgid "cannot push to a previous patch: %s"
+msgstr ""
+
+#, python-format
+msgid "qpush: %s is already at the top\n"
+msgstr ""
+
+#, python-format
+msgid "guarded by %r"
+msgstr ""
+
+msgid "no matching guards"
+msgstr ""
+
+#, python-format
+msgid "cannot push '%s' - %s\n"
+msgstr ""
+
+msgid "all patches are currently applied\n"
+msgstr ""
+
+msgid "patch series already fully applied\n"
+msgstr ""
+
+msgid "please specify the patch to move"
+msgstr ""
+
+msgid "cleaning up working directory..."
+msgstr ""
+
+#, python-format
+msgid "errors during apply, please fix and refresh %s\n"
+msgstr ""
+
+#, python-format
+msgid "now at: %s\n"
+msgstr ""
+
+#, python-format
+msgid "patch %s is not applied"
+msgstr ""
+
+msgid "no patches applied\n"
+msgstr ""
+
+#, python-format
+msgid "qpop: %s is already at the top\n"
+msgstr ""
+
+msgid "qpop: forcing dirstate update\n"
+msgstr ""
+
+#, python-format
+msgid "trying to pop unknown node %s"
+msgstr ""
+
+msgid "popping would remove a revision not managed by this patch queue"
+msgstr ""
+
+msgid "deletions found between repo revs"
+msgstr ""
+
+#, python-format
+msgid "popping %s\n"
+msgstr ""
+
+msgid "patch queue now empty\n"
+msgstr ""
+
+msgid "cannot refresh a revision with children"
+msgstr ""
+
+msgid ""
+"refresh interrupted while patch was popped! (revert --all, qpush to "
+"recover)\n"
+msgstr ""
+
+msgid "patch queue directory already exists"
+msgstr ""
+
+#, python-format
+msgid "patch %s is not in series file"
+msgstr ""
+
+msgid "No saved patch data found\n"
+msgstr ""
+
+#, python-format
+msgid "restoring status: %s\n"
+msgstr ""
+
+msgid "save entry has children, leaving it alone\n"
+msgstr ""
+
+#, python-format
+msgid "removing save entry %s\n"
+msgstr ""
+
+#, python-format
+msgid "saved queue repository parents: %s %s\n"
+msgstr ""
+
+msgid "queue directory updating\n"
+msgstr ""
+
+msgid "Unable to load queue repository\n"
+msgstr ""
+
+msgid "save: no patches applied, exiting\n"
+msgstr ""
+
+msgid "status is already saved\n"
+msgstr ""
+
+msgid "hg patches saved state"
+msgstr ""
+
+msgid "repo commit failed\n"
+msgstr ""
+
+#, python-format
+msgid "patch %s is already in the series file"
+msgstr ""
+
+msgid "option \"-r\" not valid when importing files"
+msgstr ""
+
+msgid "option \"-n\" not valid when importing multiple patches"
+msgstr ""
+
+#, python-format
+msgid "revision %d is the root of more than one branch"
+msgstr ""
+
+#, python-format
+msgid "revision %d is already managed"
+msgstr ""
+
+#, python-format
+msgid "revision %d is not the parent of the queue"
+msgstr ""
+
+#, python-format
+msgid "revision %d has unmanaged children"
+msgstr ""
+
+#, python-format
+msgid "cannot import merge revision %d"
+msgstr ""
+
+#, python-format
+msgid "revision %d is not the parent of %d"
+msgstr ""
+
+msgid "-e is incompatible with import from -"
+msgstr ""
+
+#, python-format
+msgid "patch %s does not exist"
+msgstr ""
+
+#, python-format
+msgid "renaming %s to %s\n"
+msgstr ""
+
+msgid "need --name to import a patch from -"
+msgstr ""
+
+#, python-format
+msgid "unable to read file %s"
+msgstr ""
+
+#, python-format
+msgid "adding %s to series file\n"
+msgstr ""
+
+msgid "remove patches from queue"
+msgstr ""
+
+msgid ""
+"    The patches must not be applied, and at least one patch is required. "
+"With\n"
+"    -k/--keep, the patch files are preserved in the patch directory."
+msgstr ""
+
+msgid ""
+"    To stop managing a patch and move it into permanent history,\n"
+"    use the :hg:`qfinish` command."
+msgstr ""
+
+msgid "print the patches already applied"
+msgstr ""
+
+msgid "only one patch applied\n"
+msgstr ""
+
+msgid "print the patches not yet applied"
+msgstr ""
+
+msgid "all patches applied\n"
+msgstr ""
+
+msgid "import a patch"
+msgstr ""
+
+msgid ""
+"    The patch is inserted into the series after the last applied\n"
+"    patch. If no patches have been applied, qimport prepends the patch\n"
+"    to the series."
+msgstr ""
+
+msgid ""
+"    The patch will have the same name as its source file unless you\n"
+"    give it a new one with -n/--name."
+msgstr ""
+
+msgid ""
+"    You can register an existing patch inside the patch directory with\n"
+"    the -e/--existing flag."
+msgstr ""
+
+msgid ""
+"    With -f/--force, an existing patch of the same name will be\n"
+"    overwritten."
+msgstr ""
+
+msgid ""
+"    An existing changeset may be placed under mq control with -r/--rev\n"
+"    (e.g. qimport --rev tip -n patch will place tip under mq control).\n"
+"    With -g/--git, patches imported with --rev will use the git diff\n"
+"    format. See the diffs help topic for information on why this is\n"
+"    important for preserving rename/copy information and permission\n"
+"    changes."
+msgstr ""
+
+msgid ""
+"    To import a patch from standard input, pass - as the patch file.\n"
+"    When importing from standard input, a patch name must be specified\n"
+"    using the --name flag."
+msgstr ""
+
+msgid "    To import an existing patch while renaming it::"
+msgstr ""
+
+msgid ""
+"      hg qimport -e existing-patch -n new-name\n"
+"    "
+msgstr ""
+
+msgid "init a new queue repository (DEPRECATED)"
+msgstr ""
+
+msgid ""
+"    The queue repository is unversioned by default. If\n"
+"    -c/--create-repo is specified, qinit will create a separate nested\n"
+"    repository for patches (qinit -c may also be run later to convert\n"
+"    an unversioned patch repository into a versioned one). You can use\n"
+"    qcommit to commit changes to this queue repository."
+msgstr ""
+
+msgid ""
+"    This command is deprecated. Without -c, it's implied by other relevant\n"
+"    commands. With -c, use :hg:`init --mq` instead."
+msgstr ""
+
+msgid "clone main and patch repository at same time"
+msgstr ""
+
+msgid ""
+"    If source is local, destination will have no patches applied. If\n"
+"    source is remote, this command can not check if patches are\n"
+"    applied in source, so cannot guarantee that patches are not\n"
+"    applied in destination. If you clone remote repository, be sure\n"
+"    before that it has no patches applied."
+msgstr ""
+
+msgid ""
+"    Source patch repository is looked for in <src>/.hg/patches by\n"
+"    default. Use -p <url> to change."
+msgstr ""
+
+msgid ""
+"    The patch directory must be a nested Mercurial repository, as\n"
+"    would be created by :hg:`init --mq`.\n"
+"    "
+msgstr ""
+
+msgid "versioned patch repository not found (see init --mq)"
+msgstr ""
+
+msgid "cloning main repository\n"
+msgstr ""
+
+msgid "cloning patch repository\n"
+msgstr ""
+
+msgid "stripping applied patches from destination repository\n"
+msgstr ""
+
+msgid "updating destination repository\n"
+msgstr ""
+
+msgid "commit changes in the queue repository (DEPRECATED)"
+msgstr ""
+
+msgid "    This command is deprecated; use :hg:`commit --mq` instead."
+msgstr ""
+
+msgid "print the entire series file"
+msgstr ""
+
+msgid "print the name of the current patch"
+msgstr ""
+
+msgid "print the name of the next patch"
+msgstr ""
+
+msgid "print the name of the previous patch"
+msgstr ""
+
+msgid "create a new patch"
+msgstr ""
+
+msgid ""
+"    qnew creates a new patch on top of the currently-applied patch (if\n"
+"    any). The patch will be initialized with any outstanding changes\n"
+"    in the working directory. You may also use -I/--include,\n"
+"    -X/--exclude, and/or a list of files after the patch name to add\n"
+"    only changes to matching files to the new patch, leaving the rest\n"
+"    as uncommitted modifications."
+msgstr ""
+
+msgid ""
+"    -u/--user and -d/--date can be used to set the (given) user and\n"
+"    date, respectively. -U/--currentuser and -D/--currentdate set user\n"
+"    to current user and date to current date."
+msgstr ""
+
+msgid ""
+"    -e/--edit, -m/--message or -l/--logfile set the patch header as\n"
+"    well as the commit message. If none is specified, the header is\n"
+"    empty and the commit message is '[mq]: PATCH'."
+msgstr ""
+
+msgid ""
+"    Use the -g/--git option to keep the patch in the git extended diff\n"
+"    format. Read the diffs help topic for more information on why this\n"
+"    is important for preserving permission changes and copy/rename\n"
+"    information.\n"
+"    "
+msgstr ""
+
+msgid "update the current patch"
+msgstr ""
+
+msgid ""
+"    If any file patterns are provided, the refreshed patch will\n"
+"    contain only the modifications that match those patterns; the\n"
+"    remaining modifications will remain in the working directory."
+msgstr ""
+
+msgid ""
+"    If -s/--short is specified, files currently included in the patch\n"
+"    will be refreshed just like matched files and remain in the patch."
+msgstr ""
+
+msgid ""
+"    hg add/remove/copy/rename work as usual, though you might want to\n"
+"    use git-style patches (-g/--git or [diff] git=1) to track copies\n"
+"    and renames. See the diffs help topic for more information on the\n"
+"    git diff format.\n"
+"    "
+msgstr ""
+
+msgid "option \"-e\" incompatible with \"-m\" or \"-l\""
+msgstr ""
+
+msgid "diff of the current patch and subsequent modifications"
+msgstr ""
+
+msgid ""
+"    Shows a diff which includes the current patch as well as any\n"
+"    changes which have been made in the working directory since the\n"
+"    last refresh (thus showing what the current patch would become\n"
+"    after a qrefresh)."
+msgstr ""
+
+msgid ""
+"    Use :hg:`diff` if you only want to see the changes made since the\n"
+"    last qrefresh, or :hg:`export qtip` if you want to see changes\n"
+"    made by the current patch without including changes made since the\n"
+"    qrefresh.\n"
+"    "
+msgstr ""
+
+msgid "fold the named patches into the current patch"
+msgstr ""
+
+msgid ""
+"    Patches must not yet be applied. Each patch will be successively\n"
+"    applied to the current patch in the order given. If all the\n"
+"    patches apply successfully, the current patch will be refreshed\n"
+"    with the new cumulative patch, and the folded patches will be\n"
+"    deleted. With -k/--keep, the folded patch files will not be\n"
+"    removed afterwards."
+msgstr ""
+
+msgid ""
+"    The header for each folded patch will be concatenated with the\n"
+"    current patch header, separated by a line of '* * *'."
+msgstr ""
+
+msgid "qfold requires at least one patch name"
+msgstr ""
+
+msgid "No patches applied"
+msgstr ""
+
+#, python-format
+msgid "Skipping already folded patch %s"
+msgstr ""
+
+#, python-format
+msgid "qfold cannot fold already applied patch %s"
+msgstr ""
+
+#, python-format
+msgid "Error folding patch %s"
+msgstr ""
+
+msgid "push or pop patches until named patch is at top of stack"
+msgstr ""
+
+msgid "set or print guards for a patch"
+msgstr ""
+
+msgid ""
+"    Guards control whether a patch can be pushed. A patch with no\n"
+"    guards is always pushed. A patch with a positive guard (\"+foo\") is\n"
+"    pushed only if the :hg:`qselect` command has activated it. A patch with\n"
+"    a negative guard (\"-foo\") is never pushed if the :hg:`qselect` "
+"command\n"
+"    has activated it."
+msgstr ""
+
+msgid ""
+"    With no arguments, print the currently active guards.\n"
+"    With arguments, set guards for the named patch.\n"
+"    NOTE: Specifying negative guards now requires '--'."
+msgstr ""
+
+msgid "    To set guards on another patch::"
+msgstr ""
+
+msgid ""
+"      hg qguard other.patch -- +2.6.17 -stable\n"
+"    "
+msgstr ""
+
+msgid "cannot mix -l/--list with options or arguments"
+msgstr ""
+
+msgid "no patch to work with"
+msgstr ""
+
+#, python-format
+msgid "no patch named %s"
+msgstr ""
+
+msgid "print the header of the topmost or specified patch"
+msgstr ""
+
+msgid "push the next patch onto the stack"
+msgstr ""
+
+msgid ""
+"    When -f/--force is applied, all local changes in patched files\n"
+"    will be lost.\n"
+"    "
+msgstr ""
+
+msgid "no saved queues found, please use -n\n"
+msgstr ""
+
+#, python-format
+msgid "merging with queue at: %s\n"
+msgstr ""
+
+msgid "pop the current patch off the stack"
+msgstr ""
+
+msgid ""
+"    By default, pops off the top of the patch stack. If given a patch\n"
+"    name, keeps popping off patches until the named patch is at the\n"
+"    top of the stack.\n"
+"    "
+msgstr ""
+
+#, python-format
+msgid "using patch queue: %s\n"
+msgstr ""
+
+msgid "rename a patch"
+msgstr ""
+
+msgid ""
+"    With one argument, renames the current patch to PATCH1.\n"
+"    With two arguments, renames PATCH1 to PATCH2."
+msgstr ""
+
+#, python-format
+msgid "%s already exists"
+msgstr ""
+
+#, python-format
+msgid "A patch named %s already exists in the series file"
+msgstr ""
+
+msgid "restore the queue state saved by a revision (DEPRECATED)"
+msgstr ""
+
+msgid "    This command is deprecated, use rebase --mq instead."
+msgstr ""
+
+msgid "save current queue state (DEPRECATED)"
+msgstr ""
+
+#, python-format
+msgid "destination %s exists and is not a directory"
+msgstr ""
+
+#, python-format
+msgid "destination %s exists, use -f to force"
+msgstr ""
+
+#, python-format
+msgid "copy %s to %s\n"
+msgstr ""
+
+msgid "strip a changeset and all its descendants from the repository"
+msgstr ""
+
+msgid ""
+"    The strip command removes all changesets whose local revision\n"
+"    number is greater than or equal to REV, and then restores any\n"
+"    changesets that are not descendants of REV. If the working\n"
+"    directory has uncommitted changes, the operation is aborted unless\n"
+"    the --force flag is supplied."
+msgstr ""
+
+msgid ""
+"    If a parent of the working directory is stripped, then the working\n"
+"    directory will automatically be updated to the most recent\n"
+"    available ancestor of the stripped parent after the operation\n"
+"    completes."
+msgstr ""
+
+msgid ""
+"    Any stripped changesets are stored in ``.hg/strip-backup`` as a\n"
+"    bundle (see :hg:`help bundle` and :hg:`help unbundle`). They can\n"
+"    be restored by running :hg:`unbundle .hg/strip-backup/BUNDLE`,\n"
+"    where BUNDLE is the bundle file created by the strip. Note that\n"
+"    the local revision numbers will in general be different after the\n"
+"    restore."
+msgstr ""
+
+msgid ""
+"    Use the --nobackup option to discard the backup bundle once the\n"
+"    operation completes.\n"
+"    "
+msgstr ""
+
+msgid "set or print guarded patches to push"
+msgstr ""
+
+msgid ""
+"    Use the :hg:`qguard` command to set or print guards on patch, then use\n"
+"    qselect to tell mq which guards to use. A patch will be pushed if\n"
+"    it has no guards or any positive guards match the currently\n"
+"    selected guard, but will not be pushed if any negative guards\n"
+"    match the current guard. For example::"
+msgstr ""
+
+msgid ""
+"        qguard foo.patch -stable    (negative guard)\n"
+"        qguard bar.patch +stable    (positive guard)\n"
+"        qselect stable"
+msgstr ""
+
+msgid ""
+"    This activates the \"stable\" guard. mq will skip foo.patch (because\n"
+"    it has a negative match) but push bar.patch (because it has a\n"
+"    positive match)."
+msgstr ""
+
+msgid ""
+"    With no arguments, prints the currently active guards.\n"
+"    With one argument, sets the active guard."
+msgstr ""
+
+msgid ""
+"    Use -n/--none to deactivate guards (no other arguments needed).\n"
+"    When no guards are active, patches with positive guards are\n"
+"    skipped and patches with negative guards are pushed."
+msgstr ""
+
+msgid ""
+"    qselect can change the guards on applied patches. It does not pop\n"
+"    guarded patches by default. Use --pop to pop back to the last\n"
+"    applied patch that is not guarded. Use --reapply (which implies\n"
+"    --pop) to push back to the current patch afterwards, but skip\n"
+"    guarded patches."
+msgstr ""
+
+msgid ""
+"    Use -s/--series to print a list of all guards in the series file\n"
+"    (no other arguments needed). Use -v for more information."
+msgstr ""
+
+msgid "guards deactivated\n"
+msgstr ""
+
+#, python-format
+msgid "number of unguarded, unapplied patches has changed from %d to %d\n"
+msgstr ""
+
+#, python-format
+msgid "number of guarded, applied patches has changed from %d to %d\n"
+msgstr ""
+
+msgid "guards in series file:\n"
+msgstr ""
+
+msgid "no guards in series file\n"
+msgstr ""
+
+msgid "active guards:\n"
+msgstr ""
+
+msgid "no active guards\n"
+msgstr ""
+
+msgid "popping guarded patches\n"
+msgstr ""
+
+msgid "reapplying unguarded patches\n"
+msgstr ""
+
+msgid "move applied patches into repository history"
+msgstr ""
+
+msgid ""
+"    Finishes the specified revisions (corresponding to applied\n"
+"    patches) by moving them out of mq control into regular repository\n"
+"    history."
+msgstr ""
+
+msgid ""
+"    Accepts a revision range or the -a/--applied option. If --applied\n"
+"    is specified, all applied mq revisions are removed from mq\n"
+"    control. Otherwise, the given revisions must be at the base of the\n"
+"    stack of applied patches."
+msgstr ""
+
+msgid ""
+"    This can be especially useful if your changes have been applied to\n"
+"    an upstream repository, or if you are about to push your changes\n"
+"    to upstream.\n"
+"    "
+msgstr ""
+
+msgid "no revisions specified"
+msgstr ""
+
+msgid "manage multiple patch queues"
+msgstr ""
+
+msgid ""
+"    Supports switching between different patch queues, as well as creating\n"
+"    new patch queues and deleting existing ones."
+msgstr ""
+
+msgid ""
+"    Omitting a queue name or specifying -l/--list will show you the "
+"registered\n"
+"    queues - by default the \"normal\" patches queue is registered. The "
+"currently\n"
+"    active queue will be marked with \"(active)\"."
+msgstr ""
+
+msgid ""
+"    To create a new queue, use -c/--create. The queue is automatically made\n"
+"    active, except in the case where there are applied patches from the\n"
+"    currently active queue in the repository. Then the queue will only be\n"
+"    created and switching will fail."
+msgstr ""
+
+msgid ""
+"    To delete an existing queue, use --delete. You cannot delete the "
+"currently\n"
+"    active queue.\n"
+"    "
+msgstr ""
+
+msgid "patches applied - cannot set new queue active"
+msgstr ""
+
+msgid " (active)\n"
+msgstr ""
+
+msgid "invalid queue name, may not contain the characters \":\\/.\""
+msgstr ""
+
+#, python-format
+msgid "queue \"%s\" already exists"
+msgstr ""
+
+msgid "cannot delete queue that does not exist"
+msgstr ""
+
+msgid "cannot delete currently active queue"
+msgstr ""
+
+msgid "use --create to create a new queue"
+msgstr ""
+
+msgid "cannot commit over an applied mq patch"
+msgstr ""
+
+msgid "source has mq patches applied"
+msgstr ""
+
+#, python-format
+msgid "mq status file refers to unknown node %s\n"
+msgstr ""
+
+#, python-format
+msgid "Tag %s overrides mq patch of the same name\n"
+msgstr ""
+
+msgid "cannot import over an applied patch"
+msgstr ""
+
+msgid "only a local queue repository may be initialized"
+msgstr ""
+
+msgid "There is no Mercurial repository here (.hg not found)"
+msgstr ""
+
+msgid "no queue repository"
+msgstr ""
+
+#, python-format
+msgid "%d applied"
+msgstr ""
+
+#, python-format
+msgid "%d unapplied"
+msgstr ""
+
+msgid "mq:     (empty queue)\n"
+msgstr ""
+
+msgid "operate on patch repository"
+msgstr ""
+
+msgid "print first line of patch header"
+msgstr ""
+
+msgid "show only the last patch"
+msgstr ""
+
+msgid "hg qapplied [-1] [-s] [PATCH]"
+msgstr ""
+
+msgid "use pull protocol to copy metadata"
+msgstr "folosește protocolul 'pull' pentru a copia metadatele"
+
+msgid "do not update the new working directories"
+msgstr ""
+
+msgid "use uncompressed transfer (fast over LAN)"
+msgstr "folosește transfer necomprimat (rapid în LAN)"
+
+msgid "REPO"
+msgstr ""
+
+msgid "location of source patch repository"
+msgstr ""
+
+msgid "hg qclone [OPTION]... SOURCE [DEST]"
+msgstr ""
+
+msgid "hg qcommit [OPTION]... [FILE]..."
+msgstr ""
+
+msgid "hg qdiff [OPTION]... [FILE]..."
+msgstr ""
+
+msgid "keep patch file"
+msgstr ""
+
+msgid "stop managing a revision (DEPRECATED)"
+msgstr ""
+
+msgid "hg qdelete [-k] [-r REV]... [PATCH]..."
+msgstr ""
+
+msgid "edit patch header"
+msgstr ""
+
+msgid "keep folded patch files"
+msgstr ""
+
+msgid "hg qfold [-e] [-k] [-m TEXT] [-l FILE] PATCH..."
+msgstr ""
+
+msgid "overwrite any local changes"
+msgstr ""
+
+msgid "hg qgoto [OPTION]... PATCH"
+msgstr ""
+
+msgid "list all patches and guards"
+msgstr ""
+
+msgid "drop all guards"
+msgstr ""
+
+msgid "hg qguard [-l] [-n] [PATCH] [-- [+GUARD]... [-GUARD]...]"
+msgstr ""
+
+msgid "hg qheader [PATCH]"
+msgstr ""
+
+msgid "import file in patch directory"
+msgstr ""
+
+msgid "name of patch file"
+msgstr ""
+
+msgid "overwrite existing files"
+msgstr ""
+
+msgid "place existing revisions under mq control"
+msgstr ""
+
+msgid "use git extended diff format"
+msgstr "folosește formatul diff extins al lui git"
+
+msgid "qpush after importing"
+msgstr ""
+
+msgid "hg qimport [-e] [-n NAME] [-f] [-g] [-P] [-r REV]... FILE..."
+msgstr ""
+
+msgid "create queue repository"
+msgstr ""
+
+msgid "hg qinit [-c]"
+msgstr ""
+
+msgid "import uncommitted changes (DEPRECATED)"
+msgstr ""
+
+msgid "add \"From: <current user>\" to patch"
+msgstr ""
+
+msgid "USER"
+msgstr ""
+
+msgid "add \"From: <USER>\" to patch"
+msgstr ""
+
+msgid "add \"Date: <current date>\" to patch"
+msgstr ""
+
+msgid "add \"Date: <DATE>\" to patch"
+msgstr ""
+
+msgid "hg qnew [-e] [-m TEXT] [-l FILE] PATCH [FILE]..."
+msgstr ""
+
+msgid "hg qnext [-s]"
+msgstr ""
+
+msgid "hg qprev [-s]"
+msgstr ""
+
+msgid "pop all patches"
+msgstr ""
+
+msgid "queue name to pop (DEPRECATED)"
+msgstr ""
+
+msgid "forget any local changes to patched files"
+msgstr ""
+
+msgid "hg qpop [-a] [-n NAME] [-f] [PATCH | INDEX]"
+msgstr ""
+
+msgid "apply if the patch has rejects"
+msgstr ""
+
+msgid "list patch name in commit text"
+msgstr ""
+
+msgid "apply all patches"
+msgstr ""
+
+msgid "merge from another queue (DEPRECATED)"
+msgstr ""
+
+msgid "merge queue name (DEPRECATED)"
+msgstr ""
+
+msgid "reorder patch series and apply only the patch"
+msgstr ""
+
+msgid "hg qpush [-f] [-l] [-a] [-m] [-n NAME] [--move] [PATCH | INDEX]"
+msgstr ""
+
+msgid "refresh only files already in the patch and specified files"
+msgstr ""
+
+msgid "add/update author field in patch with current user"
+msgstr ""
+
+msgid "add/update author field in patch with given user"
+msgstr ""
+
+msgid "add/update date field in patch with current date"
+msgstr ""
+
+msgid "add/update date field in patch with given date"
+msgstr ""
+
+msgid "hg qrefresh [-I] [-X] [-e] [-m TEXT] [-l FILE] [-s] [FILE]..."
+msgstr ""
+
+msgid "hg qrename PATCH1 [PATCH2]"
+msgstr ""
+
+msgid "delete save entry"
+msgstr ""
+
+msgid "update queue working directory"
+msgstr ""
+
+msgid "hg qrestore [-d] [-u] REV"
+msgstr ""
+
+msgid "copy patch directory"
+msgstr ""
+
+msgid "copy directory name"
+msgstr ""
+
+msgid "clear queue status file"
+msgstr ""
+
+msgid "force copy"
+msgstr ""
+
+msgid "hg qsave [-m TEXT] [-l FILE] [-c] [-n NAME] [-e] [-f]"
+msgstr ""
+
+msgid "disable all guards"
+msgstr ""
+
+msgid "list all guards in series file"
+msgstr ""
+
+msgid "pop to before first guarded applied patch"
+msgstr ""
+
+msgid "pop, then reapply patches"
+msgstr ""
+
+msgid "hg qselect [OPTION]... [GUARD]..."
+msgstr ""
+
+msgid "print patches not in series"
+msgstr ""
+
+msgid "hg qseries [-ms]"
+msgstr ""
+
+msgid ""
+"force removal of changesets even if the working directory has uncommitted "
+"changes"
+msgstr ""
+
+msgid ""
+"bundle only changesets with local revision number greater than REV which are "
+"not descendants of REV (DEPRECATED)"
+msgstr ""
+
+msgid "no backups"
+msgstr ""
+
+msgid "hg strip [-f] [-n] REV"
+msgstr ""
+
+msgid "hg qtop [-s]"
+msgstr ""
+
+msgid "show only the first patch"
+msgstr ""
+
+msgid "hg qunapplied [-1] [-s] [PATCH]"
+msgstr ""
+
+msgid "finish all applied changesets"
+msgstr ""
+
+msgid "hg qfinish [-a] [REV]..."
+msgstr ""
+
+msgid "list all available queues"
+msgstr ""
+
+msgid "create new queue"
+msgstr ""
+
+msgid "delete reference to queue"
+msgstr ""
+
+msgid "[OPTION] [QUEUE]"
+msgstr ""
+
+msgid "hooks for sending email notifications at commit/push time"
+msgstr ""
+
+msgid ""
+"Subscriptions can be managed through a hgrc file. Default mode is to\n"
+"print messages to stdout, for testing and configuring."
+msgstr ""
+
+msgid ""
+"To use, configure the notify extension and enable it in hgrc like\n"
+"this::"
+msgstr ""
+
+msgid ""
+"  [extensions]\n"
+"  notify ="
+msgstr ""
+
+msgid ""
+"  [hooks]\n"
+"  # one email for each incoming changeset\n"
+"  incoming.notify = python:hgext.notify.hook\n"
+"  # batch emails when many changesets incoming at one time\n"
+"  changegroup.notify = python:hgext.notify.hook"
+msgstr ""
+
+msgid ""
+"  [notify]\n"
+"  # config items go here"
+msgstr ""
+
+msgid "Required configuration items::"
+msgstr ""
+
+msgid "  config = /path/to/file # file containing subscriptions"
+msgstr ""
+
+msgid "Optional configuration items::"
+msgstr ""
+
+msgid ""
+"  test = True            # print messages to stdout for testing\n"
+"  strip = 3              # number of slashes to strip for url paths\n"
+"  domain = example.com   # domain to use if committer missing domain\n"
+"  style = ...            # style file to use when formatting email\n"
+"  template = ...         # template to use when formatting email\n"
+"  incoming = ...         # template to use when run as incoming hook\n"
+"  changegroup = ...      # template when run as changegroup hook\n"
+"  maxdiff = 300          # max lines of diffs to include (0=none, -1=all)\n"
+"  maxsubject = 67        # truncate subject line longer than this\n"
+"  diffstat = True        # add a diffstat before the diff content\n"
+"  sources = serve        # notify if source of incoming changes in this "
+"list\n"
+"                         # (serve == ssh or http, push, pull, bundle)\n"
+"  merge = False          # send notification for merges (default True)\n"
+"  [email]\n"
+"  from = user@host.com   # email address to send as if none given\n"
+"  [web]\n"
+"  baseurl = http://hgserver/... # root of hg web site for browsing commits"
+msgstr ""
+
+msgid ""
+"The notify config file has same format as a regular hgrc file. It has\n"
+"two sections so you can express subscriptions in whatever way is\n"
+"handier for you."
+msgstr ""
+
+msgid ""
+"  [usersubs]\n"
+"  # key is subscriber email, value is \",\"-separated list of glob patterns\n"
+"  user@host = pattern"
+msgstr ""
+
+msgid ""
+"  [reposubs]\n"
+"  # key is glob pattern, value is \",\"-separated list of subscriber emails\n"
+"  pattern = user@host"
+msgstr ""
+
+msgid "Glob patterns are matched against path to repository root."
+msgstr ""
+
+msgid ""
+"If you like, you can put notify config file in repository that users\n"
+"can push changes to, they can manage their own subscriptions.\n"
+msgstr ""
+
+#, python-format
+msgid "%s: %d new changesets"
+msgstr ""
+
+#, python-format
+msgid "notify: sending %d subscribers %d changes\n"
+msgstr ""
+
+#, python-format
+msgid ""
+"\n"
+"diffs (truncated from %d to %d lines):"
+msgstr ""
+
+#, python-format
+msgid ""
+"\n"
+"diffs (%d lines):"
+msgstr ""
+
+#, python-format
+msgid "notify: suppressing notification for merge %d:%s\n"
+msgstr ""
+
+msgid "browse command output with an external pager"
+msgstr ""
+
+msgid "To set the pager that should be used, set the application variable::"
+msgstr ""
+
+msgid ""
+"  [pager]\n"
+"  pager = LESS='FSRX' less"
+msgstr ""
+
+msgid ""
+"If no pager is set, the pager extensions uses the environment variable\n"
+"$PAGER. If neither pager.pager, nor $PAGER is set, no pager is used."
+msgstr ""
+
+msgid ""
+"If you notice \"BROKEN PIPE\" error messages, you can disable them by\n"
+"setting::"
+msgstr ""
+
+msgid ""
+"  [pager]\n"
+"  quiet = True"
+msgstr ""
+
+msgid ""
+"You can disable the pager for certain commands by adding them to the\n"
+"pager.ignore list::"
+msgstr ""
+
+msgid ""
+"  [pager]\n"
+"  ignore = version, help, update"
+msgstr ""
+
+msgid ""
+"You can also enable the pager only for certain commands using\n"
+"pager.attend. Below is the default list of commands to be paged::"
+msgstr ""
+
+msgid ""
+"  [pager]\n"
+"  attend = annotate, cat, diff, export, glog, log, qdiff"
+msgstr ""
+
+msgid ""
+"Setting pager.attend to an empty value will cause all commands to be\n"
+"paged."
+msgstr ""
+
+msgid "If pager.attend is present, pager.ignore will be ignored."
+msgstr ""
+
+msgid ""
+"To ignore global commands like :hg:`version` or :hg:`help`, you have\n"
+"to specify them in the global .hgrc\n"
+msgstr ""
+
+msgid "interpret suffixes to refer to ancestor revisions"
+msgstr ""
+
+msgid ""
+"This extension allows you to use git-style suffixes to refer to the\n"
+"ancestors of a specific revision."
+msgstr ""
+
+msgid "For example, if you can refer to a revision as \"foo\", then::"
+msgstr ""
+
+msgid ""
+"  foo^N = Nth parent of foo\n"
+"  foo^0 = foo\n"
+"  foo^1 = first parent of foo\n"
+"  foo^2 = second parent of foo\n"
+"  foo^  = foo^1"
+msgstr ""
+
+msgid ""
+"  foo~N = Nth first grandparent of foo\n"
+"  foo~0 = foo\n"
+"  foo~1 = foo^1 = foo^ = first parent of foo\n"
+"  foo~2 = foo^1^1 = foo^^ = first parent of first parent of foo\n"
+msgstr ""
+
+msgid "command to send changesets as (a series of) patch emails"
+msgstr ""
+
+msgid ""
+"The series is started off with a \"[PATCH 0 of N]\" introduction, which\n"
+"describes the series as a whole."
+msgstr ""
+
+msgid ""
+"Each patch email has a Subject line of \"[PATCH M of N] ...\", using the\n"
+"first line of the changeset description as the subject text. The\n"
+"message contains two or three body parts:"
+msgstr ""
+
+msgid ""
+"- The changeset description.\n"
+"- [Optional] The result of running diffstat on the patch.\n"
+"- The patch itself, as generated by :hg:`export`."
+msgstr ""
+
+msgid ""
+"Each message refers to the first in the series using the In-Reply-To\n"
+"and References headers, so they will show up as a sequence in threaded\n"
+"mail and news readers, and in mail archives."
+msgstr ""
+
+msgid ""
+"With the -d/--diffstat option, you will be prompted for each changeset\n"
+"with a diffstat summary and the changeset summary, so you can be sure\n"
+"you are sending the right changes."
+msgstr ""
+
+msgid ""
+"To configure other defaults, add a section like this to your hgrc\n"
+"file::"
+msgstr ""
+
+msgid ""
+"  [email]\n"
+"  from = My Name <my@email>\n"
+"  to = recipient1, recipient2, ...\n"
+"  cc = cc1, cc2, ...\n"
+"  bcc = bcc1, bcc2, ...\n"
+"  reply-to = address1, address2, ..."
+msgstr ""
+
+msgid ""
+"Use ``[patchbomb]`` as configuration section name if you need to\n"
+"override global ``[email]`` address settings."
+msgstr ""
+
+msgid ""
+"Then you can use the :hg:`email` command to mail a series of\n"
+"changesets as a patchbomb."
+msgstr ""
+
+msgid ""
+"To avoid sending patches prematurely, it is a good idea to first run\n"
+"the :hg:`email` command with the \"-n\" option (test only). You will be\n"
+"prompted for an email recipient address, a subject and an introductory\n"
+"message describing the patches of your patchbomb. Then when all is\n"
+"done, patchbomb messages are displayed. If the PAGER environment\n"
+"variable is set, your pager will be fired up once for each patchbomb\n"
+"message, so you can verify everything is alright."
+msgstr ""
+
+msgid ""
+"The -m/--mbox option is also very useful. Instead of previewing each\n"
+"patchbomb message in a pager or sending the messages directly, it will\n"
+"create a UNIX mailbox file with the patch emails. This mailbox file\n"
+"can be previewed with any mail user agent which supports UNIX mbox\n"
+"files, e.g. with mutt::"
+msgstr ""
+
+msgid "  % mutt -R -f mbox"
+msgstr ""
+
+msgid ""
+"When you are previewing the patchbomb messages, you can use ``formail``\n"
+"(a utility that is commonly installed as part of the procmail\n"
+"package), to send each message out::"
+msgstr ""
+
+msgid "  % formail -s sendmail -bm -t < mbox"
+msgstr ""
+
+msgid "That should be all. Now your patchbomb is on its way out."
+msgstr ""
+
+msgid ""
+"You can also either configure the method option in the email section\n"
+"to be a sendmail compatible mailer or fill out the [smtp] section so\n"
+"that the patchbomb extension can automatically send patchbombs\n"
+"directly from the commandline. See the [email] and [smtp] sections in\n"
+"hgrc(5) for details.\n"
+msgstr ""
+
+#, python-format
+msgid "%s Please enter a valid value"
+msgstr ""
+
+msgid "Please enter a valid value.\n"
+msgstr ""
+
+msgid "does the diffstat above look okay?"
+msgstr ""
+
+msgid "diffstat rejected"
+msgstr ""
+
+msgid "send changesets by email"
+msgstr ""
+
+msgid ""
+"    By default, diffs are sent in the format generated by\n"
+"    :hg:`export`, one per message. The series starts with a \"[PATCH 0\n"
+"    of N]\" introduction, which describes the series as a whole."
+msgstr ""
+
+msgid ""
+"    Each patch email has a Subject line of \"[PATCH M of N] ...\", using\n"
+"    the first line of the changeset description as the subject text.\n"
+"    The message contains two or three parts. First, the changeset\n"
+"    description. Next, (optionally) if the diffstat program is\n"
+"    installed and -d/--diffstat is used, the result of running\n"
+"    diffstat on the patch. Finally, the patch itself, as generated by\n"
+"    :hg:`export`."
+msgstr ""
+
+msgid ""
+"    By default the patch is included as text in the email body for\n"
+"    easy reviewing. Using the -a/--attach option will instead create\n"
+"    an attachment for the patch. With -i/--inline an inline attachment\n"
+"    will be created."
+msgstr ""
+
+msgid ""
+"    With -o/--outgoing, emails will be generated for patches not found\n"
+"    in the destination repository (or only those which are ancestors\n"
+"    of the specified revisions if any are provided)"
+msgstr ""
+
+msgid ""
+"    With -b/--bundle, changesets are selected as for --outgoing, but a\n"
+"    single email containing a binary Mercurial bundle as an attachment\n"
+"    will be sent."
+msgstr ""
+
+msgid ""
+"      hg email -r 3000          # send patch 3000 only\n"
+"      hg email -r 3000 -r 3001  # send patches 3000 and 3001\n"
+"      hg email -r 3000:3005     # send patches 3000 through 3005\n"
+"      hg email 3000             # send patch 3000 (deprecated)"
+msgstr ""
+
+msgid ""
+"      hg email -o               # send all patches not in default\n"
+"      hg email -o DEST          # send all patches not in DEST\n"
+"      hg email -o -r 3000       # send all ancestors of 3000 not in default\n"
+"      hg email -o -r 3000 DEST  # send all ancestors of 3000 not in DEST"
+msgstr ""
+
+msgid ""
+"      hg email -b               # send bundle of all patches not in default\n"
+"      hg email -b DEST          # send bundle of all patches not in DEST\n"
+"      hg email -b -r 3000       # bundle of all ancestors of 3000 not in "
+"default\n"
+"      hg email -b -r 3000 DEST  # bundle of all ancestors of 3000 not in DEST"
+msgstr ""
+
+msgid ""
+"    Before using this command, you will need to enable email in your\n"
+"    hgrc. See the [email] section in hgrc(5) for details.\n"
+"    "
+msgstr ""
+
+msgid "specify at least one changeset with -r or -o"
+msgstr ""
+
+msgid "--outgoing mode always on with --bundle; do not re-specify --outgoing"
+msgstr ""
+
+msgid "too many destinations"
+msgstr ""
+
+msgid "use only one form to specify the revision"
+msgstr ""
+
+msgid ""
+"\n"
+"Write the introductory message for the patch series."
+msgstr ""
+
+#, python-format
+msgid "This patch series consists of %d patches."
+msgstr ""
+
+msgid "Final summary:\n"
+msgstr ""
+
+msgid "Displaying "
+msgstr ""
+
+msgid "Writing "
+msgstr ""
+
+msgid "Sending "
+msgstr ""
+
+msgid "send patches as attachments"
+msgstr ""
+
+msgid "send patches as inline attachments"
+msgstr ""
+
+msgid "email addresses of blind carbon copy recipients"
+msgstr ""
+
+msgid "email addresses of copy recipients"
+msgstr ""
+
+msgid "add diffstat output to messages"
+msgstr ""
+
+msgid "use the given date as the sending date"
+msgstr ""
+
+msgid "use the given file as the series description"
+msgstr ""
+
+msgid "email address of sender"
+msgstr ""
+
+msgid "print messages that would be sent"
+msgstr ""
+
+msgid "write messages to mbox file instead of sending them"
+msgstr ""
+
+msgid "email addresses replies should be sent to"
+msgstr ""
+
+msgid "subject of first message (intro or single patch)"
+msgstr ""
+
+msgid "message identifier to reply to"
+msgstr ""
+
+msgid "flags to add in subject prefixes"
+msgstr ""
+
+msgid "email addresses of recipients"
+msgstr ""
+
+msgid "omit hg patch header"
+msgstr ""
+
+msgid "send changes not found in the target repository"
+msgstr ""
+
+msgid "send changes not in target as a binary bundle"
+msgstr ""
+
+msgid "name of the bundle attachment file"
+msgstr ""
+
+msgid "a revision to send"
+msgstr ""
+
+msgid "run even when remote repository is unrelated (with -b/--bundle)"
+msgstr ""
+
+msgid "a base changeset to specify instead of a destination (with -b/--bundle)"
+msgstr ""
+
+msgid "send an introduction email for a single patch"
+msgstr ""
+
+msgid "hg email [OPTION]... [DEST]..."
+msgstr ""
+
+msgid "show progress bars for some actions"
+msgstr ""
+
+msgid ""
+"This extension uses the progress information logged by hg commands\n"
+"to draw progress bars that are as informative as possible. Some progress\n"
+"bars only offer indeterminate information, while others have a definite\n"
+"end point."
+msgstr ""
+
+msgid "The following settings are available::"
+msgstr ""
+
+msgid ""
+"  [progress]\n"
+"  delay = 3 # number of seconds (float) before showing the progress bar\n"
+"  refresh = 0.1 # time in seconds between refreshes of the progress bar\n"
+"  format = topic bar number # format of the progress bar\n"
+"  width = <none> # if set, the maximum width of the progress information\n"
+"                 # (that is, min(width, term width) will be used)\n"
+"  clear-complete = True # clear the progress bar after it's done\n"
+"  disable = False # if true, don't show a progress bar\n"
+"  assume-tty = False # if true, ALWAYS show a progress bar, unless\n"
+"                     # disable is given"
+msgstr ""
+
+msgid ""
+"Valid entries for the format field are topic, bar, number, unit, and\n"
+"item. item defaults to the last 20 characters of the item, but this\n"
+"can be changed by adding either ``-<num>`` which would take the last\n"
+"num characters, or ``+<num>`` for the first num characters.\n"
+msgstr ""
+
+msgid "command to delete untracked files from the working directory"
+msgstr ""
+
+msgid "removes files not tracked by Mercurial"
+msgstr ""
+
+msgid ""
+"    Delete files not known to Mercurial. This is useful to test local\n"
+"    and uncommitted changes in an otherwise-clean source tree."
+msgstr ""
+
+msgid "    This means that purge will delete:"
+msgstr ""
+
+msgid ""
+"    - Unknown files: files marked with \"?\" by :hg:`status`\n"
+"    - Empty directories: in fact Mercurial ignores directories unless\n"
+"      they contain files under source control management"
+msgstr ""
+
+msgid "    But it will leave untouched:"
+msgstr ""
+
+msgid ""
+"    - Modified and unmodified tracked files\n"
+"    - Ignored files (unless --all is specified)\n"
+"    - New files added to the repository (with :hg:`add`)"
+msgstr ""
+
+msgid ""
+"    If directories are given on the command line, only files in these\n"
+"    directories are considered."
+msgstr ""
+
+msgid ""
+"    Be careful with purge, as you could irreversibly delete some files\n"
+"    you forgot to add to the repository. If you only want to print the\n"
+"    list of files that this program would delete, use the --print\n"
+"    option.\n"
+"    "
+msgstr ""
+
+#, python-format
+msgid "%s cannot be removed"
+msgstr ""
+
+#, python-format
+msgid "warning: %s\n"
+msgstr ""
+
+#, python-format
+msgid "Removing file %s\n"
+msgstr ""
+
+#, python-format
+msgid "Removing directory %s\n"
+msgstr ""
+
+msgid "abort if an error occurs"
+msgstr ""
+
+msgid "purge ignored files too"
+msgstr ""
+
+msgid "print filenames instead of deleting them"
+msgstr ""
+
+msgid "end filenames with NUL, for use with xargs (implies -p/--print)"
+msgstr ""
+
+msgid "hg purge [OPTION]... [DIR]..."
+msgstr ""
+
+msgid "command to move sets of revisions to a different ancestor"
+msgstr ""
+
+msgid ""
+"This extension lets you rebase changesets in an existing Mercurial\n"
+"repository."
+msgstr ""
+
+msgid ""
+"For more information:\n"
+"http://mercurial.selenic.com/wiki/RebaseExtension\n"
+msgstr ""
+
+msgid "move changeset (and descendants) to a different branch"
+msgstr ""
+
+msgid ""
+"    Rebase uses repeated merging to graft changesets from one part of\n"
+"    history (the source) onto another (the destination). This can be\n"
+"    useful for linearizing *local* changes relative to a master\n"
+"    development tree."
+msgstr ""
+
+msgid ""
+"    You should not rebase changesets that have already been shared\n"
+"    with others. Doing so will force everybody else to perform the\n"
+"    same rebase or they will end up with duplicated changesets after\n"
+"    pulling in your rebased changesets."
+msgstr ""
+
+msgid ""
+"    If you don't specify a destination changeset (``-d/--dest``),\n"
+"    rebase uses the tipmost head of the current named branch as the\n"
+"    destination. (The destination changeset is not modified by\n"
+"    rebasing, but new changesets are added as its descendants.)"
+msgstr ""
+
+msgid ""
+"    You can specify which changesets to rebase in two ways: as a\n"
+"    \"source\" changeset or as a \"base\" changeset. Both are shorthand\n"
+"    for a topologically related set of changesets (the \"source\n"
+"    branch\"). If you specify source (``-s/--source``), rebase will\n"
+"    rebase that changeset and all of its descendants onto dest. If you\n"
+"    specify base (``-b/--base``), rebase will select ancestors of base\n"
+"    back to but not including the common ancestor with dest. Thus,\n"
+"    ``-b`` is less precise but more convenient than ``-s``: you can\n"
+"    specify any changeset in the source branch, and rebase will select\n"
+"    the whole branch. If you specify neither ``-s`` nor ``-b``, rebase\n"
+"    uses the parent of the working directory as the base."
+msgstr ""
+
+msgid ""
+"    By default, rebase recreates the changesets in the source branch\n"
+"    as descendants of dest and then destroys the originals. Use\n"
+"    ``--keep`` to preserve the original source changesets. Some\n"
+"    changesets in the source branch (e.g. merges from the destination\n"
+"    branch) may be dropped if they no longer contribute any change."
+msgstr ""
+
+msgid ""
+"    One result of the rules for selecting the destination changeset\n"
+"    and source branch is that, unlike ``merge``, rebase will do\n"
+"    nothing if you are at the latest (tipmost) head of a named branch\n"
+"    with two heads. You need to explicitly specify source and/or\n"
+"    destination (or ``update`` to the other head, if it's the head of\n"
+"    the intended source branch)."
+msgstr ""
+
+msgid ""
+"    If a rebase is interrupted to manually resolve a merge, it can be\n"
+"    continued with --continue/-c or aborted with --abort/-a."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success, 1 if nothing to rebase.\n"
+"    "
+msgstr ""
+
+msgid "cannot use both abort and continue"
+msgstr ""
+
+msgid "cannot use collapse with continue or abort"
+msgstr ""
+
+msgid "cannot use detach with continue or abort"
+msgstr ""
+
+msgid "abort and continue do not allow specifying revisions"
+msgstr ""
+
+msgid "cannot specify both a revision and a base"
+msgstr ""
+
+msgid "detach requires a revision to be specified"
+msgstr ""
+
+msgid "cannot specify a base with detach"
+msgstr ""
+
+msgid "nothing to rebase\n"
+msgstr ""
+
+msgid "cannot use both keepbranches and extrafn"
+msgstr ""
+
+#, fuzzy
+msgid " changesets"
+msgstr "se adaugă seturile de modificări\n"
+
+#, fuzzy
+msgid "rebasing"
+msgstr "revizia"
+
+msgid "fix unresolved conflicts with hg resolve then run hg rebase --continue"
+msgstr ""
+
+#, python-format
+msgid "no changes, revision %d skipped\n"
+msgstr ""
+
+msgid "rebase merging completed\n"
+msgstr ""
+
+msgid "warning: new changesets detected on source branch, not stripping\n"
+msgstr ""
+
+msgid "rebase completed\n"
+msgstr ""
+
+#, python-format
+msgid "%d revisions have been skipped\n"
+msgstr ""
+
+msgid "unable to collapse, there is more than one external parent"
+msgstr ""
+
+#, python-format
+msgid "cannot use revision %d as base, result would have 3 parents"
+msgstr ""
+
+msgid "no rebase in progress"
+msgstr ""
+
+msgid "warning: new changesets detected on target branch, can't abort\n"
+msgstr ""
+
+msgid "rebase aborted\n"
+msgstr ""
+
+msgid "cannot rebase onto an applied mq patch"
+msgstr ""
+
+msgid "source is ancestor of destination"
+msgstr ""
+
+msgid "source is descendant of destination"
+msgstr ""
+
+msgid "rebase working directory to branch head"
+msgstr ""
+
+msgid "rebase from the specified changeset"
+msgstr ""
+
+msgid ""
+"rebase from the base of the specified changeset (up to greatest common "
+"ancestor of base and dest)"
+msgstr ""
+
+msgid "rebase onto the specified changeset"
+msgstr ""
+
+msgid "collapse the rebased changesets"
+msgstr ""
+
+msgid "keep original changesets"
+msgstr ""
+
+msgid "keep original branch names"
+msgstr ""
+
+msgid "force detaching of source from its original branch"
+msgstr ""
+
+msgid "continue an interrupted rebase"
+msgstr ""
+
+msgid "abort an interrupted rebase"
+msgstr ""
+
+msgid ""
+"hg rebase [-s REV | -b REV] [-d REV] [options]\n"
+"hg rebase {-a|-c}"
+msgstr ""
+
+msgid "commands to interactively select changes for commit/qrefresh"
+msgstr ""
+
+msgid "this modifies a binary file (all or nothing)\n"
+msgstr ""
+
+msgid "this is a binary file\n"
+msgstr ""
+
+#, python-format
+msgid "%d hunks, %d lines changed\n"
+msgstr ""
+
+msgid "[Ynsfdaq?]"
+msgstr ""
+
+msgid "&Yes, record this change"
+msgstr ""
+
+msgid "&No, skip this change"
+msgstr ""
+
+msgid "&Skip remaining changes to this file"
+msgstr ""
+
+msgid "Record remaining changes to this &file"
+msgstr ""
+
+msgid "&Done, skip remaining changes and files"
+msgstr ""
+
+msgid "Record &all changes to all remaining files"
+msgstr ""
+
+msgid "&Quit, recording no changes"
+msgstr ""
+
+msgid "&?"
+msgstr ""
+
+msgid "user quit"
+msgstr ""
+
+#, python-format
+msgid "examine changes to %s?"
+msgstr ""
+
+msgid " and "
+msgstr ""
+
+#, python-format
+msgid "record this change to %r?"
+msgstr ""
+
+#, python-format
+msgid "record change %d/%d to %r?"
+msgstr ""
+
+msgid "interactively select changes to commit"
+msgstr ""
+
+msgid ""
+"    If a list of files is omitted, all changes reported by :hg:`status`\n"
+"    will be candidates for recording."
+msgstr ""
+
+msgid "    See :hg:`help dates` for a list of formats valid for -d/--date."
+msgstr ""
+"    Vezi :hg:`help dates` pentru o listă de formate valide cu d/--date."
+
+msgid ""
+"    You will be prompted for whether to record changes to each\n"
+"    modified file, and for files with multiple changes, for each\n"
+"    change to use. For each query, the following responses are\n"
+"    possible::"
+msgstr ""
+
+msgid ""
+"      y - record this change\n"
+"      n - skip this change"
+msgstr ""
+
+msgid ""
+"      s - skip remaining changes to this file\n"
+"      f - record remaining changes to this file"
+msgstr ""
+
+msgid ""
+"      d - done, skip remaining changes and files\n"
+"      a - record all changes to all remaining files\n"
+"      q - quit, recording no changes"
+msgstr ""
+
+msgid "      ? - display help"
+msgstr ""
+
+msgid "    This command is not available when committing a merge."
+msgstr ""
+
+msgid "'mq' extension not loaded"
+msgstr ""
+
+msgid "running non-interactively, use commit instead"
+msgstr ""
+
+msgid "cannot partially commit a merge (use hg commit instead)"
+msgstr ""
+
+msgid "no changes to record\n"
+msgstr ""
+
+msgid "patch failed to apply"
+msgstr ""
+
+msgid "hg record [OPTION]... [FILE]..."
+msgstr ""
+
+msgid "hg qrecord [OPTION]... PATCH [FILE]..."
+msgstr ""
+
+msgid "recreates hardlinks between repository clones"
+msgstr ""
+
+msgid "recreate hardlinks between two repositories"
+msgstr ""
+
+msgid ""
+"    When repositories are cloned locally, their data files will be\n"
+"    hardlinked so that they only use the space of a single repository."
+msgstr ""
+
+msgid ""
+"    Unfortunately, subsequent pulls into either repository will break\n"
+"    hardlinks for any files touched by the new changesets, even if\n"
+"    both repositories end up pulling the same changes."
+msgstr ""
+
+msgid ""
+"    Similarly, passing --rev to \"hg clone\" will fail to use any\n"
+"    hardlinks, falling back to a complete copy of the source\n"
+"    repository."
+msgstr ""
+
+msgid ""
+"    This command lets you recreate those hardlinks and reclaim that\n"
+"    wasted space."
+msgstr ""
+
+msgid ""
+"    This repository will be relinked to share space with ORIGIN, which\n"
+"    must be on the same local disk. If ORIGIN is omitted, looks for\n"
+"    \"default-relink\", then \"default\", in [paths]."
+msgstr ""
+
+msgid ""
+"    Do not attempt any read operations on this repository while the\n"
+"    command is running. (Both repositories will be locked against\n"
+"    writes.)\n"
+"    "
+msgstr ""
+
+msgid "hardlinks are not supported on this system"
+msgstr ""
+
+#, python-format
+msgid "relinking %s to %s\n"
+msgstr ""
+
+#, python-format
+msgid "tip has %d files, estimated total number of files: %s\n"
+msgstr ""
+
+msgid "collecting"
+msgstr ""
+
+msgid "files"
+msgstr ""
+
+#, python-format
+msgid "collected %d candidate storage files\n"
+msgstr ""
+
+msgid "source and destination are on different devices"
+msgstr ""
+
+#, python-format
+msgid "not linkable: %s\n"
+msgstr ""
+
+msgid " files"
+msgstr ""
+
+msgid "pruning"
+msgstr ""
+
+#, python-format
+msgid "pruned down to %d probably relinkable files\n"
+msgstr ""
+
+msgid "relinking"
+msgstr ""
+
+#, python-format
+msgid "relinked %d files (%d bytes reclaimed)\n"
+msgstr ""
+
+msgid "[ORIGIN]"
+msgstr ""
+
+msgid "extend schemes with shortcuts to repository swarms"
+msgstr ""
+
+msgid ""
+"This extension allows you to specify shortcuts for parent URLs with a\n"
+"lot of repositories to act like a scheme, for example::"
+msgstr ""
+
+msgid ""
+"  [schemes]\n"
+"  py = http://code.python.org/hg/"
+msgstr ""
+
+msgid "After that you can use it like::"
+msgstr ""
+
+msgid "  hg clone py://trunk/"
+msgstr ""
+
+msgid ""
+"Additionally there is support for some more complex schemas, for\n"
+"example used by Google Code::"
+msgstr ""
+
+msgid ""
+"  [schemes]\n"
+"  gcode = http://{1}.googlecode.com/hg/"
+msgstr ""
+
+msgid ""
+"The syntax is taken from Mercurial templates, and you have unlimited\n"
+"number of variables, starting with ``{1}`` and continuing with\n"
+"``{2}``, ``{3}`` and so on. This variables will receive parts of URL\n"
+"supplied, split by ``/``. Anything not specified as ``{part}`` will be\n"
+"just appended to an URL."
+msgstr ""
+
+msgid "For convenience, the extension adds these schemes by default::"
+msgstr ""
+
+msgid ""
+"  [schemes]\n"
+"  py = http://hg.python.org/\n"
+"  bb = https://bitbucket.org/\n"
+"  bb+ssh = ssh://hg@bitbucket.org/\n"
+"  gcode = https://{1}.googlecode.com/hg/\n"
+"  kiln = https://{1}.kilnhg.com/Repo/"
+msgstr ""
+
+msgid ""
+"You can override a predefined scheme by defining a new scheme with the\n"
+"same name.\n"
+msgstr ""
+
+msgid "share a common history between several working directories"
+msgstr ""
+
+msgid "create a new shared repository"
+msgstr ""
+
+msgid ""
+"    Initialize a new repository and working directory that shares its\n"
+"    history with another repository."
+msgstr ""
+
+msgid ""
+"    NOTE: using rollback or extensions that destroy/modify history\n"
+"    (mq, rebase, etc.) can cause considerable confusion with shared\n"
+"    clones. In particular, if two shared clones are both updated to\n"
+"    the same changeset, and one of them destroys that changeset with\n"
+"    rollback, the other clone will suddenly stop working: all\n"
+"    operations will fail with \"abort: working directory has unknown\n"
+"    parent\". The only known workaround is to use debugsetparents on\n"
+"    the broken clone to reset it to a changeset that still exists\n"
+"    (e.g. tip).\n"
+"    "
+msgstr ""
+
+msgid "do not create a working copy"
+msgstr ""
+
+msgid "[-U] SOURCE [DEST]"
+msgstr ""
+
+msgid "command to transplant changesets from another branch"
+msgstr ""
+
+msgid "This extension allows you to transplant patches from another branch."
+msgstr ""
+
+msgid ""
+"Transplanted patches are recorded in .hg/transplant/transplants, as a\n"
+"map from a changeset hash to its hash in the source repository.\n"
+msgstr ""
+
+#, python-format
+msgid "skipping already applied revision %s\n"
+msgstr ""
+
+#, python-format
+msgid "skipping merge changeset %s:%s\n"
+msgstr ""
+
+#, python-format
+msgid "%s merged at %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s transplanted to %s\n"
+msgstr ""
+
+#, python-format
+msgid "filtering %s\n"
+msgstr ""
+
+msgid "filter failed"
+msgstr ""
+
+msgid "can only omit patchfile if merging"
+msgstr ""
+
+#, python-format
+msgid "%s: empty changeset"
+msgstr ""
+
+msgid "Fix up the merge and run hg transplant --continue"
+msgstr ""
+
+#, python-format
+msgid "%s transplanted as %s\n"
+msgstr ""
+
+msgid "transplant log file is corrupt"
+msgstr ""
+
+#, python-format
+msgid "working dir not at transplant parent %s"
+msgstr ""
+
+msgid "commit failed"
+msgstr ""
+
+msgid ""
+"y: transplant this changeset\n"
+"n: skip this changeset\n"
+"m: merge at this changeset\n"
+"p: show patch\n"
+"c: commit selected changesets\n"
+"q: cancel transplant\n"
+"?: show this help\n"
+msgstr ""
+
+msgid "apply changeset? [ynmpcq?]:"
+msgstr ""
+
+msgid "no such option\n"
+msgstr ""
+
+msgid "transplant changesets from another branch"
+msgstr ""
+
+msgid ""
+"    Selected changesets will be applied on top of the current working\n"
+"    directory with the log of the original changeset. If --log is\n"
+"    specified, log messages will have a comment appended of the form::"
+msgstr ""
+
+msgid "      (transplanted from CHANGESETHASH)"
+msgstr ""
+
+msgid ""
+"    You can rewrite the changelog message with the --filter option.\n"
+"    Its argument will be invoked with the current changelog message as\n"
+"    $1 and the patch as $2."
+msgstr ""
+
+msgid ""
+"    If --source/-s is specified, selects changesets from the named\n"
+"    repository. If --branch/-b is specified, selects changesets from\n"
+"    the branch holding the named revision, up to that revision. If\n"
+"    --all/-a is specified, all changesets on the branch will be\n"
+"    transplanted, otherwise you will be prompted to select the\n"
+"    changesets you want."
+msgstr ""
+
+msgid ""
+"    :hg:`transplant --branch REVISION --all` will rebase the selected\n"
+"    branch (up to the named revision) onto your current working\n"
+"    directory."
+msgstr ""
+
+msgid ""
+"    You can optionally mark selected transplanted changesets as merge\n"
+"    changesets. You will not be prompted to transplant any ancestors\n"
+"    of a merged transplant, and you can merge descendants of them\n"
+"    normally instead of transplanting them."
+msgstr ""
+
+msgid ""
+"    If no merges or revisions are provided, :hg:`transplant` will\n"
+"    start an interactive changeset browser."
+msgstr ""
+
+msgid ""
+"    If a changeset application fails, you can fix the merge by hand\n"
+"    and then resume where you left off by calling :hg:`transplant\n"
+"    --continue/-c`.\n"
+"    "
+msgstr ""
+
+msgid "--continue is incompatible with branch, all or merge"
+msgstr ""
+
+msgid "no source URL, branch tag or revision list provided"
+msgstr ""
+
+msgid "--all requires a branch revision"
+msgstr ""
+
+msgid "--all is incompatible with a revision list"
+msgstr ""
+
+msgid "no revision checked out"
+msgstr ""
+
+msgid "outstanding uncommitted merges"
+msgstr ""
+
+msgid "outstanding local changes"
+msgstr ""
+
+msgid "pull patches from REPO"
+msgstr ""
+
+msgid "BRANCH"
+msgstr ""
+
+msgid "pull patches from branch BRANCH"
+msgstr ""
+
+msgid "pull all changesets up to BRANCH"
+msgstr ""
+
+msgid "skip over REV"
+msgstr ""
+
+msgid "merge at REV"
+msgstr ""
+
+msgid "append transplant info to log message"
+msgstr ""
+
+msgid "continue last transplant session after repair"
+msgstr ""
+
+msgid "filter changesets through command"
+msgstr ""
+
+msgid "hg transplant [-s REPO] [-b BRANCH [-a]] [-p REV] [-m REV] [REV]..."
+msgstr ""
+
+msgid "allow the use of MBCS paths with problematic encodings"
+msgstr ""
+
+msgid ""
+"Some MBCS encodings are not good for some path operations (i.e.\n"
+"splitting path, case conversion, etc.) with its encoded bytes. We call\n"
+"such a encoding (i.e. shift_jis and big5) as \"problematic encoding\".\n"
+"This extension can be used to fix the issue with those encodings by\n"
+"wrapping some functions to convert to Unicode string before path\n"
+"operation."
+msgstr ""
+
+msgid "This extension is useful for:"
+msgstr ""
+
+msgid ""
+"- Japanese Windows users using shift_jis encoding.\n"
+"- Chinese Windows users using big5 encoding.\n"
+"- All users who use a repository with one of problematic encodings on\n"
+"  case-insensitive file system."
+msgstr ""
+
+msgid "This extension is not needed for:"
+msgstr ""
+
+msgid ""
+"- Any user who use only ASCII chars in path.\n"
+"- Any user who do not use any of problematic encodings."
+msgstr ""
+
+msgid "Note that there are some limitations on using this extension:"
+msgstr ""
+
+msgid "- You should use single encoding in one repository."
+msgstr ""
+
+msgid ""
+"\n"
+"By default, win32mbcs uses encoding.encoding decided by Mercurial.\n"
+"You can specify the encoding by config option::"
+msgstr ""
+
+msgid ""
+" [win32mbcs]\n"
+" encoding = sjis"
+msgstr ""
+
+msgid "It is useful for the users who want to commit with UTF-8 log message.\n"
+msgstr ""
+
+#, python-format
+msgid "[win32mbcs] filename conversion failed with %s encoding\n"
+msgstr ""
+
+msgid "[win32mbcs] cannot activate on this platform.\n"
+msgstr ""
+
+msgid "perform automatic newline conversion"
+msgstr ""
+
+msgid ""
+"  Deprecation: The win32text extension requires each user to configure\n"
+"  the extension again and again for each clone since the configuration\n"
+"  is not copied when cloning."
+msgstr ""
+
+msgid ""
+"  We have therefore made the ``eol`` as an alternative. The ``eol``\n"
+"  uses a version controlled file for its configuration and each clone\n"
+"  will therefore use the right settings from the start."
+msgstr ""
+
+msgid "To perform automatic newline conversion, use::"
+msgstr ""
+
+msgid ""
+"  [extensions]\n"
+"  win32text =\n"
+"  [encode]\n"
+"  ** = cleverencode:\n"
+"  # or ** = macencode:"
+msgstr ""
+
+msgid ""
+"  [decode]\n"
+"  ** = cleverdecode:\n"
+"  # or ** = macdecode:"
+msgstr ""
+
+msgid ""
+"If not doing conversion, to make sure you do not commit CRLF/CR by accident::"
+msgstr ""
+
+msgid ""
+"  [hooks]\n"
+"  pretxncommit.crlf = python:hgext.win32text.forbidcrlf\n"
+"  # or pretxncommit.cr = python:hgext.win32text.forbidcr"
+msgstr ""
+
+msgid ""
+"To do the same check on a server to prevent CRLF/CR from being\n"
+"pushed or pulled::"
+msgstr ""
+
+msgid ""
+"  [hooks]\n"
+"  pretxnchangegroup.crlf = python:hgext.win32text.forbidcrlf\n"
+"  # or pretxnchangegroup.cr = python:hgext.win32text.forbidcr\n"
+msgstr ""
+
+#, python-format
+msgid ""
+"WARNING: %s already has %s line endings\n"
+"and does not need EOL conversion by the win32text plugin.\n"
+"Before your next commit, please reconsider your encode/decode settings in \n"
+"Mercurial.ini or %s.\n"
+msgstr ""
+
+#, python-format
+msgid "Attempt to commit or push text file(s) using %s line endings\n"
+msgstr ""
+
+#, python-format
+msgid "in %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid ""
+"\n"
+"To prevent this mistake in your local repository,\n"
+"add to Mercurial.ini or .hg/hgrc:"
+msgstr ""
+
+#, python-format
+msgid ""
+"[hooks]\n"
+"pretxncommit.%s = python:hgext.win32text.forbid%s"
+msgstr ""
+
+#, python-format
+msgid "and also consider adding:"
+msgstr ""
+
+#, python-format
+msgid ""
+"[extensions]\n"
+"win32text =\n"
+"[encode]\n"
+"** = %sencode:\n"
+"[decode]\n"
+"** = %sdecode:\n"
+msgstr ""
+
+msgid "discover and advertise repositories on the local network"
+msgstr ""
+
+msgid ""
+"Zeroconf-enabled repositories will be announced in a network without\n"
+"the need to configure a server or a service. They can be discovered\n"
+"without knowing their actual IP address."
+msgstr ""
+
+msgid ""
+"To allow other people to discover your repository using run\n"
+":hg:`serve` in your repository::"
+msgstr ""
+
+msgid ""
+"  $ cd test\n"
+"  $ hg serve"
+msgstr ""
+
+msgid ""
+"You can discover Zeroconf-enabled repositories by running\n"
+":hg:`paths`::"
+msgstr ""
+
+msgid ""
+"  $ hg paths\n"
+"  zc-test = http://example.com:8000/test\n"
+msgstr ""
+
+msgid "archive prefix contains illegal components"
+msgstr ""
+
+msgid "cannot give prefix when archiving to files"
+msgstr ""
+
+#, python-format
+msgid "unknown archive type '%s'"
+msgstr ""
+
+msgid "invalid changegroup"
+msgstr ""
+
+msgid "unknown parent"
+msgstr ""
+
+#, python-format
+msgid "integrity check failed on %s:%d"
+msgstr ""
+
+#, python-format
+msgid "%s: not a Mercurial bundle file"
+msgstr ""
+
+#, python-format
+msgid "%s: unknown bundle version"
+msgstr ""
+
+#, python-format
+msgid "%s: unknown bundle compression type"
+msgstr ""
+
+msgid "cannot create new bundle repository"
+msgstr ""
+
+#, python-format
+msgid "premature EOF reading chunk (got %d bytes, expected %d)"
+msgstr ""
+
+msgid "empty username"
+msgstr ""
+
+#, python-format
+msgid "username %s contains a newline"
+msgstr ""
+
+#, python-format
+msgid "the name '%s' is reserved"
+msgstr ""
+
+msgid "options --message and --logfile are mutually exclusive"
+msgstr ""
+
+#, python-format
+msgid "can't read commit message '%s': %s"
+msgstr ""
+
+msgid "limit must be a positive integer"
+msgstr ""
+
+msgid "limit must be positive"
+msgstr ""
+
+msgid "too many revisions specified"
+msgstr ""
+
+#, python-format
+msgid "invalid format spec '%%%s' in output filename"
+msgstr ""
+
+#, python-format
+msgid "adding %s\n"
+msgstr "se adaugă %s\n"
+
+#, python-format
+msgid "removing %s\n"
+msgstr ""
+
+#, python-format
+msgid "recording removal of %s as rename to %s (%d%% similar)\n"
+msgstr ""
+
+#, python-format
+msgid "%s: not copying - file is not managed\n"
+msgstr ""
+
+#, python-format
+msgid "%s: not copying - file has been marked for remove\n"
+msgstr ""
+
+#, python-format
+msgid "%s: not overwriting - %s collides with %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s: not overwriting - file exists\n"
+msgstr ""
+
+#, python-format
+msgid "%s: not recording move - %s does not exist\n"
+msgstr ""
+
+#, python-format
+msgid "%s: not recording copy - %s does not exist\n"
+msgstr ""
+
+#, python-format
+msgid "%s: deleted in working copy\n"
+msgstr ""
+
+#, python-format
+msgid "%s: cannot copy - %s\n"
+msgstr ""
+
+#, python-format
+msgid "moving %s to %s\n"
+msgstr ""
+
+#, python-format
+msgid "copying %s to %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s has not been committed yet, so no copy data will be stored for %s.\n"
+msgstr ""
+
+msgid "no source or destination specified"
+msgstr ""
+
+msgid "no destination specified"
+msgstr ""
+
+msgid "with multiple sources, destination must be an existing directory"
+msgstr ""
+
+#, python-format
+msgid "destination %s is not a directory"
+msgstr ""
+
+msgid "no files to copy"
+msgstr ""
+
+msgid "(consider using --after)\n"
+msgstr ""
+
+msgid "child process failed to start"
+msgstr ""
+
+#, python-format
+msgid "changeset:   %d:%s\n"
+msgstr ""
+
+#, python-format
+msgid "branch:      %s\n"
+msgstr ""
+
+#, python-format
+msgid "tag:         %s\n"
+msgstr ""
+
+#, python-format
+msgid "parent:      %d:%s\n"
+msgstr ""
+
+#, python-format
+msgid "manifest:    %d:%s\n"
+msgstr ""
+
+#, python-format
+msgid "user:        %s\n"
+msgstr ""
+
+#, python-format
+msgid "date:        %s\n"
+msgstr ""
+
+msgid "files+:"
+msgstr ""
+
+msgid "files-:"
+msgstr ""
+
+msgid "files:"
+msgstr ""
+
+#, python-format
+msgid "files:       %s\n"
+msgstr ""
+
+#, python-format
+msgid "copies:      %s\n"
+msgstr ""
+
+#, python-format
+msgid "extra:       %s=%s\n"
+msgstr ""
+
+msgid "description:\n"
+msgstr ""
+
+#, python-format
+msgid "summary:     %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s: no key named '%s'"
+msgstr ""
+
+#, python-format
+msgid "Found revision %s from %s\n"
+msgstr ""
+
+msgid "revision matching date not found"
+msgstr ""
+
+#, python-format
+msgid "cannot follow nonexistent file: \"%s\""
+msgstr ""
+
+msgid "can only follow copies/renames for explicit filenames"
+msgstr ""
+
+msgid "HG: Enter commit message.  Lines beginning with 'HG:' are removed."
+msgstr ""
+
+msgid "HG: Leave message empty to abort commit."
+msgstr ""
+
+#, python-format
+msgid "HG: user: %s"
+msgstr ""
+
+msgid "HG: branch merge"
+msgstr ""
+
+#, python-format
+msgid "HG: branch '%s'"
+msgstr ""
+
+#, python-format
+msgid "HG: subrepo %s"
+msgstr ""
+
+#, python-format
+msgid "HG: added %s"
+msgstr ""
+
+#, python-format
+msgid "HG: changed %s"
+msgstr ""
+
+#, python-format
+msgid "HG: removed %s"
+msgstr ""
+
+msgid "HG: no files changed"
+msgstr ""
+
+msgid "empty commit message"
+msgstr ""
+
+msgid "add the specified files on the next commit"
+msgstr "adaugă fișierele specificate la următoarea depozitare ('commit')"
+
+msgid ""
+"    Schedule files to be version controlled and added to the\n"
+"    repository."
+msgstr ""
+"    Planifică fișierele pentru a fi luate în evidența sistemului de\n"
+"    control al versiunilor și adăugate în depozit."
+
+msgid ""
+"    The files will be added to the repository at the next commit. To\n"
+"    undo an add before that, see :hg:`forget`."
+msgstr ""
+"   Fișierele vor fi adăugate în depozit la următoarea depozitare "
+"('commit').\n"
+"   Pentru a anula acțiunea înainte de efectuare, folosiți :hg:`forget`."
+
+msgid "    If no names are given, add all files to the repository."
+msgstr ""
+"    Dacă nu se specifică niciun nume, vor fi adăugate în depozit toate "
+"fișierele."
+
+msgid "    .. container:: verbose"
+msgstr ""
+
+msgid ""
+"       An example showing how new (unknown) files are added\n"
+"       automatically by :hg:`add`::"
+msgstr ""
+
+msgid ""
+"         $ ls\n"
+"         foo.c\n"
+"         $ hg status\n"
+"         ? foo.c\n"
+"         $ hg add\n"
+"         adding foo.c\n"
+"         $ hg status\n"
+"         A foo.c"
+msgstr ""
+
+msgid ""
+"    Returns 0 if all files are successfully added.\n"
+"    "
+msgstr ""
+
+msgid "add all new files, delete all missing files"
+msgstr ""
+
+msgid ""
+"    Add all new files and remove all missing files from the\n"
+"    repository."
+msgstr ""
+
+msgid ""
+"    New files are ignored if they match any of the patterns in\n"
+"    .hgignore. As with add, these changes take effect at the next\n"
+"    commit."
+msgstr ""
+
+msgid ""
+"    Use the -s/--similarity option to detect renamed files. With a\n"
+"    parameter greater than 0, this compares every removed file with\n"
+"    every added file and records those similar enough as renames. This\n"
+"    option takes a percentage between 0 (disabled) and 100 (files must\n"
+"    be identical) as its parameter. Detecting renamed files this way\n"
+"    can be expensive. After using this option, :hg:`status -C` can be\n"
+"    used to check which files were identified as moved or renamed."
+msgstr ""
+
+msgid "similarity must be a number"
+msgstr ""
+
+msgid "similarity must be between 0 and 100"
+msgstr ""
+
+msgid "show changeset information by line for each file"
+msgstr ""
+
+msgid ""
+"    List changes in files, showing the revision id responsible for\n"
+"    each line"
+msgstr ""
+
+msgid ""
+"    This command is useful for discovering when a change was made and\n"
+"    by whom."
+msgstr ""
+
+msgid ""
+"    Without the -a/--text option, annotate will avoid processing files\n"
+"    it detects as binary. With -a, annotate will annotate the file\n"
+"    anyway, although the results will probably be neither useful\n"
+"    nor desirable."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success.\n"
+"    "
+msgstr ""
+
+msgid "at least one filename or pattern is required"
+msgstr ""
+
+msgid "at least one of -n/-c is required for -l"
+msgstr ""
+
+#, python-format
+msgid "%s: binary file\n"
+msgstr ""
+
+msgid "create an unversioned archive of a repository revision"
+msgstr ""
+
+msgid ""
+"    By default, the revision used is the parent of the working\n"
+"    directory; use -r/--rev to specify a different revision."
+msgstr ""
+
+msgid ""
+"    The archive type is automatically detected based on file\n"
+"    extension (or override using -t/--type)."
+msgstr ""
+
+msgid "    Valid types are:"
+msgstr ""
+
+msgid ""
+"    :``files``: a directory full of files (default)\n"
+"    :``tar``:   tar archive, uncompressed\n"
+"    :``tbz2``:  tar archive, compressed using bzip2\n"
+"    :``tgz``:   tar archive, compressed using gzip\n"
+"    :``uzip``:  zip archive, uncompressed\n"
+"    :``zip``:   zip archive, compressed using deflate"
+msgstr ""
+
+msgid ""
+"    The exact name of the destination archive or directory is given\n"
+"    using a format string; see :hg:`help export` for details."
+msgstr ""
+
+msgid ""
+"    Each member added to an archive file has a directory prefix\n"
+"    prepended. Use -p/--prefix to specify a format string for the\n"
+"    prefix. The default is the basename of the archive, with suffixes\n"
+"    removed."
+msgstr ""
+
+msgid "no working directory: please specify a revision"
+msgstr ""
+
+msgid "repository root cannot be destination"
+msgstr ""
+
+msgid "cannot archive plain files to stdout"
+msgstr ""
+
+msgid "reverse effect of earlier changeset"
+msgstr ""
+
+msgid ""
+"    Commit the backed out changes as a new changeset. The new\n"
+"    changeset is a child of the backed out changeset."
+msgstr ""
+
+msgid ""
+"    If you backout a changeset other than the tip, a new head is\n"
+"    created. This head will be the new tip and you should merge this\n"
+"    backout changeset with another head."
+msgstr ""
+
+msgid ""
+"    The --merge option remembers the parent of the working directory\n"
+"    before starting the backout, then merges the new head with that\n"
+"    changeset afterwards. This saves you from doing the merge by hand.\n"
+"    The result of this merge is not committed, as with a normal merge."
+msgstr ""
+
+msgid "please specify just one revision"
+msgstr ""
+
+msgid "please specify a revision to backout"
+msgstr ""
+
+msgid "cannot backout change on a different branch"
+msgstr ""
+
+msgid "cannot backout a change with no parents"
+msgstr ""
+
+msgid "cannot backout a merge changeset without --parent"
+msgstr ""
+
+#, python-format
+msgid "%s is not a parent of %s"
+msgstr ""
+
+msgid "cannot use --parent on non-merge changeset"
+msgstr ""
+
+#, python-format
+msgid "changeset %s backs out changeset %s\n"
+msgstr ""
+
+#, python-format
+msgid "merging with changeset %s\n"
+msgstr ""
+
+msgid "the backout changeset is a new head - do not forget to merge\n"
+msgstr ""
+
+msgid "(use \"backout --merge\" if you want to auto-merge)\n"
+msgstr ""
+
+msgid "subdivision search of changesets"
+msgstr ""
+
+msgid ""
+"    This command helps to find changesets which introduce problems. To\n"
+"    use, mark the earliest changeset you know exhibits the problem as\n"
+"    bad, then mark the latest changeset which is free from the problem\n"
+"    as good. Bisect will update your working directory to a revision\n"
+"    for testing (unless the -U/--noupdate option is specified). Once\n"
+"    you have performed tests, mark the working directory as good or\n"
+"    bad, and bisect will either update to another candidate changeset\n"
+"    or announce that it has found the bad revision."
+msgstr ""
+
+msgid ""
+"    As a shortcut, you can also use the revision argument to mark a\n"
+"    revision as good or bad without checking it out first."
+msgstr ""
+"   Ca scurtătură, puteți folosi argumentul reviziei pentru a marca o    "
+"revizie ca bună sau rea, fără a o actualiza în prealabil."
+
+msgid ""
+"    If you supply a command, it will be used for automatic bisection.\n"
+"    Its exit status will be used to mark revisions as good or bad:\n"
+"    status 0 means good, 125 means to skip the revision, 127\n"
+"    (command not found) will abort the bisection, and any other\n"
+"    non-zero exit status means the revision is bad."
+msgstr ""
+
+msgid "The first good revision is:\n"
+msgstr ""
+
+msgid "The first bad revision is:\n"
+msgstr ""
+
+msgid "Due to skipped revisions, the first good revision could be any of:\n"
+msgstr ""
+
+msgid "Due to skipped revisions, the first bad revision could be any of:\n"
+msgstr ""
+
+msgid "cannot bisect (no known good revisions)"
+msgstr ""
+
+msgid "cannot bisect (no known bad revisions)"
+msgstr ""
+
+msgid "(use of 'hg bisect <cmd>' is deprecated)\n"
+msgstr ""
+
+msgid "incompatible arguments"
+msgstr ""
+
+#, python-format
+msgid "failed to execute %s"
+msgstr ""
+
+#, python-format
+msgid "%s killed"
+msgstr ""
+
+#, python-format
+msgid "Changeset %d:%s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "Testing changeset %d:%s (%d changesets remaining, ~%d tests)\n"
+msgstr ""
+
+msgid "set or show the current branch name"
+msgstr ""
+
+msgid ""
+"    With no argument, show the current branch name. With one argument,\n"
+"    set the working directory branch name (the branch will not exist\n"
+"    in the repository until the next commit). Standard practice\n"
+"    recommends that primary development take place on the 'default'\n"
+"    branch."
+msgstr ""
+
+msgid ""
+"    Unless -f/--force is specified, branch will not let you set a\n"
+"    branch name that already exists, even if it's inactive."
+msgstr ""
+
+msgid ""
+"    Use -C/--clean to reset the working directory branch to that of\n"
+"    the parent of the working directory, negating a previous branch\n"
+"    change."
+msgstr ""
+
+msgid ""
+"    Use the command :hg:`update` to switch to an existing branch. Use\n"
+"    :hg:`commit --close-branch` to mark this branch as closed."
+msgstr ""
+
+#, python-format
+msgid "reset working directory to branch %s\n"
+msgstr ""
+
+msgid ""
+"a branch of the same name already exists (use 'hg update' to switch to it)"
+msgstr ""
+
+#, python-format
+msgid "marked working directory as branch %s\n"
+msgstr ""
+
+msgid "list repository named branches"
+msgstr ""
+
+msgid ""
+"    List the repository's named branches, indicating which ones are\n"
+"    inactive. If -c/--closed is specified, also list branches which have\n"
+"    been marked closed (see :hg:`commit --close-branch`)."
+msgstr ""
+
+msgid ""
+"    If -a/--active is specified, only show active branches. A branch\n"
+"    is considered active if it contains repository heads."
+msgstr ""
+
+msgid "    Use the command :hg:`update` to switch to an existing branch."
+msgstr ""
+
+msgid ""
+"    Returns 0.\n"
+"    "
+msgstr ""
+
+msgid " (closed)"
+msgstr ""
+
+msgid " (inactive)"
+msgstr ""
+
+msgid "create a changegroup file"
+msgstr ""
+
+msgid ""
+"    Generate a compressed changegroup file collecting changesets not\n"
+"    known to be in another repository."
+msgstr ""
+
+msgid ""
+"    If you omit the destination repository, then hg assumes the\n"
+"    destination will have all the nodes you specify with --base\n"
+"    parameters. To create a bundle containing all changesets, use\n"
+"    -a/--all (or --base null)."
+msgstr ""
+
+msgid ""
+"    You can change compression method with the -t/--type option.\n"
+"    The available compression methods are: none, bzip2, and\n"
+"    gzip (by default, bundles are compressed using bzip2)."
+msgstr ""
+
+msgid ""
+"    The bundle file can then be transferred using conventional means\n"
+"    and applied to another repository with the unbundle or pull\n"
+"    command. This is useful when direct push and pull are not\n"
+"    available or when exporting an entire repository is undesirable."
+msgstr ""
+
+msgid ""
+"    Applying bundles preserves all changeset contents including\n"
+"    permissions, copy/rename information, and revision history."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success, 1 if no changes found.\n"
+"    "
+msgstr ""
+
+msgid "--base is incompatible with specifying a destination"
+msgstr ""
+
+msgid "unknown bundle type specified with --type"
+msgstr ""
+
+msgid "output the current or given revision of files"
+msgstr ""
+
+msgid ""
+"    Print the specified files as they were at the given revision. If\n"
+"    no revision is given, the parent of the working directory is used,\n"
+"    or tip if no revision is checked out."
+msgstr ""
+
+msgid ""
+"    Output may be to a file, in which case the name of the file is\n"
+"    given using a format string. The formatting rules are the same as\n"
+"    for the export command, with the following additions:"
+msgstr ""
+
+msgid ""
+"    :``%s``: basename of file being printed\n"
+"    :``%d``: dirname of file being printed, or '.' if in repository root\n"
+"    :``%p``: root-relative path name of file being printed"
+msgstr ""
+
+msgid "make a copy of an existing repository"
+msgstr "realizează o copie a unui depozit existent"
+
+msgid "    Create a copy of an existing repository in a new directory."
+msgstr "    Creează o copie a unui depozit existent, într-un director nou."
+
+msgid ""
+"    If no destination directory name is specified, it defaults to the\n"
+"    basename of the source."
+msgstr ""
+"    Dacă nu se specifică numele directorului destinație, acesta va fi\n"
+"    implicit numele de bază (basename) al sursei."
+
+msgid ""
+"    The location of the source is added to the new repository's\n"
+"    .hg/hgrc file, as the default to be used for future pulls."
+msgstr ""
+"    Amplasarea sursei este adăugată în fișierul .hg/hgrc al noului\n"
+"    depozit, ca amplasarea implicită pentru viitoarele comenzi 'pull'."
+
+msgid "    See :hg:`help urls` for valid source format details."
+msgstr ""
+
+msgid ""
+"    It is possible to specify an ``ssh://`` URL as the destination, but no\n"
+"    .hg/hgrc and working directory will be created on the remote side.\n"
+"    Please see :hg:`help urls` for important details about ``ssh://`` URLs."
+msgstr ""
+"    Ca destinație se poate specifica un URL ``ssh://``, dar nu va fi creat.\n"
+"    niciun fișier .hg/hgrc pe mașina de la distanță.\n"
+"    Vezi :hg:`help urls` pentru detalii importante despre URL-urile ``ssh://"
+"``."
+
+msgid ""
+"    A set of changesets (tags, or branch names) to pull may be specified\n"
+"    by listing each changeset (tag, or branch name) with -r/--rev.\n"
+"    If -r/--rev is used, the cloned repository will contain only a subset\n"
+"    of the changesets of the source repository. Only the set of changesets\n"
+"    defined by all -r/--rev options (including all their ancestors)\n"
+"    will be pulled into the destination repository.\n"
+"    No subsequent changesets (including subsequent tags) will be present\n"
+"    in the destination."
+msgstr ""
+"    O colecție de seturi de modificări (etichete sau nume de ramuri) care\n"
+"    urmează a fi recuperate poate fi specificată prin listarea fiecărui set\n"
+"    de modificări (etichete sau nume de ramuri) cu -r/--rev.\n"
+"    Dacă se folosește -r/--rev, depozitul clonat va conține numai un subset\n"
+"    al seturilor de modificări ale depozitului sursă. Numai colecția de "
+"seturi\n"
+"    de modificări definite de toate opțiunile -r/--rev (inclusiv toți "
+"precedenții)\n"
+"    vor fi aduse (pulled) in depozitul destinație.\n"
+"    Nici un set de modificări ulterior (inclusiv etichete ulterioare) nu se "
+"va     regăsi în destinație."
+
+msgid ""
+"    Using -r/--rev (or 'clone src#rev dest') implies --pull, even for\n"
+"    local source repositories."
+msgstr ""
+"    Folosirea -r/--rev (sau 'clone src#rev dest') implică --pull, chiar\n"
+"    și pentru depozite sursă locale."
+
+msgid ""
+"    For efficiency, hardlinks are used for cloning whenever the source\n"
+"    and destination are on the same filesystem (note this applies only\n"
+"    to the repository data, not to the working directory). Some\n"
+"    filesystems, such as AFS, implement hardlinking incorrectly, but\n"
+"    do not report errors. In these cases, use the --pull option to\n"
+"    avoid hardlinking."
+msgstr ""
+"    Pentru eficiență, se folosesc link-uri hard ori de câte ori sursa și\n"
+"    destinația se află pe același sistem de fișiere (remarcați ca aceasta\n"
+"    este valabil doar pentru datele din depozit, nu și pentru directorul\n"
+"    de lucru). Unele sisteme de fișiere, precum AFS, implementează\n"
+"    link-urile hard în mod incorect, dar nu raportează erori. În aceste\n"
+"    cazuri, folosiți opțiunea --pull pentru a evita link-urile hard."
+
+msgid ""
+"    In some cases, you can clone repositories and the working directory\n"
+"    using full hardlinks with ::"
+msgstr ""
+"    În unele cazuri, puteți clona depozitele și directorul de lucru "
+"utilizând\n"
+"    link-uri hard complete cu:"
+
+msgid "      $ cp -al REPO REPOCLONE"
+msgstr "      $ cp -al DEP CLONA_DEP"
+
+msgid ""
+"    This is the fastest way to clone, but it is not always safe. The\n"
+"    operation is not atomic (making sure REPO is not modified during\n"
+"    the operation is up to you) and you have to make sure your editor\n"
+"    breaks hardlinks (Emacs and most Linux Kernel tools do so). Also,\n"
+"    this is not compatible with certain extensions that place their\n"
+"    metadata under the .hg directory, such as mq."
+msgstr ""
+"    Acesta este cel mai rapid mod de a clona, dar nu este întotdeauna\n"
+"    sigur. Operația nu este atomică (rămâne în sarcina dvs. să vă asigurați\n"
+"    că DEP nu este modificat în timpul operației) și trebuie să vă "
+"asigurați\n"
+"    că editorul dvs. desface link-urile hard (Emacs si cele mai multe "
+"unelte\n"
+"    din kernelul Linux vor face aceasta). De asemenea, acest mod nu este\n"
+"    compatibil cu anumite extensii care își plasează metadatele în "
+"directorul\n"
+"    .hg, precum mq."
+
+msgid ""
+"    Mercurial will update the working directory to the first applicable\n"
+"    revision from this list:"
+msgstr ""
+
+msgid ""
+"    a) null if -U or the source repository has no changesets\n"
+"    b) if -u . and the source repository is local, the first parent of\n"
+"       the source repository's working directory\n"
+"    c) the changeset specified with -u (if a branch name, this means the\n"
+"       latest head of that branch)\n"
+"    d) the changeset specified with -r\n"
+"    e) the tipmost head specified with -b\n"
+"    f) the tipmost head specified with the url#branch source syntax\n"
+"    g) the tipmost head of the default branch\n"
+"    h) tip"
+msgstr ""
+
+msgid "cannot specify both --noupdate and --updaterev"
+msgstr ""
+
+msgid "commit the specified files or all outstanding changes"
+msgstr "depozitează fișierele specificate sau toate modificările în suspensie"
+
+msgid ""
+"    Commit changes to the given files into the repository. Unlike a\n"
+"    centralized RCS, this operation is a local operation. See\n"
+"    :hg:`push` for a way to actively distribute your changes."
+msgstr ""
+"    Depozitează modificările fișierelor date în depozit. Spre deosebire\n"
+"    de un sistem de control al versiunilor centralizat, această operație\n"
+"    este locală. Vezi :hg:`push` pentru o cale de a vă distribui în mod\n"
+"    activ modificările."
+
+msgid ""
+"    If a list of files is omitted, all changes reported by :hg:`status`\n"
+"    will be committed."
+msgstr ""
+"    Dacă se omite lista de fișiere, vor fi depozitate toate modificările\n"
+"    raportate de :hg:`status`."
+
+msgid ""
+"    If you are committing the result of a merge, do not provide any\n"
+"    filenames or -I/-X filters."
+msgstr ""
+"    Dacă depozitați rezultatul unei fuziuni, nu furnizați niciun nume de\n"
+"    fișier sau filtrele -I/-X."
+
+msgid ""
+"    If no commit message is specified, the configured editor is\n"
+"    started to prompt you for a message."
+msgstr ""
+"    Dacă nu specificați nici un mesaj pentru depozitare, se va\n"
+"    lansa editorul menționat în configurație pentru a scrie un mesaj."
+
+msgid ""
+"    Returns 0 on success, 1 if nothing changed.\n"
+"    "
+msgstr ""
+
+msgid "can only close branch heads"
+msgstr ""
+
+msgid "nothing changed\n"
+msgstr ""
+
+msgid "created new head\n"
+msgstr ""
+
+#, python-format
+msgid "reopening closed branch head %d\n"
+msgstr ""
+
+#, python-format
+msgid "committed changeset %d:%s\n"
+msgstr ""
+
+msgid "mark files as copied for the next commit"
+msgstr ""
+
+msgid ""
+"    Mark dest as having copies of source files. If dest is a\n"
+"    directory, copies are put in that directory. If dest is a file,\n"
+"    the source must be a single file."
+msgstr ""
+
+msgid ""
+"    By default, this command copies the contents of files as they\n"
+"    exist in the working directory. If invoked with -A/--after, the\n"
+"    operation is recorded, but no copying is performed."
+msgstr ""
+
+msgid ""
+"    This command takes effect with the next commit. To undo a copy\n"
+"    before that, see :hg:`revert`."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success, 1 if errors are encountered.\n"
+"    "
+msgstr ""
+
+msgid "find the ancestor revision of two revisions in a given index"
+msgstr ""
+
+msgid "either two or three arguments required"
+msgstr ""
+
+msgid "builds a repo with a given dag from scratch in the current empty repo"
+msgstr ""
+
+msgid "    Elements:"
+msgstr ""
+
+msgid ""
+"     - \"+n\" is a linear run of n nodes based on the current default "
+"parent\n"
+"     - \".\" is a single node based on the current default parent\n"
+"     - \"$\" resets the default parent to null (implied at the start);\n"
+"           otherwise the default parent is always the last node created\n"
+"     - \"<p\" sets the default parent to the backref p\n"
+"     - \"*p\" is a fork at parent p, which is a backref\n"
+"     - \"*p1/p2\" is a merge of parents p1 and p2, which are backrefs\n"
+"     - \"/p2\" is a merge of the preceding node and p2\n"
+"     - \":tag\" defines a local tag for the preceding node\n"
+"     - \"@branch\" sets the named branch for subsequent nodes\n"
+"     - \"!command\" runs the command using your shell\n"
+"     - \"!!my command\\n\" is like \"!\", but to the end of the line\n"
+"     - \"#...\\n\" is a comment up to the end of the line"
+msgstr ""
+
+msgid "    Whitespace between the above elements is ignored."
+msgstr ""
+
+msgid "    A backref is either"
+msgstr ""
+
+msgid ""
+"     - a number n, which references the node curr-n, where curr is the "
+"current\n"
+"       node, or\n"
+"     - the name of a local tag you placed earlier using \":tag\", or\n"
+"     - empty to denote the default parent."
+msgstr ""
+
+msgid ""
+"    All string valued-elements are either strictly alphanumeric, or must\n"
+"    be enclosed in double quotes (\"...\"), with \"\" as escape character."
+msgstr ""
+
+msgid ""
+"    Note that the --overwritten-file and --appended-file options imply the\n"
+"    use of \"HGMERGE=internal:local\" during DAG buildup.\n"
+"    "
+msgstr ""
+
+msgid "need at least one of -m, -a, -o, -n"
+msgstr ""
+
+msgid "repository is not empty"
+msgstr ""
+
+#, python-format
+msgid "%s command %s"
+msgstr ""
+
+msgid "list all available commands and options"
+msgstr ""
+
+msgid "returns the completion list associated with the given command"
+msgstr ""
+
+msgid "show information detected about current filesystem"
+msgstr ""
+
+msgid "rebuild the dirstate as it would look like for the given revision"
+msgstr ""
+
+msgid "validate the correctness of the current dirstate"
+msgstr ""
+
+#, python-format
+msgid "%s in state %s, but not in manifest1\n"
+msgstr ""
+
+#, python-format
+msgid "%s in state %s, but also in manifest1\n"
+msgstr ""
+
+#, python-format
+msgid "%s in state %s, but not in either manifest\n"
+msgstr ""
+
+#, python-format
+msgid "%s in manifest1, but listed as state %s"
+msgstr ""
+
+msgid ".hg/dirstate inconsistent with current parent's manifest"
+msgstr ""
+
+msgid "show combined config settings from all hgrc files"
+msgstr ""
+
+msgid "    With no arguments, print names and values of all config items."
+msgstr ""
+
+msgid ""
+"    With one argument of the form section.name, print just the value\n"
+"    of that config item."
+msgstr ""
+
+msgid ""
+"    With multiple arguments, print names and values of all config\n"
+"    items with matching section names."
+msgstr ""
+
+msgid ""
+"    With --debug, the source (filename and line number) is printed\n"
+"    for each config item."
+msgstr ""
+
+#, python-format
+msgid "read config from: %s\n"
+msgstr ""
+
+msgid "only one config item permitted"
+msgstr ""
+
+msgid "access the pushkey key/value protocol"
+msgstr ""
+
+msgid "    With two args, list the keys in the given namespace."
+msgstr ""
+
+msgid ""
+"    With five args, set a key to new if it currently is set to old.\n"
+"    Reports success or failure.\n"
+"    "
+msgstr ""
+
+msgid "parse and apply a revision specification"
+msgstr ""
+
+msgid "manually set the parents of the current working directory"
+msgstr ""
+
+msgid ""
+"    This is useful for writing repository conversion tools, but should\n"
+"    be used with care."
+msgstr ""
+
+msgid "show the contents of the current dirstate"
+msgstr ""
+
+#, python-format
+msgid "copy: %s -> %s\n"
+msgstr ""
+
+msgid "format the changelog or an index DAG as a concise textual description"
+msgstr ""
+
+msgid ""
+"    If you pass a revlog index, the revlog's DAG is emitted. If you list\n"
+"    revision numbers, they get labelled in the output as rN."
+msgstr ""
+
+msgid ""
+"    Otherwise, the changelog DAG of the current repo is emitted.\n"
+"    "
+msgstr ""
+
+msgid "need repo for changelog dag"
+msgstr ""
+
+msgid "dump the contents of a data file revision"
+msgstr ""
+
+#, python-format
+msgid "invalid revision identifier %s"
+msgstr ""
+
+msgid "parse and display a date"
+msgstr ""
+
+msgid "dump the contents of an index file"
+msgstr ""
+
+msgid "dump an index DAG as a graphviz dot file"
+msgstr ""
+
+msgid "test Mercurial installation"
+msgstr ""
+
+#, python-format
+msgid "Checking encoding (%s)...\n"
+msgstr "Se verifică codificarea (%s)...\n"
+
+msgid " (check that your locale is properly set)\n"
+msgstr ""
+
+msgid "Checking extensions...\n"
+msgstr "Se verifică extensiile...\n"
+
+msgid " One or more extensions could not be found"
+msgstr ""
+
+msgid " (check that you compiled the extensions)\n"
+msgstr ""
+
+msgid "Checking templates...\n"
+msgstr "Se verifică șabloanele...\n"
+
+msgid " (templates seem to have been installed incorrectly)\n"
+msgstr ""
+
+msgid "Checking patch...\n"
+msgstr "Se verifică patch-ul\n"
+
+msgid " patch call failed:\n"
+msgstr ""
+
+msgid " unexpected patch output!\n"
+msgstr ""
+
+msgid " patch test failed!\n"
+msgstr ""
+
+msgid ""
+" (Current patch tool may be incompatible with patch, or misconfigured. "
+"Please check your .hgrc file)\n"
+msgstr ""
+
+msgid ""
+" Internal patcher failure, please report this error to http://mercurial."
+"selenic.com/bts/\n"
+msgstr ""
+
+msgid "Checking commit editor...\n"
+msgstr "Se verifică editorul pentru commit...\n"
+
+msgid " No commit editor set and can't find vi in PATH\n"
+msgstr ""
+
+msgid " (specify a commit editor in your .hgrc file)\n"
+msgstr ""
+
+#, python-format
+msgid " Can't find editor '%s' in PATH\n"
+msgstr ""
+
+msgid "Checking username...\n"
+msgstr "Se verifică numele de utilizator...\n"
+
+msgid " (specify a username in your .hgrc file)\n"
+msgstr ""
+
+msgid "No problems detected\n"
+msgstr ""
+
+#, python-format
+msgid "%s problems detected, please check your install!\n"
+msgstr ""
+
+msgid "dump rename information"
+msgstr ""
+
+#, python-format
+msgid "%s renamed from %s:%s\n"
+msgstr ""
+
+#, python-format
+msgid "%s not renamed\n"
+msgstr ""
+
+msgid "show how files match on given patterns"
+msgstr ""
+
+msgid "diff repository (or selected files)"
+msgstr ""
+
+msgid "    Show differences between revisions for the specified files."
+msgstr ""
+
+msgid "    Differences between files are shown using the unified diff format."
+msgstr ""
+
+msgid ""
+"    NOTE: diff may generate unexpected results for merges, as it will\n"
+"    default to comparing against the working directory's first parent\n"
+"    changeset if no revisions are specified."
+msgstr ""
+
+msgid ""
+"    Alternatively you can specify -c/--change with a revision to see\n"
+"    the changes in that changeset relative to its first parent."
+msgstr ""
+
+msgid ""
+"    Without the -a/--text option, diff will avoid generating diffs of\n"
+"    files it detects as binary. With -a, diff will generate a diff\n"
+"    anyway, probably with undesirable results."
+msgstr ""
+
+msgid ""
+"    Use the -g/--git option to generate diffs in the git extended diff\n"
+"    format. For more information, read :hg:`help diffs`."
+msgstr ""
+
+msgid "dump the header and diffs for one or more changesets"
+msgstr ""
+
+msgid "    Print the changeset header and diffs for one or more revisions."
+msgstr ""
+
+msgid ""
+"    The information shown in the changeset header is: author, date,\n"
+"    branch name (if non-default), changeset hash, parent(s) and commit\n"
+"    comment."
+msgstr ""
+
+msgid ""
+"    NOTE: export may generate unexpected diff output for merge\n"
+"    changesets, as it will compare the merge changeset against its\n"
+"    first parent only."
+msgstr ""
+
+msgid ""
+"    Output may be to a file, in which case the name of the file is\n"
+"    given using a format string. The formatting rules are as follows:"
+msgstr ""
+
+msgid ""
+"    :``%%``: literal \"%\" character\n"
+"    :``%H``: changeset hash (40 hexadecimal digits)\n"
+"    :``%N``: number of patches being generated\n"
+"    :``%R``: changeset revision number\n"
+"    :``%b``: basename of the exporting repository\n"
+"    :``%h``: short-form changeset hash (12 hexadecimal digits)\n"
+"    :``%n``: zero-padded sequence number, starting at 1\n"
+"    :``%r``: zero-padded changeset revision number"
+msgstr ""
+
+msgid ""
+"    Without the -a/--text option, export will avoid generating diffs\n"
+"    of files it detects as binary. With -a, export will generate a\n"
+"    diff anyway, probably with undesirable results."
+msgstr ""
+
+msgid ""
+"    Use the -g/--git option to generate diffs in the git extended diff\n"
+"    format. See :hg:`help diffs` for more information."
+msgstr ""
+
+msgid ""
+"    With the --switch-parent option, the diff will be against the\n"
+"    second parent. It can be useful to review a merge."
+msgstr ""
+
+msgid "export requires at least one changeset"
+msgstr ""
+
+msgid "exporting patches:\n"
+msgstr ""
+
+msgid "exporting patch:\n"
+msgstr ""
+
+msgid "forget the specified files on the next commit"
+msgstr ""
+
+msgid ""
+"    Mark the specified files so they will no longer be tracked\n"
+"    after the next commit."
+msgstr ""
+
+msgid ""
+"    This only removes files from the current branch, not from the\n"
+"    entire project history, and it does not delete them from the\n"
+"    working directory."
+msgstr ""
+
+msgid "    To undo a forget before the next commit, see :hg:`add`."
+msgstr ""
+
+msgid "no files specified"
+msgstr ""
+
+#, python-format
+msgid "not removing %s: file is already untracked\n"
+msgstr ""
+
+msgid "search for a pattern in specified files and revisions"
+msgstr ""
+
+msgid "    Search revisions of files for a regular expression."
+msgstr ""
+
+msgid ""
+"    This command behaves differently than Unix grep. It only accepts\n"
+"    Python/Perl regexps. It searches repository history, not the\n"
+"    working directory. It always prints the revision number in which a\n"
+"    match appears."
+msgstr ""
+
+msgid ""
+"    By default, grep only prints output for the first revision of a\n"
+"    file in which it finds a match. To get it to print every revision\n"
+"    that contains a change in match status (\"-\" for a match that\n"
+"    becomes a non-match, or \"+\" for a non-match that becomes a match),\n"
+"    use the --all flag."
+msgstr ""
+
+msgid ""
+"    Returns 0 if a match is found, 1 otherwise.\n"
+"    "
+msgstr ""
+
+#, python-format
+msgid "grep: invalid match pattern: %s\n"
+msgstr ""
+
+msgid "show current repository heads or show branch heads"
+msgstr ""
+
+msgid "    With no arguments, show all repository branch heads."
+msgstr ""
+
+msgid ""
+"    Repository \"heads\" are changesets with no child changesets. They are\n"
+"    where development generally takes place and are the usual targets\n"
+"    for update and merge operations. Branch heads are changesets that have\n"
+"    no child changeset on the same branch."
+msgstr ""
+
+msgid ""
+"    If one or more REVs are given, only branch heads on the branches\n"
+"    associated with the specified changesets are shown."
+msgstr ""
+
+msgid ""
+"    If -c/--closed is specified, also show branch heads marked closed\n"
+"    (see :hg:`commit --close-branch`)."
+msgstr ""
+
+msgid ""
+"    If STARTREV is specified, only those heads that are descendants of\n"
+"    STARTREV will be displayed."
+msgstr ""
+
+msgid ""
+"    If -t/--topo is specified, named branch mechanics will be ignored and "
+"only\n"
+"    changesets without children will be shown."
+msgstr ""
+
+msgid ""
+"    Returns 0 if matching heads are found, 1 if not.\n"
+"    "
+msgstr ""
+
+#, python-format
+msgid "no open branch heads found on branches %s"
+msgstr ""
+
+#, python-format
+msgid " (started at %s)"
+msgstr ""
+
+msgid "show help for a given topic or a help overview"
+msgstr ""
+
+msgid ""
+"    With no arguments, print a list of commands with short help messages."
+msgstr ""
+
+msgid ""
+"    Given a topic, extension, or command name, print help for that\n"
+"    topic."
+msgstr ""
+
+msgid ""
+"    Returns 0 if successful.\n"
+"    "
+msgstr ""
+
+msgid "global options:"
+msgstr "opțiuni globale:"
+
+msgid "use \"hg help\" for the full list of commands"
+msgstr ""
+
+msgid "use \"hg help\" for the full list of commands or \"hg -v\" for details"
+msgstr ""
+
+#, python-format
+msgid "use \"hg -v help%s\" to show aliases and global options"
+msgstr ""
+
+#, python-format
+msgid "use \"hg -v help %s\" to show global options"
+msgstr "folosiți \"hg -v help %s\" pentru a vedea opțiunile globale"
+
+msgid "list of commands:"
+msgstr ""
+
+#, python-format
+msgid ""
+"\n"
+"aliases: %s\n"
+msgstr ""
+"\n"
+"alias: %s\n"
+
+msgid "(no help text available)"
+msgstr ""
+
+#, python-format
+msgid "shell alias for::"
+msgstr "alias de shell pentru:"
+
+#, python-format
+msgid "    %s"
+msgstr ""
+
+#, python-format
+msgid "alias for: hg %s"
+msgstr "alias pentru: hg %s"
+
+#, python-format
+msgid "%s"
+msgstr ""
+
+#, python-format
+msgid ""
+"\n"
+"use \"hg -v help %s\" to show verbose help\n"
+msgstr ""
+
+msgid "options:\n"
+msgstr "opțiuni:\n"
+
+msgid "no commands defined\n"
+msgstr ""
+
+msgid "no help text available"
+msgstr ""
+
+#, python-format
+msgid "%s extension - %s"
+msgstr ""
+
+msgid "use \"hg help extensions\" for information on enabling extensions\n"
+msgstr ""
+
+#, python-format
+msgid "'%s' is provided by the following extension:"
+msgstr ""
+
+msgid "Mercurial Distributed SCM\n"
+msgstr ""
+
+msgid "basic commands:"
+msgstr ""
+
+msgid "enabled extensions:"
+msgstr ""
+
+msgid "VALUE"
+msgstr ""
+
+msgid "DEPRECATED"
+msgstr ""
+
+msgid ""
+"\n"
+"[+] marked option can be specified multiple times"
+msgstr ""
+
+msgid ""
+"\n"
+"additional help topics:"
+msgstr ""
+
+msgid "identify the working copy or specified revision"
+msgstr ""
+
+msgid ""
+"    With no revision, print a summary of the current state of the\n"
+"    repository."
+msgstr ""
+
+msgid ""
+"    Specifying a path to a repository root or Mercurial bundle will\n"
+"    cause lookup to operate on that repository/bundle."
+msgstr ""
+
+msgid ""
+"    This summary identifies the repository state using one or two\n"
+"    parent hash identifiers, followed by a \"+\" if there are\n"
+"    uncommitted changes in the working directory, a list of tags for\n"
+"    this revision and a branch name for non-default branches."
+msgstr ""
+
+msgid "import an ordered set of patches"
+msgstr ""
+
+msgid ""
+"    Import a list of patches and commit them individually (unless\n"
+"    --no-commit is specified)."
+msgstr ""
+
+msgid ""
+"    If there are outstanding changes in the working directory, import\n"
+"    will abort unless given the -f/--force flag."
+msgstr ""
+
+msgid ""
+"    You can import a patch straight from a mail message. Even patches\n"
+"    as attachments work (to use the body part, it must have type\n"
+"    text/plain or text/x-patch). From and Subject headers of email\n"
+"    message are used as default committer and commit message. All\n"
+"    text/plain body parts before first diff are added to commit\n"
+"    message."
+msgstr ""
+
+msgid ""
+"    If the imported patch was generated by :hg:`export`, user and\n"
+"    description from patch override values from message headers and\n"
+"    body. Values given on command line with -m/--message and -u/--user\n"
+"    override these."
+msgstr ""
+
+msgid ""
+"    If --exact is specified, import will set the working directory to\n"
+"    the parent of each patch before applying it, and will abort if the\n"
+"    resulting changeset has a different ID than the one recorded in\n"
+"    the patch. This may happen due to character set problems or other\n"
+"    deficiencies in the text patch format."
+msgstr ""
+
+msgid ""
+"    With -s/--similarity, hg will attempt to discover renames and\n"
+"    copies in the patch in the same way as 'addremove'."
+msgstr ""
+
+msgid ""
+"    To read a patch from standard input, use \"-\" as the patch name. If\n"
+"    a URL is specified, the patch will be downloaded from it.\n"
+"    See :hg:`help dates` for a list of formats valid for -d/--date."
+msgstr ""
+
+msgid "to working directory"
+msgstr ""
+
+msgid "not a Mercurial patch"
+msgstr ""
+
+msgid "patch is damaged or loses information"
+msgstr ""
+
+msgid "applying patch from stdin\n"
+msgstr ""
+
+#, python-format
+msgid "applied %s\n"
+msgstr ""
+
+msgid "no diffs found"
+msgstr ""
+
+msgid "show new changesets found in source"
+msgstr ""
+
+msgid ""
+"    Show new changesets found in the specified path/URL or the default\n"
+"    pull location. These are the changesets that would have been pulled\n"
+"    if a pull at the time you issued this command."
+msgstr ""
+
+msgid ""
+"    For remote repository, using --bundle avoids downloading the\n"
+"    changesets twice if the incoming is followed by a pull."
+msgstr ""
+
+msgid "    See pull for valid source format details."
+msgstr ""
+
+msgid ""
+"    Returns 0 if there are incoming changes, 1 otherwise.\n"
+"    "
+msgstr ""
+
+msgid "create a new repository in the given directory"
+msgstr "creează un nou depozit în directorul specificat"
+
+msgid ""
+"    Initialize a new repository in the given directory. If the given\n"
+"    directory does not exist, it will be created."
+msgstr ""
+"    Inițializează un depozit nou în directorul specificat. Dacă\n"
+"    directorul nu există, va fi creat."
+
+msgid "    If no directory is given, the current directory is used."
+msgstr ""
+"    Dacă nu se specifică niciun director, va fi folosit directorul curent."
+
+msgid ""
+"    It is possible to specify an ``ssh://`` URL as the destination.\n"
+"    See :hg:`help urls` for more information."
+msgstr ""
+"    Ca destinație se poate specifica un URL ``ssh://``.\n"
+"    Vezi :hg:`help urls` pentru mai multe detalii."
+
+msgid "locate files matching specific patterns"
+msgstr ""
+
+msgid ""
+"    Print files under Mercurial control in the working directory whose\n"
+"    names match the given patterns."
+msgstr ""
+
+msgid ""
+"    By default, this command searches all directories in the working\n"
+"    directory. To search just the current directory and its\n"
+"    subdirectories, use \"--include .\"."
+msgstr ""
+
+msgid ""
+"    If no patterns are given to match, this command prints the names\n"
+"    of all files under Mercurial control in the working directory."
+msgstr ""
+
+msgid ""
+"    If you want to feed the output of this command into the \"xargs\"\n"
+"    command, use the -0 option to both this command and \"xargs\". This\n"
+"    will avoid the problem of \"xargs\" treating single filenames that\n"
+"    contain whitespace as multiple filenames."
+msgstr ""
+
+msgid "show revision history of entire repository or files"
+msgstr ""
+"afișează istoricul reviziilor pentru întregul depozit sau pentru unele "
+"fișiere"
+
+msgid ""
+"    Print the revision history of the specified files or the entire\n"
+"    project."
+msgstr ""
+"    Afișează istoricul reviziilor pentru fișierele specificate sau\n"
+"    pentru întregul proiect."
+
+msgid ""
+"    File history is shown without following rename or copy history of\n"
+"    files. Use -f/--follow with a filename to follow history across\n"
+"    renames and copies. --follow without a filename will only show\n"
+"    ancestors or descendants of the starting revision. --follow-first\n"
+"    only follows the first parent of merge revisions."
+msgstr ""
+"    Istoricul fișierelor este afișat fără a urmări istoricul redenumirilor\n"
+"    sau al copierii acestora - pentru aceasta, folosiți -f/--follow cu un\n"
+"    nume de fișier. Fără un nume de fișier, --follow va afișa doar\n"
+"    precedenți sau descendenți ai reviziei de stat. --follow-first\n"
+"    urmărește doar primul părinte al reviziilor fuzionate."
+
+msgid ""
+"    If no revision range is specified, the default is tip:0 unless\n"
+"    --follow is set, in which case the working directory parent is\n"
+"    used as the starting revision. You can specify a revision set for\n"
+"    log, see :hg:`help revsets` for more information."
+msgstr ""
+"    Dacă nu se specifică niciun interval de revizii, acesta este implicit\n"
+"    tip:0 (vârf:0), cu excepția cazului când --follow este setat, în "
+"această\n"
+"    situație părintele directorului de lucru este folosit ca revizie de "
+"stat.\n"
+"    Puteți specifica un set de revizii pentru 'log'; pentru mai multe\n"
+"    informații, vezi :hg:`help revsets`."
+
+msgid ""
+"    By default this command prints revision number and changeset id,\n"
+"    tags, non-trivial parents, user, date and time, and a summary for\n"
+"    each commit. When the -v/--verbose switch is used, the list of\n"
+"    changed files and full commit message are shown."
+msgstr ""
+"    Implicit, această comandă afișează numărul reviziei și id-ul setului\n"
+"    de modificări, etichete, părinți netriviali, utilizatorul, data și ora\n"
+"    și un rezumat al fiecărei depozitări. Când se folosește -v/--verbose,\n"
+"    se afișează lista fișierelor modificate și mesajul de depozitare complet."
+
+msgid ""
+"    NOTE: log -p/--patch may generate unexpected diff output for merge\n"
+"    changesets, as it will only compare the merge changeset against\n"
+"    its first parent. Also, only files different from BOTH parents\n"
+"    will appear in files:."
+msgstr ""
+"    NOTĂ: log -p/--patch poate genera afișaj diff neașteptat pentru seturi\n"
+"    de modificări de fuziune, deoarece va compara setul de modificări de\n"
+"    fuziune doar cu primul părinte. De asemenea, doar fișierele diferite\n"
+"    față de AMBII părinți vor apărea în lista de fișiere."
+
+msgid "output the current or given revision of the project manifest"
+msgstr ""
+
+msgid ""
+"    Print a list of version controlled files for the given revision.\n"
+"    If no revision is given, the first parent of the working directory\n"
+"    is used, or the null revision if no revision is checked out."
+msgstr ""
+
+msgid ""
+"    With -v, print file permissions, symlink and executable bits.\n"
+"    With --debug, print file revision hashes."
+msgstr ""
+
+msgid "merge working directory with another revision"
+msgstr ""
+
+msgid ""
+"    The current working directory is updated with all changes made in\n"
+"    the requested revision since the last common predecessor revision."
+msgstr ""
+
+msgid ""
+"    Files that changed between either parent are marked as changed for\n"
+"    the next commit and a commit must be performed before any further\n"
+"    updates to the repository are allowed. The next commit will have\n"
+"    two parents."
+msgstr ""
+
+msgid ""
+"    If no revision is specified, the working directory's parent is a\n"
+"    head revision, and the current branch contains exactly one other\n"
+"    head, the other head is merged with by default. Otherwise, an\n"
+"    explicit revision with which to merge with must be provided."
+msgstr ""
+
+msgid ""
+"    To undo an uncommitted merge, use :hg:`update --clean .` which\n"
+"    will check out a clean copy of the original merge parent, losing\n"
+"    all changes."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success, 1 if there are unresolved files.\n"
+"    "
+msgstr ""
+
+#, python-format
+msgid ""
+"branch '%s' has %d heads - please merge with an explicit rev\n"
+"(run 'hg heads .' to see heads)"
+msgstr ""
+
+#, python-format
+msgid ""
+"branch '%s' has one head - please merge with an explicit rev\n"
+"(run 'hg heads' to see all heads)"
+msgstr ""
+
+msgid "there is nothing to merge"
+msgstr ""
+
+#, python-format
+msgid "%s - use \"hg update\" instead"
+msgstr ""
+
+msgid ""
+"working dir not at a head rev - use \"hg update\" or merge with an explicit "
+"rev"
+msgstr ""
+
+msgid "show changesets not found in the destination"
+msgstr ""
+
+msgid ""
+"    Show changesets not found in the specified destination repository\n"
+"    or the default push location. These are the changesets that would\n"
+"    be pushed if a push was requested."
+msgstr ""
+
+msgid "    See pull for details of valid destination formats."
+msgstr ""
+
+msgid ""
+"    Returns 0 if there are outgoing changes, 1 otherwise.\n"
+"    "
+msgstr ""
+
+msgid "show the parents of the working directory or revision"
+msgstr ""
+
+msgid ""
+"    Print the working directory's parent revisions. If a revision is\n"
+"    given via -r/--rev, the parent of that revision will be printed.\n"
+"    If a file argument is given, the revision in which the file was\n"
+"    last changed (before the working directory revision or the\n"
+"    argument to --rev if given) is printed."
+msgstr ""
+
+msgid "can only specify an explicit filename"
+msgstr ""
+
+#, python-format
+msgid "'%s' not found in manifest!"
+msgstr "'%s' nu a fost găsit în manifest!"
+
+msgid "show aliases for remote repositories"
+msgstr ""
+
+msgid ""
+"    Show definition of symbolic path name NAME. If no name is given,\n"
+"    show definition of all available names."
+msgstr ""
+
+msgid ""
+"    Path names are defined in the [paths] section of\n"
+"    ``/etc/mercurial/hgrc`` and ``$HOME/.hgrc``. If run inside a\n"
+"    repository, ``.hg/hgrc`` is used, too."
+msgstr ""
+
+msgid ""
+"    The path names ``default`` and ``default-push`` have a special\n"
+"    meaning.  When performing a push or pull operation, they are used\n"
+"    as fallbacks if no location is specified on the command-line.\n"
+"    When ``default-push`` is set, it will be used for push and\n"
+"    ``default`` will be used for pull; otherwise ``default`` is used\n"
+"    as the fallback for both.  When cloning a repository, the clone\n"
+"    source is written as ``default`` in ``.hg/hgrc``.  Note that\n"
+"    ``default`` and ``default-push`` apply to all inbound (e.g.\n"
+"    :hg:`incoming`) and outbound (e.g. :hg:`outgoing`, :hg:`email` and\n"
+"    :hg:`bundle`) operations."
+msgstr ""
+
+msgid "    See :hg:`help urls` for more information."
+msgstr ""
+
+msgid "not found!\n"
+msgstr ""
+
+msgid "not updating, since new heads added\n"
+msgstr ""
+
+msgid "(run 'hg heads' to see heads, 'hg merge' to merge)\n"
+msgstr ""
+
+msgid "(run 'hg update' to get a working copy)\n"
+msgstr ""
+
+msgid "pull changes from the specified source"
+msgstr ""
+
+msgid "    Pull changes from a remote repository to a local one."
+msgstr ""
+
+msgid ""
+"    This finds all changes from the repository at the specified path\n"
+"    or URL and adds them to a local repository (the current one unless\n"
+"    -R is specified). By default, this does not update the copy of the\n"
+"    project in the working directory."
+msgstr ""
+
+msgid ""
+"    Use :hg:`incoming` if you want to see what would have been added\n"
+"    by a pull at the time you issued this command. If you then decide\n"
+"    to add those changes to the repository, you should use :hg:`pull\n"
+"    -r X` where ``X`` is the last changeset listed by :hg:`incoming`."
+msgstr ""
+
+msgid ""
+"    If SOURCE is omitted, the 'default' path will be used.\n"
+"    See :hg:`help urls` for more information."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success, 1 if an update had unresolved files.\n"
+"    "
+msgstr ""
+
+msgid "push changes to the specified destination"
+msgstr ""
+
+msgid ""
+"    Push changesets from the local repository to the specified\n"
+"    destination."
+msgstr ""
+
+msgid ""
+"    This operation is symmetrical to pull: it is identical to a pull\n"
+"    in the destination repository from the current one."
+msgstr ""
+
+msgid ""
+"    By default, push will not allow creation of new heads at the\n"
+"    destination, since multiple heads would make it unclear which head\n"
+"    to use. In this situation, it is recommended to pull and merge\n"
+"    before pushing."
+msgstr ""
+
+msgid ""
+"    Use --new-branch if you want to allow push to create a new named\n"
+"    branch that is not present at the destination. This allows you to\n"
+"    only create a new branch without forcing other changes."
+msgstr ""
+
+msgid ""
+"    Use -f/--force to override the default behavior and push all\n"
+"    changesets on all branches."
+msgstr ""
+
+msgid ""
+"    If -r/--rev is used, the specified revision and all its ancestors\n"
+"    will be pushed to the remote repository."
+msgstr ""
+
+msgid ""
+"    Please see :hg:`help urls` for important details about ``ssh://``\n"
+"    URLs. If DESTINATION is omitted, a default path will be used."
+msgstr ""
+
+msgid ""
+"    Returns 0 if push was successful, 1 if nothing to push.\n"
+"    "
+msgstr ""
+
+#, python-format
+msgid "pushing to %s\n"
+msgstr ""
+
+msgid "roll back an interrupted transaction"
+msgstr ""
+
+msgid "    Recover from an interrupted commit or pull."
+msgstr ""
+
+msgid ""
+"    This command tries to fix the repository status after an\n"
+"    interrupted operation. It should only be necessary when Mercurial\n"
+"    suggests it."
+msgstr ""
+
+msgid ""
+"    Returns 0 if successful, 1 if nothing to recover or verify fails.\n"
+"    "
+msgstr ""
+
+msgid "remove the specified files on the next commit"
+msgstr ""
+
+msgid "    Schedule the indicated files for removal from the repository."
+msgstr ""
+
+msgid ""
+"    This only removes files from the current branch, not from the\n"
+"    entire project history. -A/--after can be used to remove only\n"
+"    files that have already been deleted, -f/--force can be used to\n"
+"    force deletion, and -Af can be used to remove files from the next\n"
+"    revision without deleting them from the working directory."
+msgstr ""
+
+msgid ""
+"    The following table details the behavior of remove for different\n"
+"    file states (columns) and option combinations (rows). The file\n"
+"    states are Added [A], Clean [C], Modified [M] and Missing [!] (as\n"
+"    reported by :hg:`status`). The actions are Warn, Remove (from\n"
+"    branch) and Delete (from disk)::"
+msgstr ""
+
+msgid ""
+"             A  C  M  !\n"
+"      none   W  RD W  R\n"
+"      -f     R  RD RD R\n"
+"      -A     W  W  W  R\n"
+"      -Af    R  R  R  R"
+msgstr ""
+
+msgid ""
+"    This command schedules the files to be removed at the next commit.\n"
+"    To undo a remove before that, see :hg:`revert`."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success, 1 if any warnings encountered.\n"
+"    "
+msgstr ""
+
+#, python-format
+msgid "not removing %s: file is untracked\n"
+msgstr ""
+
+#, python-format
+msgid "not removing %s: file %s (use -f to force removal)\n"
+msgstr ""
+
+msgid "still exists"
+msgstr ""
+
+msgid "is modified"
+msgstr ""
+
+msgid "has been marked for add"
+msgstr ""
+
+msgid "rename files; equivalent of copy + remove"
+msgstr ""
+
+msgid ""
+"    Mark dest as copies of sources; mark sources for deletion. If dest\n"
+"    is a directory, copies are put in that directory. If dest is a\n"
+"    file, there can only be one source."
+msgstr ""
+
+msgid ""
+"    This command takes effect at the next commit. To undo a rename\n"
+"    before that, see :hg:`revert`."
+msgstr ""
+
+msgid "various operations to help finish a merge"
+msgstr ""
+
+msgid ""
+"    This command includes several actions that are often useful while\n"
+"    performing a merge, after running ``merge`` but before running\n"
+"    ``commit``.  (It is only meaningful if your working directory has\n"
+"    two parents.)  It is most relevant for merges with unresolved\n"
+"    conflicts, which are typically a result of non-interactive merging with\n"
+"    ``internal:merge`` or a command-line merge tool like ``diff3``."
+msgstr ""
+
+msgid "    The available actions are:"
+msgstr ""
+
+msgid ""
+"      1) list files that were merged with conflicts (U, for unresolved)\n"
+"         and without conflicts (R, for resolved): ``hg resolve -l``\n"
+"         (this is like ``status`` for merges)\n"
+"      2) record that you have resolved conflicts in certain files:\n"
+"         ``hg resolve -m [file ...]`` (default: mark all unresolved files)\n"
+"      3) forget that you have resolved conflicts in certain files:\n"
+"         ``hg resolve -u [file ...]`` (default: unmark all resolved files)\n"
+"      4) discard your current attempt(s) at resolving conflicts and\n"
+"         restart the merge from scratch: ``hg resolve file...``\n"
+"         (or ``-a`` for all unresolved files)"
+msgstr ""
+
+msgid ""
+"    Note that Mercurial will not let you commit files with unresolved merge\n"
+"    conflicts.  You must use ``hg resolve -m ...`` before you can commit\n"
+"    after a conflicting merge."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success, 1 if any files fail a resolve attempt.\n"
+"    "
+msgstr ""
+
+msgid "too many options specified"
+msgstr ""
+
+msgid "can't specify --all and patterns"
+msgstr ""
+
+msgid "no files or directories specified; use --all to remerge all files"
+msgstr ""
+
+msgid "restore individual files or directories to an earlier state"
+msgstr ""
+
+msgid ""
+"    NOTE: This command is most likely not what you are looking for. revert\n"
+"    will partially overwrite content in the working directory without "
+"changing\n"
+"    the working directory parents. Use :hg:`update -r rev` to check out "
+"earlier\n"
+"    revisions, or :hg:`update --clean .` to undo a merge which has added\n"
+"    another parent."
+msgstr ""
+
+msgid ""
+"    With no revision specified, revert the named files or directories\n"
+"    to the contents they had in the parent of the working directory.\n"
+"    This restores the contents of the affected files to an unmodified\n"
+"    state and unschedules adds, removes, copies, and renames. If the\n"
+"    working directory has two parents, you must explicitly specify a\n"
+"    revision."
+msgstr ""
+
+msgid ""
+"    Using the -r/--rev option, revert the given files or directories\n"
+"    to their contents as of a specific revision. This can be helpful\n"
+"    to \"roll back\" some or all of an earlier change. See :hg:`help\n"
+"    dates` for a list of formats valid for -d/--date."
+msgstr ""
+
+msgid ""
+"    Revert modifies the working directory. It does not commit any\n"
+"    changes, or change the parent of the working directory. If you\n"
+"    revert to a revision other than the parent of the working\n"
+"    directory, the reverted files will thus appear modified\n"
+"    afterwards."
+msgstr ""
+
+msgid ""
+"    If a file has been deleted, it is restored. If the executable mode\n"
+"    of a file was changed, it is reset."
+msgstr ""
+
+msgid ""
+"    If names are given, all files matching the names are reverted.\n"
+"    If no arguments are given, no files are reverted."
+msgstr ""
+
+msgid ""
+"    Modified files are saved with a .orig suffix before reverting.\n"
+"    To disable these backups, use --no-backup."
+msgstr ""
+
+msgid "you can't specify a revision and a date"
+msgstr ""
+
+msgid "no files or directories specified; use --all to revert the whole repo"
+msgstr ""
+
+#, python-format
+msgid "forgetting %s\n"
+msgstr "se uită %s\n"
+
+#, python-format
+msgid "reverting %s\n"
+msgstr ""
+
+#, python-format
+msgid "undeleting %s\n"
+msgstr ""
+
+#, python-format
+msgid "saving current version of %s as %s\n"
+msgstr ""
+
+#, python-format
+msgid "file not managed: %s\n"
+msgstr ""
+
+#, python-format
+msgid "no changes needed to %s\n"
+msgstr ""
+
+msgid "roll back the last transaction (dangerous)"
+msgstr ""
+
+msgid ""
+"    This command should be used with care. There is only one level of\n"
+"    rollback, and there is no way to undo a rollback. It will also\n"
+"    restore the dirstate at the time of the last transaction, losing\n"
+"    any dirstate changes since that time. This command does not alter\n"
+"    the working directory."
+msgstr ""
+
+msgid ""
+"    Transactions are used to encapsulate the effects of all commands\n"
+"    that create new changesets or propagate existing changesets into a\n"
+"    repository. For example, the following commands are transactional,\n"
+"    and their effects can be rolled back:"
+msgstr ""
+
+msgid ""
+"    - commit\n"
+"    - import\n"
+"    - pull\n"
+"    - push (with this repository as the destination)\n"
+"    - unbundle"
+msgstr ""
+
+msgid ""
+"    This command is not intended for use on public repositories. Once\n"
+"    changes are visible for pull by other users, rolling a transaction\n"
+"    back locally is ineffective (someone else may already have pulled\n"
+"    the changes). Furthermore, a race is possible with readers of the\n"
+"    repository; for example an in-progress pull from the repository\n"
+"    may fail if a rollback is performed."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success, 1 if no rollback data is available.\n"
+"    "
+msgstr ""
+
+msgid "print the root (top) of the current working directory"
+msgstr ""
+
+msgid "    Print the root directory of the current repository."
+msgstr ""
+
+msgid "start stand-alone webserver"
+msgstr ""
+
+msgid ""
+"    Start a local HTTP repository browser and pull server. You can use\n"
+"    this for ad-hoc sharing and browing of repositories. It is\n"
+"    recommended to use a real web server to serve a repository for\n"
+"    longer periods of time."
+msgstr ""
+
+msgid ""
+"    Please note that the server does not implement access control.\n"
+"    This means that, by default, anybody can read from the server and\n"
+"    nobody can write to it by default. Set the ``web.allow_push``\n"
+"    option to ``*`` to allow everybody to push to the server. You\n"
+"    should use a real web server if you need to authenticate users."
+msgstr ""
+
+msgid ""
+"    By default, the server logs accesses to stdout and errors to\n"
+"    stderr. Use the -A/--accesslog and -E/--errorlog options to log to\n"
+"    files."
+msgstr ""
+
+msgid ""
+"    To have the server choose a free port number to listen on, specify\n"
+"    a port number of 0; in this case, the server will print the port\n"
+"    number it uses."
+msgstr ""
+
+#, python-format
+msgid "listening at http://%s%s/%s (bound to %s:%d)\n"
+msgstr ""
+
+msgid "show changed files in the working directory"
+msgstr ""
+
+msgid ""
+"    Show status of files in the repository. If names are given, only\n"
+"    files that match are shown. Files that are clean or ignored or\n"
+"    the source of a copy/move operation, are not listed unless\n"
+"    -c/--clean, -i/--ignored, -C/--copies or -A/--all are given.\n"
+"    Unless options described with \"show only ...\" are given, the\n"
+"    options -mardu are used."
+msgstr ""
+
+msgid ""
+"    Option -q/--quiet hides untracked (unknown and ignored) files\n"
+"    unless explicitly requested with -u/--unknown or -i/--ignored."
+msgstr ""
+
+msgid ""
+"    NOTE: status may appear to disagree with diff if permissions have\n"
+"    changed or a merge has occurred. The standard diff format does not\n"
+"    report permission changes and diff only reports changes relative\n"
+"    to one merge parent."
+msgstr ""
+
+msgid ""
+"    If one revision is given, it is used as the base revision.\n"
+"    If two revisions are given, the differences between them are\n"
+"    shown. The --change option can also be used as a shortcut to list\n"
+"    the changed files of a revision from its first parent."
+msgstr ""
+
+msgid "    The codes used to show the status of files are::"
+msgstr ""
+
+msgid ""
+"      M = modified\n"
+"      A = added\n"
+"      R = removed\n"
+"      C = clean\n"
+"      ! = missing (deleted by non-hg command, but still tracked)\n"
+"      ? = not tracked\n"
+"      I = ignored\n"
+"        = origin of the previous file listed as A (added)"
+msgstr ""
+
+msgid "summarize working directory state"
+msgstr ""
+
+msgid ""
+"    This generates a brief summary of the working directory state,\n"
+"    including parents, branch, commit status, and available updates."
+msgstr ""
+
+msgid ""
+"    With the --remote option, this will check the default paths for\n"
+"    incoming and outgoing changes. This can be time-consuming."
+msgstr ""
+
+#, python-format
+msgid "parent: %d:%s "
+msgstr ""
+
+msgid " (empty repository)"
+msgstr ""
+
+msgid " (no revision checked out)"
+msgstr ""
+
+#, python-format
+msgid "branch: %s\n"
+msgstr ""
+
+#, python-format
+msgid "%d modified"
+msgstr ""
+
+#, python-format
+msgid "%d added"
+msgstr ""
+
+#, python-format
+msgid "%d removed"
+msgstr ""
+
+#, python-format
+msgid "%d renamed"
+msgstr ""
+
+#, python-format
+msgid "%d copied"
+msgstr ""
+
+#, python-format
+msgid "%d deleted"
+msgstr ""
+
+#, python-format
+msgid "%d unknown"
+msgstr ""
+
+#, python-format
+msgid "%d ignored"
+msgstr ""
+
+#, python-format
+msgid "%d unresolved"
+msgstr ""
+
+#, python-format
+msgid "%d subrepos"
+msgstr ""
+
+msgid " (merge)"
+msgstr ""
+
+msgid " (new branch)"
+msgstr ""
+
+msgid " (head closed)"
+msgstr ""
+
+msgid " (clean)"
+msgstr ""
+
+msgid " (new branch head)"
+msgstr ""
+
+#, python-format
+msgid "commit: %s\n"
+msgstr ""
+
+msgid "update: (current)\n"
+msgstr ""
+
+#, python-format
+msgid "update: %d new changesets (update)\n"
+msgstr ""
+
+#, python-format
+msgid "update: %d new changesets, %d branch heads (merge)\n"
+msgstr ""
+
+msgid "1 or more incoming"
+msgstr ""
+
+#, python-format
+msgid "%d outgoing"
+msgstr ""
+
+#, python-format
+msgid "remote: %s\n"
+msgstr ""
+
+msgid "remote: (synced)\n"
+msgstr ""
+
+msgid "add one or more tags for the current or given revision"
+msgstr ""
+
+msgid "    Name a particular revision using <name>."
+msgstr ""
+
+msgid ""
+"    Tags are used to name particular revisions of the repository and are\n"
+"    very useful to compare different revisions, to go back to significant\n"
+"    earlier versions or to mark branch points as releases, etc."
+msgstr ""
+
+msgid ""
+"    If no revision is given, the parent of the working directory is\n"
+"    used, or tip if no revision is checked out."
+msgstr ""
+
+msgid ""
+"    To facilitate version control, distribution, and merging of tags,\n"
+"    they are stored as a file named \".hgtags\" which is managed\n"
+"    similarly to other project files and can be hand-edited if\n"
+"    necessary. The file '.hg/localtags' is used for local tags (not\n"
+"    shared among repositories)."
+msgstr ""
+
+msgid ""
+"    Since tag names have priority over branch names during revision\n"
+"    lookup, using an existing branch name as a tag name is discouraged."
+msgstr ""
+
+msgid "tag names must be unique"
+msgstr ""
+
+msgid "tag names cannot consist entirely of whitespace"
+msgstr ""
+
+msgid "--rev and --remove are incompatible"
+msgstr ""
+
+#, python-format
+msgid "tag '%s' does not exist"
+msgstr ""
+
+#, python-format
+msgid "tag '%s' is not a global tag"
+msgstr ""
+
+#, python-format
+msgid "tag '%s' is not a local tag"
+msgstr ""
+
+#, python-format
+msgid "tag '%s' already exists (use -f to force)"
+msgstr ""
+
+msgid "list repository tags"
+msgstr ""
+
+msgid ""
+"    This lists both regular and local tags. When the -v/--verbose\n"
+"    switch is used, a third column \"local\" is printed for local tags."
+msgstr ""
+
+msgid "show the tip revision"
+msgstr ""
+
+msgid ""
+"    The tip revision (usually just called the tip) is the changeset\n"
+"    most recently added to the repository (and therefore the most\n"
+"    recently changed head)."
+msgstr ""
+
+msgid ""
+"    If you have just made a commit, that commit will be the tip. If\n"
+"    you have just pulled changes from another repository, the tip of\n"
+"    that repository becomes the current tip. The \"tip\" tag is special\n"
+"    and cannot be renamed or assigned to a different changeset."
+msgstr ""
+
+msgid "apply one or more changegroup files"
+msgstr ""
+
+msgid ""
+"    Apply one or more compressed changegroup files generated by the\n"
+"    bundle command."
+msgstr ""
+
+msgid ""
+"    Returns 0 on success, 1 if an update has unresolved files.\n"
+"    "
+msgstr ""
+
+msgid "update working directory (or switch revisions)"
+msgstr "actualizează directorul de lucru (sau comută între revizii)"
+
+msgid ""
+"    Update the repository's working directory to the specified\n"
+"    changeset."
+msgstr ""
+"    Actualizează directorul de lucru al depozitului la setul de\n"
+"    modificări specificat."
+
+msgid ""
+"    If no changeset is specified, attempt to update to the tip of the\n"
+"    current branch. If this changeset is a descendant of the working\n"
+"    directory's parent, update to it, otherwise abort."
+msgstr ""
+"    Dacă nu se specifică nici un set de modificări, se încearcă "
+"actualizarea\n"
+"    la vârful ramurii curente. Dacă acest set de modificări este descendent\n"
+"    al părintelui directorului de lucru, se actualizează la el, altfel se "
+"renunță."
+
+msgid ""
+"    The following rules apply when the working directory contains\n"
+"    uncommitted changes:"
+msgstr ""
+"   Când directorul de lucru conține modificări nedepozitate, se\n"
+"   aplică următoarele reguli:"
+
+msgid ""
+"    1. If neither -c/--check nor -C/--clean is specified, and if\n"
+"       the requested changeset is an ancestor or descendant of\n"
+"       the working directory's parent, the uncommitted changes\n"
+"       are merged into the requested changeset and the merged\n"
+"       result is left uncommitted. If the requested changeset is\n"
+"       not an ancestor or descendant (that is, it is on another\n"
+"       branch), the update is aborted and the uncommitted changes\n"
+"       are preserved."
+msgstr ""
+"    1. Dacă nu e specificat -c/--check sau -C/--clean, și dacă setul de\n"
+"       modificări solicitat este ascendent sau descendent al părintelui\n"
+"       directorului de lucru, modificările nedepozitate sunt fuzionate în\n"
+"       setul de modificări solicitat, iar rezultatul fuziunii este lăsat\n"
+"       nedepozitat. Dacă setul de modificări solicitat nu este ascendent\n"
+"       sau descendent (adică se află în altă ramură), actualizarea este\n"
+"       întreruptă, iar modificările nedepozitate sunt păstrate."
+
+msgid ""
+"    2. With the -c/--check option, the update is aborted and the\n"
+"       uncommitted changes are preserved."
+msgstr ""
+"    2. Cu opțiunea -c/--check, actualizarea este întreruptă,  iar\n"
+"       modificările nedepozitate sunt păstrate."
+
+msgid ""
+"    3. With the -C/--clean option, uncommitted changes are discarded and\n"
+"       the working directory is updated to the requested changeset."
+msgstr ""
+"    3. Cu opțiunea -C/--clean, modificările nedepozitate sunt înlăturate, "
+"iar\n"
+"       directorul de lucru este actualizat la setul de modificări solicitat."
+
+msgid ""
+"    Use null as the changeset to remove the working directory (like\n"
+"    :hg:`clone -U`)."
+msgstr ""
+"    Folosiți null ca set de modificări pentru a elimina directorul de\n"
+"    lucru (similar cu :hg:`clone -U`)."
+
+msgid ""
+"    If you want to update just one file to an older changeset, use :hg:"
+"`revert`."
+msgstr ""
+"    Dacă doriți să actualizați doar un singur fișier la un set de "
+"modificări\n"
+"    mai vechi, folosiți :hg:`revert`."
+
+msgid "cannot specify both -c/--check and -C/--clean"
+msgstr ""
+
+msgid "uncommitted local changes"
+msgstr ""
+
+msgid "verify the integrity of the repository"
+msgstr ""
+
+msgid "    Verify the integrity of the current repository."
+msgstr ""
+
+msgid ""
+"    This will perform an extensive check of the repository's\n"
+"    integrity, validating the hashes and checksums of each entry in\n"
+"    the changelog, manifest, and tracked files, as well as the\n"
+"    integrity of their crosslinks and indices."
+msgstr ""
+
+msgid "output version and copyright information"
+msgstr ""
+
+#, python-format
+msgid "Mercurial Distributed SCM (version %s)\n"
+msgstr ""
+
+msgid ""
+"\n"
+"Copyright (C) 2005-2010 Matt Mackall <mpm@selenic.com> and others\n"
+"This is free software; see the source for copying conditions. There is NO\n"
+"warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n"
+msgstr ""
+
+msgid "repository root directory or name of overlay bundle file"
+msgstr ""
+
+msgid "DIR"
+msgstr ""
+
+msgid "change working directory"
+msgstr ""
+
+msgid "do not prompt, assume 'yes' for any required answers"
+msgstr ""
+
+msgid "suppress output"
+msgstr ""
+
+msgid "enable additional output"
+msgstr ""
+
+msgid "set/override config option (use 'section.name=value')"
+msgstr ""
+
+msgid "CONFIG"
+msgstr ""
+
+msgid "enable debugging output"
+msgstr ""
+
+msgid "start debugger"
+msgstr ""
+
+msgid "set the charset encoding"
+msgstr ""
+
+msgid "ENCODE"
+msgstr ""
+
+msgid "MODE"
+msgstr ""
+
+msgid "set the charset encoding mode"
+msgstr ""
+
+msgid "always print a traceback on exception"
+msgstr ""
+
+msgid "time how long the command takes"
+msgstr ""
+
+msgid "print command execution profile"
+msgstr ""
+
+msgid "output version information and exit"
+msgstr ""
+
+msgid "display help and exit"
+msgstr ""
+
+msgid "do not perform actions, just print output"
+msgstr "acțiunea nu se execută, doar se afișează mesajele"
+
+msgid "specify ssh command to use"
+msgstr "specifică comanda ssh care va fi folosită"
+
+msgid "specify hg command to run on the remote side"
+msgstr "specifică comanda hg care va fi executată pe mașina de la distanță"
+
+msgid "PATTERN"
+msgstr ""
+
+msgid "include names matching the given patterns"
+msgstr "include numele care se potrivesc cu șabloanele date"
+
+msgid "exclude names matching the given patterns"
+msgstr "exclude numele care se potrivesc cu șabloanele date"
+
+msgid "use text as commit message"
+msgstr ""
+
+msgid "read commit message from file"
+msgstr "citește mesajul pentru depozitare din fișier"
+
+msgid "record datecode as commit date"
+msgstr "înregistrează codul de dată ca dată a depozitării"
+
+msgid "record the specified user as committer"
+msgstr ""
+"înregistrează utilizatorul specificat ca fiind cel care a făcut depozitarea"
+
+msgid "STYLE"
+msgstr ""
+
+msgid "display using template map file"
+msgstr "afișează folosind fișierul cu harta de șabloane"
+
+msgid "display with template"
+msgstr "show the revision DAG"
+
+msgid "do not show merges"
+msgstr "nu afișa fuziunile"
+
+msgid "output diffstat-style summary of changes"
+msgstr ""
+
+msgid "treat all files as text"
+msgstr ""
+
+msgid "omit dates from diff headers"
+msgstr ""
+
+msgid "show which function each change is in"
+msgstr ""
+
+msgid "produce a diff that undoes the changes"
+msgstr ""
+
+msgid "ignore white space when comparing lines"
+msgstr ""
+
+msgid "ignore changes in the amount of white space"
+msgstr ""
+
+msgid "ignore changes whose lines are all blank"
+msgstr ""
+
+msgid "number of lines of context to show"
+msgstr ""
+
+msgid "SIMILARITY"
+msgstr ""
+
+msgid "guess renamed files by similarity (0<=s<=100)"
+msgstr ""
+
+msgid "[OPTION]... [FILE]..."
+msgstr ""
+
+msgid "annotate the specified revision"
+msgstr ""
+
+msgid "follow copies/renames and list the filename (DEPRECATED)"
+msgstr ""
+
+msgid "don't follow copies and renames"
+msgstr ""
+
+msgid "list the author (long with -v)"
+msgstr ""
+
+msgid "list the filename"
+msgstr ""
+
+msgid "list the date (short with -q)"
+msgstr ""
+
+msgid "list the revision number (default)"
+msgstr ""
+
+msgid "list the changeset"
+msgstr ""
+
+msgid "show line number at the first appearance"
+msgstr ""
+
+msgid "[-r REV] [-f] [-a] [-u] [-d] [-n] [-c] [-l] FILE..."
+msgstr ""
+
+msgid "do not pass files through decoders"
+msgstr ""
+
+msgid "PREFIX"
+msgstr ""
+
+msgid "directory prefix for files in archive"
+msgstr ""
+
+msgid "revision to distribute"
+msgstr ""
+
+msgid "type of distribution to create"
+msgstr ""
+
+msgid "[OPTION]... DEST"
+msgstr ""
+
+msgid "merge with old dirstate parent after backout"
+msgstr ""
+
+msgid "parent to choose when backing out merge"
+msgstr ""
+
+msgid "revision to backout"
+msgstr ""
+
+msgid "[OPTION]... [-r] REV"
+msgstr ""
+
+msgid "reset bisect state"
+msgstr ""
+
+msgid "mark changeset good"
+msgstr ""
+
+msgid "mark changeset bad"
+msgstr ""
+
+msgid "skip testing changeset"
+msgstr ""
+
+msgid "use command to check changeset state"
+msgstr ""
+
+msgid "do not update to target"
+msgstr ""
+
+msgid "[-gbsr] [-U] [-c CMD] [REV]"
+msgstr ""
+
+msgid "set branch name even if it shadows an existing branch"
+msgstr ""
+
+msgid "reset branch name to parent branch name"
+msgstr ""
+
+msgid "[-fC] [NAME]"
+msgstr ""
+
+msgid "show only branches that have unmerged heads"
+msgstr ""
+
+msgid "show normal and closed branches"
+msgstr ""
+
+msgid "[-ac]"
+msgstr ""
+
+msgid "run even when the destination is unrelated"
+msgstr ""
+
+msgid "a changeset intended to be added to the destination"
+msgstr ""
+
+msgid "a specific branch you would like to bundle"
+msgstr ""
+
+msgid "a base changeset assumed to be available at the destination"
+msgstr ""
+
+msgid "bundle all changesets in the repository"
+msgstr ""
+
+msgid "bundle compression type to use"
+msgstr ""
+
+msgid "[-f] [-t TYPE] [-a] [-r REV]... [--base REV]... FILE [DEST]"
+msgstr ""
+
+msgid "print output to file with formatted name"
+msgstr ""
+
+msgid "print the given revision"
+msgstr ""
+
+msgid "apply any matching decode filter"
+msgstr ""
+
+msgid "[OPTION]... FILE..."
+msgstr ""
+
+msgid "the clone will include an empty working copy (only a repository)"
+msgstr ""
+
+msgid "revision, tag or branch to check out"
+msgstr "revizia, eticheta sau ramura care va fi actualizată"
+
+msgid "include the specified changeset"
+msgstr ""
+
+msgid "clone only the specified branch"
+msgstr ""
+
+msgid "[OPTION]... SOURCE [DEST]"
+msgstr ""
+
+msgid "mark new/missing files as added/removed before committing"
+msgstr ""
+"marchează fișierele noi/lipsă ca adăugate/eliminate înainte de depozitare"
+
+msgid "mark a branch as closed, hiding it from the branch list"
+msgstr "marchează o ramură ca închisă, ascunzând-o din lista ramurilor"
+
+msgid "record a copy that has already occurred"
+msgstr ""
+
+msgid "forcibly copy over an existing managed file"
+msgstr ""
+
+msgid "[OPTION]... [SOURCE]... DEST"
+msgstr ""
+
+msgid "[INDEX] REV1 REV2"
+msgstr ""
+
+msgid "add single file mergeable changes"
+msgstr ""
+
+msgid "add single file all revs append to"
+msgstr ""
+
+msgid "add single file all revs overwrite"
+msgstr ""
+
+msgid "add new file at each rev"
+msgstr ""
+
+msgid "[OPTION]... TEXT"
+msgstr ""
+
+msgid "[COMMAND]"
+msgstr ""
+
+msgid "show the command options"
+msgstr ""
+
+msgid "[-o] CMD"
+msgstr ""
+
+msgid "use tags as labels"
+msgstr ""
+
+msgid "annotate with branch names"
+msgstr ""
+
+msgid "use dots for runs"
+msgstr ""
+
+msgid "separate elements by spaces"
+msgstr ""
+
+msgid "[OPTION]... [FILE [REV]...]"
+msgstr ""
+
+msgid "try extended date formats"
+msgstr ""
+
+msgid "[-e] DATE [RANGE]"
+msgstr ""
+
+msgid "FILE REV"
+msgstr ""
+
+msgid "[PATH]"
+msgstr ""
+
+msgid "REPO NAMESPACE [KEY OLD NEW]"
+msgstr ""
+
+msgid "revision to rebuild to"
+msgstr ""
+
+msgid "[-r REV] [REV]"
+msgstr ""
+
+msgid "revision to debug"
+msgstr ""
+
+msgid "[-r REV] FILE"
+msgstr ""
+
+msgid "REV1 [REV2]"
+msgstr ""
+
+msgid "do not display the saved mtime"
+msgstr ""
+
+msgid "[OPTION]..."
+msgstr ""
+
+msgid "revision to check"
+msgstr ""
+
+msgid "[OPTION]... ([-c REV] | [-r REV1 [-r REV2]]) [FILE]..."
+msgstr ""
+
+msgid "diff against the second parent"
+msgstr ""
+
+msgid "revisions to export"
+msgstr ""
+
+msgid "[OPTION]... [-o OUTFILESPEC] REV..."
+msgstr ""
+
+msgid "end fields with NUL"
+msgstr ""
+
+msgid "print all revisions that match"
+msgstr ""
+
+msgid "follow changeset history, or file history across copies and renames"
+msgstr ""
+"urmărește istoricul seturilor de modificări sau al fișierelor, ținând cont "
+"de copieri și redenumiri"
+
+msgid "ignore case when matching"
+msgstr ""
+
+msgid "print only filenames and revisions that match"
+msgstr ""
+
+msgid "print matching line numbers"
+msgstr ""
+
+msgid "only search files changed within revision range"
+msgstr ""
+
+msgid "[OPTION]... PATTERN [FILE]..."
+msgstr ""
+
+msgid "show only heads which are descendants of REV"
+msgstr ""
+
+msgid "show topological heads only"
+msgstr ""
+
+msgid "show active branchheads only [DEPRECATED]"
+msgstr ""
+
+msgid "show normal and closed branch heads"
+msgstr ""
+
+msgid "[-ac] [-r REV] [REV]..."
+msgstr ""
+
+msgid "[TOPIC]"
+msgstr ""
+
+msgid "identify the specified revision"
+msgstr ""
+
+msgid "show local revision number"
+msgstr ""
+
+msgid "show global revision id"
+msgstr "arată id-ul global al reviziei"
+
+msgid "show branch"
+msgstr ""
+
+msgid "show tags"
+msgstr ""
+
+msgid "[-nibt] [-r REV] [SOURCE]"
+msgstr ""
+
+msgid ""
+"directory strip option for patch. This has the same meaning as the "
+"corresponding patch option"
+msgstr ""
+
+msgid "PATH"
+msgstr ""
+
+msgid "base path"
+msgstr ""
+
+msgid "skip check for outstanding uncommitted changes"
+msgstr ""
+
+msgid "don't commit, just update the working directory"
+msgstr ""
+
+msgid "apply patch to the nodes from which it was generated"
+msgstr ""
+
+msgid "use any branch information in patch (implied by --exact)"
+msgstr ""
+
+msgid "[OPTION]... PATCH..."
+msgstr ""
+
+msgid "run even if remote repository is unrelated"
+msgstr ""
+
+msgid "show newest record first"
+msgstr ""
+
+msgid "file to store the bundles into"
+msgstr ""
+
+msgid "a remote changeset intended to be added"
+msgstr ""
+
+msgid "a specific branch you would like to pull"
+msgstr ""
+
+msgid "[-p] [-n] [-M] [-f] [-r REV]... [--bundle FILENAME] [SOURCE]"
+msgstr ""
+
+msgid "[-e CMD] [--remotecmd CMD] [DEST]"
+msgstr ""
+
+msgid "search the repository as it is in REV"
+msgstr ""
+
+msgid "end filenames with NUL, for use with xargs"
+msgstr ""
+
+msgid "print complete paths from the filesystem root"
+msgstr ""
+
+msgid "[OPTION]... [PATTERN]..."
+msgstr ""
+
+msgid "only follow the first parent of merge changesets"
+msgstr "urmărește doar primul părinte al seturilor de modificări de fuziune"
+
+msgid "show revisions matching date spec"
+msgstr "afișează reviziile care se potrivesc cu data"
+
+msgid "show copied files"
+msgstr "afișează fișierele copiate"
+
+msgid "do case-insensitive search for a given text"
+msgstr "caută textul dat fără a ține cont de majuscule"
+
+msgid "include revisions where files were removed"
+msgstr "include reviziile în care au fost eliminate fișiere"
+
+msgid "show only merges"
+msgstr "afișează doar fuziunile"
+
+msgid "revisions committed by user"
+msgstr "reviziile depozitate de utilizatorul"
+
+msgid "show only changesets within the given named branch (DEPRECATED)"
+msgstr ""
+"afișează doar seturile de modificări din interiorul ramurii cu nume date "
+"(ÃŽNVECHIT)"
+
+msgid "show changesets within the given named branch"
+msgstr ""
+
+msgid "do not display revision or any of its ancestors"
+msgstr "nu afișa revizia sau oricare din strămoșii ei"
+
+msgid "[OPTION]... [FILE]"
+msgstr ""
+
+msgid "revision to display"
+msgstr ""
+
+msgid "[-r REV]"
+msgstr ""
+
+msgid "force a merge with outstanding changes"
+msgstr ""
+
+msgid "revision to merge"
+msgstr ""
+
+msgid "review revisions to merge (no merge is performed)"
+msgstr ""
+
+msgid "[-P] [-f] [[-r] REV]"
+msgstr ""
+
+msgid "a changeset intended to be included in the destination"
+msgstr ""
+
+msgid "a specific branch you would like to push"
+msgstr ""
+
+msgid "[-M] [-p] [-n] [-f] [-r REV]... [DEST]"
+msgstr ""
+
+msgid "show parents of the specified revision"
+msgstr ""
+
+msgid "[-r REV] [FILE]"
+msgstr ""
+
+msgid "[NAME]"
+msgstr ""
+
+msgid "update to new branch head if changesets were pulled"
+msgstr ""
+
+msgid "run even when remote repository is unrelated"
+msgstr ""
+
+msgid "[-u] [-f] [-r REV]... [-e CMD] [--remotecmd CMD] [SOURCE]"
+msgstr ""
+
+msgid "force push"
+msgstr ""
+
+msgid "allow pushing a new branch"
+msgstr ""
+
+msgid "[-f] [-r REV]... [-e CMD] [--remotecmd CMD] [DEST]"
+msgstr ""
+
+msgid "record delete for missing files"
+msgstr ""
+
+msgid "remove (and delete) file even if added or modified"
+msgstr ""
+
+msgid "record a rename that has already occurred"
+msgstr ""
+
+msgid "[OPTION]... SOURCE... DEST"
+msgstr ""
+
+msgid "select all unresolved files"
+msgstr ""
+
+msgid "list state of files needing merge"
+msgstr ""
+
+msgid "mark files as resolved"
+msgstr ""
+
+msgid "unmark files as resolved"
+msgstr ""
+
+msgid "hide status prefix"
+msgstr ""
+
+msgid "revert all changes when no arguments given"
+msgstr ""
+
+msgid "tipmost revision matching date"
+msgstr "revizia cea mai apropiată de vârf care se potrivește cu data"
+
+msgid "revert to the specified revision"
+msgstr ""
+
+msgid "do not save backup copies of files"
+msgstr ""
+
+msgid "[OPTION]... [-r REV] [NAME]..."
+msgstr ""
+
+msgid "name of access log file to write to"
+msgstr ""
+
+msgid "name of error log file to write to"
+msgstr ""
+
+msgid "PORT"
+msgstr ""
+
+msgid "port to listen on (default: 8000)"
+msgstr ""
+
+msgid "ADDR"
+msgstr ""
+
+msgid "address to listen on (default: all interfaces)"
+msgstr ""
+
+msgid "prefix path to serve from (default: server root)"
+msgstr ""
+
+msgid "name to show in web pages (default: working directory)"
+msgstr ""
+
+msgid "name of the hgweb config file (serve more than one repository)"
+msgstr ""
+
+msgid "name of the hgweb config file (DEPRECATED)"
+msgstr ""
+
+msgid "for remote clients"
+msgstr ""
+
+msgid "web templates to use"
+msgstr ""
+
+msgid "template style to use"
+msgstr ""
+
+msgid "use IPv6 in addition to IPv4"
+msgstr ""
+
+msgid "SSL certificate file"
+msgstr ""
+
+msgid "show untrusted configuration options"
+msgstr ""
+
+msgid "[-u] [NAME]..."
+msgstr ""
+
+msgid "check for push and pull"
+msgstr ""
+
+msgid "show status of all files"
+msgstr ""
+
+msgid "show only modified files"
+msgstr ""
+
+msgid "show only added files"
+msgstr ""
+
+msgid "show only removed files"
+msgstr ""
+
+msgid "show only deleted (but tracked) files"
+msgstr ""
+
+msgid "show only files without changes"
+msgstr ""
+
+msgid "show only unknown (not tracked) files"
+msgstr ""
+
+msgid "show only ignored files"
+msgstr ""
+
+msgid "show source of copied files"
+msgstr ""
+
+msgid "show difference from revision"
+msgstr ""
+
+msgid "list the changed files of a revision"
+msgstr ""
+
+msgid "replace existing tag"
+msgstr ""
+
+msgid "make the tag local"
+msgstr ""
+
+msgid "revision to tag"
+msgstr ""
+
+msgid "remove a tag"
+msgstr ""
+
+msgid "use <text> as commit message"
+msgstr ""
+
+msgid "[-f] [-l] [-m TEXT] [-d DATE] [-u USER] [-r REV] NAME..."
+msgstr ""
+
+msgid "[-p] [-g]"
+msgstr ""
+
+msgid "update to new branch head if changesets were unbundled"
+msgstr ""
+
+msgid "[-u] FILE..."
+msgstr ""
+
+msgid "discard uncommitted changes (no backup)"
+msgstr "înlătură modificările nedepozitate (fără copie de siguranță)"
+
+msgid "check for uncommitted changes"
+msgstr "verifică dacă există modificări nedepozitate"
+
+msgid "[-c] [-C] [-d DATE] [[-r] REV]"
+msgstr ""
+
+#, python-format
+msgid "cannot include %s (%s)"
+msgstr ""
+
+msgid "not found in manifest"
+msgstr "nu s-a găsit în manifest"
+
+msgid "branch name not in UTF-8!"
+msgstr ""
+
+#, python-format
+msgid "%s does not exist!\n"
+msgstr ""
+
+#, python-format
+msgid ""
+"%s: up to %d MB of RAM may be required to manage this file\n"
+"(use 'hg revert %s' to cancel the pending addition)\n"
+msgstr ""
+
+#, python-format
+msgid "%s not added: only files and symlinks supported currently\n"
+msgstr ""
+
+#, python-format
+msgid "%s already tracked!\n"
+msgstr ""
+
+#, python-format
+msgid "%s not added!\n"
+msgstr ""
+
+#, python-format
+msgid "%s still exists!\n"
+msgstr ""
+
+#, python-format
+msgid "%s not tracked!\n"
+msgstr ""
+
+#, python-format
+msgid "%s not removed!\n"
+msgstr ""
+
+#, python-format
+msgid "copy failed: %s is not a file or a symbolic link\n"
+msgstr ""
+
+#, python-format
+msgid "invalid event type in dag: %s"
+msgstr ""
+
+msgid "working directory state appears damaged!"
+msgstr ""
+
+#, python-format
+msgid "'\\n' and '\\r' disallowed in filenames: %r"
+msgstr ""
+
+#, python-format
+msgid "directory %r already in dirstate"
+msgstr ""
+
+#, python-format
+msgid "file %r in dirstate clashes with %r"
+msgstr ""
+
+#, python-format
+msgid "setting %r to other parent only allowed in merges"
+msgstr ""
+
+#, python-format
+msgid "not in dirstate: %s\n"
+msgstr ""
+
+msgid "unknown"
+msgstr ""
+
+msgid "character device"
+msgstr ""
+
+msgid "block device"
+msgstr ""
+
+msgid "fifo"
+msgstr ""
+
+msgid "socket"
+msgstr ""
+
+msgid "directory"
+msgstr ""
+
+#, python-format
+msgid "unsupported file type (type is %s)"
+msgstr ""
+
+msgid "queries"
+msgstr ""
+
+msgid "searching"
+msgstr ""
+
+msgid "already have changeset "
+msgstr ""
+
+msgid "warning: repository is unrelated\n"
+msgstr ""
+
+msgid "repository is unrelated"
+msgstr ""
+
+#, python-format
+msgid "push creates new remote branches: %s!"
+msgstr ""
+
+msgid "use 'hg push --new-branch' to create new remote branches"
+msgstr ""
+
+#, python-format
+msgid "push creates new remote heads on branch '%s'!"
+msgstr ""
+
+msgid "push creates new remote heads!"
+msgstr ""
+
+msgid "you should pull and merge or use push -f to force"
+msgstr ""
+
+msgid "did you forget to merge? use push -f to force"
+msgstr ""
+
+msgid "note: unsynced remote changes!\n"
+msgstr ""
+
+#, python-format
+msgid "abort: %s\n"
+msgstr ""
+
+#, python-format
+msgid "(%s)\n"
+msgstr ""
+
+#, python-format
+msgid "hg: parse error at %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "hg: parse error: %s\n"
+msgstr ""
+
+msgid "entering debugger - type c to continue starting hg or h for help\n"
+msgstr ""
+
+#, python-format
+msgid ""
+"hg: command '%s' is ambiguous:\n"
+"    %s\n"
+msgstr ""
+
+#, python-format
+msgid "timed out waiting for lock held by %s"
+msgstr ""
+
+#, python-format
+msgid "lock held by %s"
+msgstr ""
+
+#, python-format
+msgid "abort: %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "abort: could not lock %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "hg %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "hg: %s\n"
+msgstr ""
+
+#, python-format
+msgid "abort: %s!\n"
+msgstr ""
+
+#, python-format
+msgid "abort: %s"
+msgstr ""
+
+msgid " empty string\n"
+msgstr ""
+
+msgid "killed!\n"
+msgstr ""
+
+#, python-format
+msgid "hg: unknown command '%s'\n"
+msgstr ""
+
+msgid "(did you forget to compile extensions?)\n"
+msgstr ""
+
+msgid "(is your Python install correct?)\n"
+msgstr ""
+
+#, python-format
+msgid "abort: error: %s\n"
+msgstr ""
+
+msgid "broken pipe\n"
+msgstr ""
+
+msgid "interrupted!\n"
+msgstr ""
+
+msgid ""
+"\n"
+"broken pipe\n"
+msgstr ""
+
+msgid "abort: out of memory\n"
+msgstr ""
+
+msgid "** unknown exception encountered, details follow\n"
+msgstr ""
+
+msgid "** report bug details to http://mercurial.selenic.com/bts/\n"
+msgstr ""
+
+msgid "** or mercurial@selenic.com\n"
+msgstr ""
+
+#, python-format
+msgid "** Python %s\n"
+msgstr ""
+
+#, python-format
+msgid "** Mercurial Distributed SCM (version %s)\n"
+msgstr ""
+
+#, python-format
+msgid "** Extensions loaded: %s\n"
+msgstr ""
+
+#, python-format
+msgid "no definition for alias '%s'\n"
+msgstr "nu există nicio definiție pentru alias-ul '%s'\n"
+
+#, python-format
+msgid ""
+"error in definition for alias '%s': %s may only be given on the command "
+"line\n"
+msgstr ""
+
+#, python-format
+msgid "alias '%s' resolves to unknown command '%s'\n"
+msgstr "alias-ul '%s' corespunde comenzii necunoscute '%s'\n"
+
+#, python-format
+msgid "alias '%s' resolves to ambiguous command '%s'\n"
+msgstr "alias-ul '%s' corespunde comenzii ambigue '%s'\n"
+
+#, python-format
+msgid "malformed --config option: %r (use --config section.name=value)"
+msgstr ""
+
+#, fuzzy, python-format
+msgid "error getting current working directory: %s"
+msgstr "directorul de lucrul al %s"
+
+#, python-format
+msgid "extension '%s' overrides commands: %s\n"
+msgstr ""
+
+msgid "Option --config may not be abbreviated!"
+msgstr ""
+
+msgid "Option --cwd may not be abbreviated!"
+msgstr ""
+
+msgid ""
+"Option -R has to be separated from other options (e.g. not -qR) and --"
+"repository may only be abbreviated as --repo!"
+msgstr ""
+
+#, python-format
+msgid "Time: real %.3f secs (user %.3f+%.3f sys %.3f+%.3f)\n"
+msgstr ""
+
+#, python-format
+msgid "repository '%s' is not local"
+msgstr ""
+
+msgid "warning: --repository ignored\n"
+msgstr ""
+
+msgid "invalid arguments"
+msgstr ""
+
+#, python-format
+msgid "unrecognized profiling format '%s' - Ignored\n"
+msgstr ""
+
+msgid ""
+"lsprof not available - install from http://codespeak.net/svn/user/arigo/hack/"
+"misc/lsprof/"
+msgstr ""
+
+#, python-format
+msgid "*** failed to import extension %s from %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "*** failed to import extension %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "couldn't find merge tool %s\n"
+msgstr ""
+
+#, python-format
+msgid "tool %s can't handle symlinks\n"
+msgstr ""
+
+#, python-format
+msgid "tool %s can't handle binary\n"
+msgstr ""
+
+#, python-format
+msgid "tool %s requires a GUI\n"
+msgstr ""
+
+#, python-format
+msgid ""
+" no tool found to merge %s\n"
+"keep (l)ocal or take (o)ther?"
+msgstr ""
+
+msgid "&Local"
+msgstr ""
+
+msgid "&Other"
+msgstr ""
+
+#, python-format
+msgid "merging %s and %s to %s\n"
+msgstr ""
+
+#, python-format
+msgid "merging %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s.premerge not valid ('%s' is neither boolean nor %s)"
+msgstr ""
+
+#, python-format
+msgid "was merge of '%s' successful (yn)?"
+msgstr ""
+
+msgid "&No"
+msgstr ""
+
+msgid "&Yes"
+msgstr ""
+
+#, python-format
+msgid ""
+" output file %s appears unchanged\n"
+"was merge successful (yn)?"
+msgstr ""
+
+#, python-format
+msgid "merging %s failed!\n"
+msgstr ""
+
+#, python-format
+msgid "Inconsistent state, %s:%s is good and bad"
+msgstr ""
+
+#, python-format
+msgid "unknown bisect kind %s"
+msgstr ""
+
+msgid "disabled extensions:"
+msgstr ""
+
+msgid "Configuration Files"
+msgstr "Fișiere de configurare"
+
+msgid "Date Formats"
+msgstr "Formate de dată"
+
+msgid "File Name Patterns"
+msgstr "Șabloane pentru nume de fișiere"
+
+msgid "Environment Variables"
+msgstr "Variabile de mediu"
+
+msgid "Specifying Single Revisions"
+msgstr "Se specifică revizii simple"
+
+msgid "Specifying Multiple Revisions"
+msgstr "Se specifică revizii multiple"
+
+msgid "Specifying Revision Sets"
+msgstr ""
+
+msgid "Diff Formats"
+msgstr "Formate pentru diff"
+
+msgid "Template Usage"
+msgstr "Folosirea șablonului"
+
+msgid "URL Paths"
+msgstr "Căi URL"
+
+msgid "Using additional features"
+msgstr "Se folosesc facilități suplimentare"
+
+msgid "Configuring hgweb"
+msgstr ""
+
+msgid "Glossary"
+msgstr ""
+
+msgid ""
+"Mercurial reads configuration data from several files, if they exist.\n"
+"Below we list the most specific file first."
+msgstr ""
+
+msgid "On Windows, these configuration files are read:"
+msgstr ""
+
+msgid ""
+"- ``<repo>\\.hg\\hgrc``\n"
+"- ``%USERPROFILE%\\.hgrc``\n"
+"- ``%USERPROFILE%\\mercurial.ini``\n"
+"- ``%HOME%\\.hgrc``\n"
+"- ``%HOME%\\mercurial.ini``\n"
+"- ``C:\\mercurial\\mercurial.ini`` (unless regkey or hgrc.d\\ or mercurial."
+"ini found)\n"
+"- ``HKEY_LOCAL_MACHINE\\SOFTWARE\\Mercurial`` (unless hgrc.d\\ or mercurial."
+"ini found)\n"
+"- ``<hg.exe-dir>\\hgrc.d\\*.rc`` (unless mercurial.ini found)\n"
+"- ``<hg.exe-dir>\\mercurial.ini``"
+msgstr ""
+
+msgid "On Unix, these files are read:"
+msgstr ""
+
+msgid ""
+"- ``<repo>/.hg/hgrc``\n"
+"- ``$HOME/.hgrc``\n"
+"- ``/etc/mercurial/hgrc``\n"
+"- ``/etc/mercurial/hgrc.d/*.rc``\n"
+"- ``<install-root>/etc/mercurial/hgrc``\n"
+"- ``<install-root>/etc/mercurial/hgrc.d/*.rc``"
+msgstr ""
+
+msgid ""
+"If there is a per-repository configuration file which is not owned by\n"
+"the active user, Mercurial will warn you that the file is skipped::"
+msgstr ""
+
+msgid ""
+"  not trusting file <repo>/.hg/hgrc from untrusted user USER, group GROUP"
+msgstr ""
+
+msgid ""
+"If this bothers you, the warning can be silenced (the file would still\n"
+"be ignored) or trust can be established. Use one of the following\n"
+"settings, the syntax is explained below:"
+msgstr ""
+
+msgid ""
+"- ``ui.report_untrusted = False``\n"
+"- ``trusted.users = USER``\n"
+"- ``trusted.groups = GROUP``"
+msgstr ""
+
+msgid ""
+"The configuration files for Mercurial use a simple ini-file format. A\n"
+"configuration file consists of sections, led by a ``[section]`` header\n"
+"and followed by ``name = value`` entries::"
+msgstr ""
+
+msgid ""
+"  [ui]\n"
+"  username = Firstname Lastname <firstname.lastname@example.net>\n"
+"  verbose = True"
+msgstr ""
+
+msgid ""
+"The above entries will be referred to as ``ui.username`` and\n"
+"``ui.verbose``, respectively. Please see the hgrc man page for a full\n"
+"description of the possible configuration values:"
+msgstr ""
+
+msgid ""
+"- on Unix-like systems: ``man hgrc``\n"
+"- online: http://www.selenic.com/mercurial/hgrc.5.html\n"
+msgstr ""
+
+msgid "Some commands allow the user to specify a date, e.g.:"
+msgstr ""
+
+msgid ""
+"- backout, commit, import, tag: Specify the commit date.\n"
+"- log, revert, update: Select revision(s) by date."
+msgstr ""
+
+msgid "Many date formats are valid. Here are some examples:"
+msgstr ""
+
+msgid ""
+"- ``Wed Dec 6 13:18:29 2006`` (local timezone assumed)\n"
+"- ``Dec 6 13:18 -0600`` (year assumed, time offset provided)\n"
+"- ``Dec 6 13:18 UTC`` (UTC and GMT are aliases for +0000)\n"
+"- ``Dec 6`` (midnight)\n"
+"- ``13:18`` (today assumed)\n"
+"- ``3:39`` (3:39AM assumed)\n"
+"- ``3:39pm`` (15:39)\n"
+"- ``2006-12-06 13:18:29`` (ISO 8601 format)\n"
+"- ``2006-12-6 13:18``\n"
+"- ``2006-12-6``\n"
+"- ``12-6``\n"
+"- ``12/6``\n"
+"- ``12/6/6`` (Dec 6 2006)"
+msgstr ""
+"- ``Wed Dec 6 13:18:29 2006`` (se subînțelege 'ora locală')\n"
+"- ``Dec 6 13:18 -0600`` (se subînțelege anul, diferența de fus orar este "
+"furnizată)\n"
+"- ``Dec 6 13:18 UTC`` (UTC și GMT sunt alias-uri pentru +0000)\n"
+"- ``Dec 6`` (miezul nopții)\n"
+"- ``13:18`` (se subînțelege 'astăzi')\n"
+"- ``3:39`` (se subînțelege 3:39AM)\n"
+"- ``3:39pm`` (15:39)\n"
+"- ``2006-12-06 13:18:29`` (formatul ISO 8601)\n"
+"- ``2006-12-6 13:18``\n"
+"- ``2006-12-6``\n"
+"- ``12-6``\n"
+"- ``12/6``\n"
+"- ``12/6/6`` (Dec 6 2006)"
+
+msgid "Lastly, there is Mercurial's internal format:"
+msgstr ""
+
+msgid "- ``1165432709 0`` (Wed Dec 6 13:18:29 2006 UTC)"
+msgstr ""
+
+msgid ""
+"This is the internal representation format for dates. unixtime is the\n"
+"number of seconds since the epoch (1970-01-01 00:00 UTC). offset is\n"
+"the offset of the local timezone, in seconds west of UTC (negative if\n"
+"the timezone is east of UTC)."
+msgstr ""
+
+msgid "The log command also accepts date ranges:"
+msgstr ""
+
+msgid ""
+"- ``<{datetime}`` - at or before a given date/time\n"
+"- ``>{datetime}`` - on or after a given date/time\n"
+"- ``{datetime} to {datetime}`` - a date range, inclusive\n"
+"- ``-{days}`` - within a given number of days of today\n"
+msgstr ""
+
+msgid ""
+"Mercurial's default format for showing changes between two versions of\n"
+"a file is compatible with the unified format of GNU diff, which can be\n"
+"used by GNU patch and many other standard tools."
+msgstr ""
+
+msgid ""
+"While this standard format is often enough, it does not encode the\n"
+"following information:"
+msgstr ""
+
+msgid ""
+"- executable status and other permission bits\n"
+"- copy or rename information\n"
+"- changes in binary files\n"
+"- creation or deletion of empty files"
+msgstr ""
+
+msgid ""
+"Mercurial also supports the extended diff format from the git VCS\n"
+"which addresses these limitations. The git diff format is not produced\n"
+"by default because a few widespread tools still do not understand this\n"
+"format."
+msgstr ""
+
+msgid ""
+"This means that when generating diffs from a Mercurial repository\n"
+"(e.g. with :hg:`export`), you should be careful about things like file\n"
+"copies and renames or other things mentioned above, because when\n"
+"applying a standard diff to a different repository, this extra\n"
+"information is lost. Mercurial's internal operations (like push and\n"
+"pull) are not affected by this, because they use an internal binary\n"
+"format for communicating changes."
+msgstr ""
+
+msgid ""
+"To make Mercurial produce the git extended diff format, use the --git\n"
+"option available for many commands, or set 'git = True' in the [diff]\n"
+"section of your hgrc. You do not need to set this option when\n"
+"importing diffs in this format or using them in the mq extension.\n"
+msgstr ""
+
+msgid ""
+"HG\n"
+"    Path to the 'hg' executable, automatically passed when running\n"
+"    hooks, extensions or external tools. If unset or empty, this is\n"
+"    the hg executable's name if it's frozen, or an executable named\n"
+"    'hg' (with %PATHEXT% [defaulting to COM/EXE/BAT/CMD] extensions on\n"
+"    Windows) is searched."
+msgstr ""
+
+msgid ""
+"HGEDITOR\n"
+"    This is the name of the editor to run when committing. See EDITOR."
+msgstr ""
+
+msgid "    (deprecated, use .hgrc)"
+msgstr ""
+
+msgid ""
+"HGENCODING\n"
+"    This overrides the default locale setting detected by Mercurial.\n"
+"    This setting is used to convert data including usernames,\n"
+"    changeset descriptions, tag names, and branches. This setting can\n"
+"    be overridden with the --encoding command-line option."
+msgstr ""
+
+msgid ""
+"HGENCODINGMODE\n"
+"    This sets Mercurial's behavior for handling unknown characters\n"
+"    while transcoding user input. The default is \"strict\", which\n"
+"    causes Mercurial to abort if it can't map a character. Other\n"
+"    settings include \"replace\", which replaces unknown characters, and\n"
+"    \"ignore\", which drops them. This setting can be overridden with\n"
+"    the --encodingmode command-line option."
+msgstr ""
+
+msgid ""
+"HGMERGE\n"
+"    An executable to use for resolving merge conflicts. The program\n"
+"    will be executed with three arguments: local file, remote file,\n"
+"    ancestor file."
+msgstr ""
+
+msgid ""
+"HGRCPATH\n"
+"    A list of files or directories to search for hgrc files. Item\n"
+"    separator is \":\" on Unix, \";\" on Windows. If HGRCPATH is not set,\n"
+"    platform default search path is used. If empty, only the .hg/hgrc\n"
+"    from the current repository is read."
+msgstr ""
+
+msgid "    For each element in HGRCPATH:"
+msgstr ""
+
+msgid ""
+"    - if it's a directory, all files ending with .rc are added\n"
+"    - otherwise, the file itself will be added"
+msgstr ""
+
+msgid ""
+"HGPLAIN\n"
+"    When set, this disables any options in .hgrc that might change\n"
+"    Mercurial's default output. This includes encoding, defaults,\n"
+"    verbose mode, debug mode, quiet mode, tracebacks, and\n"
+"    localization. This can be useful when scripting against Mercurial\n"
+"    in the face of existing user configuration."
+msgstr ""
+
+msgid ""
+"    Equivalent options set via command line flags or environment\n"
+"    variables are not overridden."
+msgstr ""
+
+msgid ""
+"HGUSER\n"
+"    This is the string used as the author of a commit. If not set,\n"
+"    available values will be considered in this order:"
+msgstr ""
+
+msgid ""
+"    - HGUSER (deprecated)\n"
+"    - hgrc files from the HGRCPATH\n"
+"    - EMAIL\n"
+"    - interactive prompt\n"
+"    - LOGNAME (with ``@hostname`` appended)"
+msgstr ""
+
+msgid ""
+"EMAIL\n"
+"    May be used as the author of a commit; see HGUSER."
+msgstr ""
+
+msgid ""
+"LOGNAME\n"
+"    May be used as the author of a commit; see HGUSER."
+msgstr ""
+
+msgid ""
+"VISUAL\n"
+"    This is the name of the editor to use when committing. See EDITOR."
+msgstr ""
+
+msgid ""
+"EDITOR\n"
+"    Sometimes Mercurial needs to open a text file in an editor for a\n"
+"    user to modify, for example when writing commit messages. The\n"
+"    editor it uses is determined by looking at the environment\n"
+"    variables HGEDITOR, VISUAL and EDITOR, in that order. The first\n"
+"    non-empty one is chosen. If all of them are empty, the editor\n"
+"    defaults to 'vi'."
+msgstr ""
+
+msgid ""
+"PYTHONPATH\n"
+"    This is used by Python to find imported modules and may need to be\n"
+"    set appropriately if this Mercurial is not installed system-wide.\n"
+msgstr ""
+
+msgid ""
+"Mercurial has the ability to add new features through the use of\n"
+"extensions. Extensions may add new commands, add options to\n"
+"existing commands, change the default behavior of commands, or\n"
+"implement hooks."
+msgstr ""
+
+msgid ""
+"Extensions are not loaded by default for a variety of reasons:\n"
+"they can increase startup overhead; they may be meant for advanced\n"
+"usage only; they may provide potentially dangerous abilities (such\n"
+"as letting you destroy or modify history); they might not be ready\n"
+"for prime time; or they may alter some usual behaviors of stock\n"
+"Mercurial. It is thus up to the user to activate extensions as\n"
+"needed."
+msgstr ""
+
+msgid ""
+"To enable the \"foo\" extension, either shipped with Mercurial or in\n"
+"the Python search path, create an entry for it in your hgrc, like\n"
+"this::"
+msgstr ""
+
+msgid ""
+"  [extensions]\n"
+"  foo ="
+msgstr ""
+
+msgid "You may also specify the full path to an extension::"
+msgstr ""
+
+msgid ""
+"  [extensions]\n"
+"  myfeature = ~/.hgext/myfeature.py"
+msgstr ""
+
+msgid ""
+"To explicitly disable an extension enabled in an hgrc of broader\n"
+"scope, prepend its path with !::"
+msgstr ""
+
+msgid ""
+"  [extensions]\n"
+"  # disabling extension bar residing in /path/to/extension/bar.py\n"
+"  bar = !/path/to/extension/bar.py\n"
+"  # ditto, but no path was supplied for extension baz\n"
+"  baz = !\n"
+msgstr ""
+
+msgid ""
+"Ancestor\n"
+"    Any changeset that can be reached by an unbroken chain of parent\n"
+"    changesets from a given changeset. More precisely, the ancestors\n"
+"    of a changeset can be defined by two properties: a parent of a\n"
+"    changeset is an ancestor, and a parent of an ancestor is an\n"
+"    ancestor. See also: 'Descendant'."
+msgstr ""
+
+msgid ""
+"Branch\n"
+"    (Noun) A child changeset that has been created from a parent that\n"
+"    is not a head. These are known as topological branches, see\n"
+"    'Branch, topological'. If a topological branch is named, it becomes\n"
+"    a named branch. If a topological branch is not named, it becomes\n"
+"    an anonymous branch. See 'Branch, anonymous' and 'Branch, named'."
+msgstr ""
+
+msgid ""
+"    Branches may be created when changes are pulled from or pushed to\n"
+"    a remote repository, since new heads may be created by these\n"
+"    operations. Note that the term branch can also be used informally\n"
+"    to describe a development process in which certain development is\n"
+"    done independently of other development. This is sometimes done\n"
+"    explicitly with a named branch, but it can also be done locally,\n"
+"    using bookmarks or clones and anonymous branches."
+msgstr ""
+
+msgid "    Example: \"The experimental branch\"."
+msgstr ""
+
+msgid ""
+"    (Verb) The action of creating a child changeset which results in\n"
+"    its parent having more than one child."
+msgstr ""
+
+msgid "    Example: \"I'm going to branch at X\"."
+msgstr ""
+
+msgid ""
+"Branch, anonymous\n"
+"    Every time a new child changeset is created from a parent that is not\n"
+"    a head and the name of the branch is not changed, a new anonymous\n"
+"    branch is created."
+msgstr ""
+
+msgid ""
+"Branch, closed\n"
+"    A named branch whose branch heads have all been closed."
+msgstr ""
+
+msgid ""
+"Branch, default\n"
+"    The branch assigned to a changeset when no name has previously been\n"
+"    assigned."
+msgstr ""
+
+msgid ""
+"Branch head\n"
+"    See 'Head, branch'."
+msgstr ""
+
+msgid ""
+"Branch, named\n"
+"    A collection of changesets which have the same branch name. By\n"
+"    default, children of a changeset in a named branch belong to the\n"
+"    same named branch. A child can be explicitly assigned to a\n"
+"    different branch. See :hg:`help branch`, :hg:`help branches` and\n"
+"    :hg:`commit --close-branch` for more information on managing\n"
+"    branches."
+msgstr ""
+
+msgid ""
+"    Named branches can be thought of as a kind of namespace, dividing\n"
+"    the collection of changesets that comprise the repository into a\n"
+"    collection of disjoint subsets. A named branch is not necessarily\n"
+"    a topological branch. If a new named branch is created from the\n"
+"    head of another named branch, or the default branch, but no\n"
+"    further changesets are added to that previous branch, then that\n"
+"    previous branch will be a branch in name only."
+msgstr ""
+
+msgid ""
+"Branch tip\n"
+"    See 'Tip, branch'."
+msgstr ""
+
+msgid ""
+"Branch, topological\n"
+"    Every time a new child changeset is created from a parent that is\n"
+"    not a head, a new topological branch is created. If a topological\n"
+"    branch is named, it becomes a named branch. If a topological\n"
+"    branch is not named, it becomes an anonymous branch of the\n"
+"    current, possibly default, branch."
+msgstr ""
+
+msgid ""
+"Changelog\n"
+"    A record of the changesets in the order in which they were added\n"
+"    to the repository. This includes details such as changeset id,\n"
+"    author, commit message, date, and list of changed files."
+msgstr ""
+
+msgid ""
+"Changeset\n"
+"    A snapshot of the state of the repository used to record a change."
+msgstr ""
+
+msgid ""
+"Changeset, child\n"
+"    The converse of parent changeset: if P is a parent of C, then C is\n"
+"    a child of P. There is no limit to the number of children that a\n"
+"    changeset may have."
+msgstr ""
+
+msgid ""
+"Changeset id\n"
+"    A SHA-1 hash that uniquely identifies a changeset. It may be\n"
+"    represented as either a \"long\" 40 hexadecimal digit string, or a\n"
+"    \"short\" 12 hexadecimal digit string."
+msgstr ""
+
+msgid ""
+"Changeset, merge\n"
+"    A changeset with two parents. This occurs when a merge is\n"
+"    committed."
+msgstr ""
+
+msgid ""
+"Changeset, parent\n"
+"    A revision upon which a child changeset is based. Specifically, a\n"
+"    parent changeset of a changeset C is a changeset whose node\n"
+"    immediately precedes C in the DAG. Changesets have at most two\n"
+"    parents."
+msgstr ""
+
+msgid ""
+"Checkout\n"
+"    (Noun) The working directory being updated to a specific\n"
+"    revision. This use should probably be avoided where possible, as\n"
+"    changeset is much more appropriate than checkout in this context."
+msgstr ""
+
+msgid "    Example: \"I'm using checkout X.\""
+msgstr ""
+
+msgid ""
+"    (Verb) Updating the working directory to a specific changeset. See\n"
+"    :hg:`help update`."
+msgstr ""
+
+msgid "    Example: \"I'm going to check out changeset X.\""
+msgstr ""
+
+msgid ""
+"Child changeset\n"
+"    See 'Changeset, child'."
+msgstr ""
+
+msgid ""
+"Close changeset\n"
+"    See 'Changeset, close'."
+msgstr ""
+
+msgid ""
+"Closed branch\n"
+"    See 'Branch, closed'."
+msgstr ""
+
+msgid ""
+"Clone\n"
+"    (Noun) An entire or partial copy of a repository. The partial\n"
+"    clone must be in the form of a revision and its ancestors."
+msgstr ""
+
+msgid "    Example: \"Is your clone up to date?\"."
+msgstr ""
+
+msgid "    (Verb) The process of creating a clone, using :hg:`clone`."
+msgstr ""
+
+msgid "    Example: \"I'm going to clone the repository\"."
+msgstr ""
+
+msgid ""
+"Closed branch head\n"
+"    See 'Head, closed branch'."
+msgstr ""
+
+msgid ""
+"Commit\n"
+"    (Noun) A synonym for changeset."
+msgstr ""
+
+msgid "    Example: \"Is the bug fixed in your recent commit?\""
+msgstr ""
+
+msgid ""
+"    (Verb) The act of recording changes to a repository. When files\n"
+"    are committed in a working directory, Mercurial finds the\n"
+"    differences between the committed files and their parent\n"
+"    changeset, creating a new changeset in the repository."
+msgstr ""
+
+msgid "    Example: \"You should commit those changes now.\""
+msgstr ""
+
+msgid ""
+"Cset\n"
+"    A common abbreviation of the term changeset."
+msgstr ""
+
+msgid ""
+"DAG\n"
+"    The repository of changesets of a distributed version control\n"
+"    system (DVCS) can be described as a directed acyclic graph (DAG),\n"
+"    consisting of nodes and edges, where nodes correspond to\n"
+"    changesets and edges imply a parent -> child relation. This graph\n"
+"    can be visualized by graphical tools such as :hg:`glog`\n"
+"    (graphlog). In Mercurial, the DAG is limited by the requirement\n"
+"    for children to have at most two parents."
+msgstr ""
+
+msgid ""
+"Default branch\n"
+"    See 'Branch, default'."
+msgstr ""
+
+msgid ""
+"Descendant\n"
+"    Any changeset that can be reached by a chain of child changesets\n"
+"    from a given changeset. More precisely, the descendants of a\n"
+"    changeset can be defined by two properties: the child of a\n"
+"    changeset is a descendant, and the child of a descendant is a\n"
+"    descendant. See also: 'Ancestor'."
+msgstr ""
+
+msgid ""
+"Diff\n"
+"    (Noun) The difference between the contents and attributes of files\n"
+"    in two changesets or a changeset and the current working\n"
+"    directory. The difference is usually represented in a standard\n"
+"    form called a \"diff\" or \"patch\". The \"git diff\" format is used\n"
+"    when the changes include copies, renames, or changes to file\n"
+"    attributes, none of which can be represented/handled by classic\n"
+"    \"diff\" and \"patch\"."
+msgstr ""
+
+msgid "    Example: \"Did you see my correction in the diff?\""
+msgstr ""
+
+msgid ""
+"    (Verb) Diffing two changesets is the action of creating a diff or\n"
+"    patch."
+msgstr ""
+
+msgid ""
+"    Example: \"If you diff with changeset X, you will see what I mean.\""
+msgstr ""
+
+msgid ""
+"Directory, working\n"
+"    The working directory represents the state of the files tracked by\n"
+"    Mercurial, that will be recorded in the next commit. The working\n"
+"    directory initially corresponds to the snapshot at an existing\n"
+"    changeset, known as the parent of the working directory. See\n"
+"    'Parent, working directory'. The state may be modified by changes\n"
+"    to the files introduced manually or by a merge. The repository\n"
+"    metadata exists in the .hg directory inside the working directory."
+msgstr ""
+
+msgid ""
+"Graph\n"
+"    See DAG and :hg:`help graphlog`."
+msgstr ""
+
+msgid ""
+"Head\n"
+"    The term 'head' may be used to refer to both a branch head or a\n"
+"    repository head, depending on the context. See 'Head, branch' and\n"
+"    'Head, repository' for specific definitions."
+msgstr ""
+
+msgid ""
+"    Heads are where development generally takes place and are the\n"
+"    usual targets for update and merge operations."
+msgstr ""
+
+msgid ""
+"Head, branch\n"
+"    A changeset with no descendants on the same named branch."
+msgstr ""
+
+msgid ""
+"Head, closed branch\n"
+"    A changeset that marks a head as no longer interesting. The closed\n"
+"    head is no longer listed by :hg:`heads`. A branch is considered\n"
+"    closed when all its heads are closed and consequently is not\n"
+"    listed by :hg:`branches`."
+msgstr ""
+
+msgid ""
+"Head, repository\n"
+"    A topological head which has not been closed."
+msgstr ""
+
+msgid ""
+"Head, topological\n"
+"    A changeset with no children in the repository."
+msgstr ""
+
+msgid ""
+"History, immutable\n"
+"    Once committed, changesets cannot be altered.  Extensions which\n"
+"    appear to change history actually create new changesets that\n"
+"    replace existing ones, and then destroy the old changesets. Doing\n"
+"    so in public repositories can result in old changesets being\n"
+"    reintroduced to the repository."
+msgstr ""
+
+msgid ""
+"History, rewriting\n"
+"    The changesets in a repository are immutable. However, extensions\n"
+"    to Mercurial can be used to alter the repository, usually in such\n"
+"    a way as to preserve changeset contents."
+msgstr ""
+
+msgid ""
+"Immutable history\n"
+"    See 'History, immutable'."
+msgstr ""
+
+msgid ""
+"Merge changeset\n"
+"    See 'Changeset, merge'."
+msgstr ""
+
+msgid ""
+"Manifest\n"
+"    Each changeset has a manifest, which is the list of files that are\n"
+"    tracked by the changeset."
+msgstr ""
+
+msgid ""
+"Merge\n"
+"    Used to bring together divergent branches of work. When you update\n"
+"    to a changeset and then merge another changeset, you bring the\n"
+"    history of the latter changeset into your working directory. Once\n"
+"    conflicts are resolved (and marked), this merge may be committed\n"
+"    as a merge changeset, bringing two branches together in the DAG."
+msgstr ""
+
+msgid ""
+"Named branch\n"
+"    See 'Branch, named'."
+msgstr ""
+
+msgid ""
+"Null changeset\n"
+"    The empty changeset. It is the parent state of newly-initialized\n"
+"    repositories and repositories with no checked out revision. It is\n"
+"    thus the parent of root changesets and the effective ancestor when\n"
+"    merging unrelated changesets. Can be specified by the alias 'null'\n"
+"    or by the changeset ID '000000000000'."
+msgstr ""
+
+msgid ""
+"Parent\n"
+"    See 'Changeset, parent'."
+msgstr ""
+
+msgid ""
+"Parent changeset\n"
+"    See 'Changeset, parent'."
+msgstr ""
+
+msgid ""
+"Parent, working directory\n"
+"    The working directory parent reflects a virtual revision which is\n"
+"    the child of the changeset (or two changesets with an uncommitted\n"
+"    merge) shown by :hg:`parents`. This is changed with\n"
+"    :hg:`update`. Other commands to see the working directory parent\n"
+"    are :hg:`summary` and :hg:`id`. Can be specified by the alias \".\"."
+msgstr ""
+
+msgid ""
+"Patch\n"
+"    (Noun) The product of a diff operation."
+msgstr ""
+
+msgid "    Example: \"I've sent you my patch.\""
+msgstr ""
+
+msgid ""
+"    (Verb) The process of using a patch file to transform one\n"
+"    changeset into another."
+msgstr ""
+
+msgid "    Example: \"You will need to patch that revision.\""
+msgstr ""
+
+msgid ""
+"Pull\n"
+"    An operation in which changesets in a remote repository which are\n"
+"    not in the local repository are brought into the local\n"
+"    repository. Note that this operation without special arguments\n"
+"    only updates the repository, it does not update the files in the\n"
+"    working directory. See :hg:`help pull`."
+msgstr ""
+
+msgid ""
+"Push\n"
+"    An operation in which changesets in a local repository which are\n"
+"    not in a remote repository are sent to the remote repository. Note\n"
+"    that this operation only adds changesets which have been committed\n"
+"    locally to the remote repository. Uncommitted changes are not\n"
+"    sent. See :hg:`help push`."
+msgstr ""
+
+msgid ""
+"Repository\n"
+"    The metadata describing all recorded states of a collection of\n"
+"    files. Each recorded state is represented by a changeset. A\n"
+"    repository is usually (but not always) found in the ``.hg``\n"
+"    subdirectory of a working directory. Any recorded state can be\n"
+"    recreated by \"updating\" a working directory to a specific\n"
+"    changeset."
+msgstr ""
+
+msgid ""
+"Repository head\n"
+"    See 'Head, repository'."
+msgstr ""
+
+msgid ""
+"Revision\n"
+"    A state of the repository at some point in time. Earlier revisions\n"
+"    can be updated to by using :hg:`update`.  See also 'Revision\n"
+"    number'; See also 'Changeset'."
+msgstr ""
+
+msgid ""
+"Revision number\n"
+"    This integer uniquely identifies a changeset in a specific\n"
+"    repository. It represents the order in which changesets were added\n"
+"    to a repository, starting with revision number 0. Note that the\n"
+"    revision number may be different in each clone of a repository. To\n"
+"    identify changesets uniquely between different clones, see\n"
+"    'Changeset id'."
+msgstr ""
+
+msgid ""
+"Revlog\n"
+"    History storage mechanism used by Mercurial. It is a form of delta\n"
+"    encoding, with occasional full revision of data followed by delta\n"
+"    of each successive revision. It includes data and an index\n"
+"    pointing to the data."
+msgstr ""
+
+msgid ""
+"Rewriting history\n"
+"    See 'History, rewriting'."
+msgstr ""
+
+msgid ""
+"Root\n"
+"    A changeset that has only the null changeset as its parent. Most\n"
+"    repositories have only a single root changeset."
+msgstr ""
+
+msgid ""
+"Tip\n"
+"    The changeset with the highest revision number. It is the changeset\n"
+"    most recently added in a repository."
+msgstr ""
+
+msgid ""
+"Tip, branch\n"
+"    The head of a given branch with the highest revision number. When\n"
+"    a branch name is used as a revision identifier, it refers to the\n"
+"    branch tip. See also 'Branch, head'. Note that because revision\n"
+"    numbers may be different in different repository clones, the\n"
+"    branch tip may be different in different cloned repositories."
+msgstr ""
+
+msgid ""
+"Update\n"
+"    (Noun) Another synonym of changeset."
+msgstr ""
+
+msgid "    Example: \"I've pushed an update\"."
+msgstr ""
+
+msgid ""
+"    (Verb) This term is usually used to describe updating the state of\n"
+"    the working directory to that of a specific changeset. See\n"
+"    :hg:`help update`."
+msgstr ""
+
+msgid "    Example: \"You should update\"."
+msgstr ""
+
+msgid ""
+"Working directory\n"
+"    See 'Directory, working'."
+msgstr ""
+
+msgid ""
+"Working directory parent\n"
+"    See 'Parent, working directory'.\n"
+msgstr ""
+
+msgid ""
+"Mercurial's internal web server, hgweb, can serve either a single\n"
+"repository, or a collection of them. In the latter case, a special\n"
+"configuration file can be used to specify the repository paths to use\n"
+"and global web configuration options."
+msgstr ""
+
+msgid ""
+"This file uses the same syntax as hgrc configuration files, but only\n"
+"the following sections are recognized:"
+msgstr ""
+
+msgid ""
+"  - web\n"
+"  - paths\n"
+"  - collections"
+msgstr ""
+
+msgid ""
+"The ``web`` section can specify all the settings described in the web\n"
+"section of the hgrc documentation."
+msgstr ""
+
+msgid ""
+"The ``paths`` section provides mappings of physical repository\n"
+"paths to virtual ones. For instance::"
+msgstr ""
+
+msgid ""
+"  [paths]\n"
+"  projects/a = /foo/bar\n"
+"  projects/b = /baz/quux\n"
+"  web/root = /real/root/*\n"
+"  / = /real/root2/*\n"
+"  virtual/root2 = /real/root2/**"
+msgstr ""
+
+msgid ""
+"- The first two entries make two repositories in different directories\n"
+"  appear under the same directory in the web interface\n"
+"- The third entry maps every Mercurial repository found in '/real/root'\n"
+"  into 'web/root'. This format is preferred over the [collections] one,\n"
+"  since using absolute paths as configuration keys is not supported on "
+"every\n"
+"  platform (especially on Windows).\n"
+"- The fourth entry is a special case mapping all repositories in\n"
+"  '/real/root2' in the root of the virtual directory.\n"
+"- The fifth entry recursively finds all repositories under the real\n"
+"  root, and maps their relative paths under the virtual root."
+msgstr ""
+
+msgid ""
+"The ``collections`` section provides mappings of trees of physical\n"
+"repositories paths to virtual ones, though the paths syntax is generally\n"
+"preferred. For instance::"
+msgstr ""
+
+msgid ""
+"  [collections]\n"
+"  /foo = /foo"
+msgstr ""
+
+msgid ""
+"Here, the left side will be stripped off all repositories found in the\n"
+"right side. Thus ``/foo/bar`` and ``foo/quux/baz`` will be listed as\n"
+"``bar`` and ``quux/baz`` respectively.\n"
+msgstr ""
+
+msgid ""
+"When Mercurial accepts more than one revision, they may be specified\n"
+"individually, or provided as a topologically continuous range,\n"
+"separated by the \":\" character."
+msgstr ""
+
+msgid ""
+"The syntax of range notation is [BEGIN]:[END], where BEGIN and END are\n"
+"revision identifiers. Both BEGIN and END are optional. If BEGIN is not\n"
+"specified, it defaults to revision number 0. If END is not specified,\n"
+"it defaults to the tip. The range \":\" thus means \"all revisions\"."
+msgstr ""
+
+msgid "If BEGIN is greater than END, revisions are treated in reverse order."
+msgstr ""
+
+msgid ""
+"A range acts as a closed interval. This means that a range of 3:5\n"
+"gives 3, 4 and 5. Similarly, a range of 9:6 gives 9, 8, 7, and 6.\n"
+msgstr ""
+
+msgid ""
+"Mercurial accepts several notations for identifying one or more files\n"
+"at a time."
+msgstr ""
+
+msgid ""
+"By default, Mercurial treats filenames as shell-style extended glob\n"
+"patterns."
+msgstr ""
+
+msgid "Alternate pattern notations must be specified explicitly."
+msgstr ""
+
+msgid ""
+"To use a plain path name without any pattern matching, start it with\n"
+"``path:``. These path names must completely match starting at the\n"
+"current repository root."
+msgstr ""
+
+msgid ""
+"To use an extended glob, start a name with ``glob:``. Globs are rooted\n"
+"at the current directory; a glob such as ``*.c`` will only match files\n"
+"in the current directory ending with ``.c``."
+msgstr ""
+
+msgid ""
+"The supported glob syntax extensions are ``**`` to match any string\n"
+"across path separators and ``{a,b}`` to mean \"a or b\"."
+msgstr ""
+
+msgid ""
+"To use a Perl/Python regular expression, start a name with ``re:``.\n"
+"Regexp pattern matching is anchored at the root of the repository."
+msgstr ""
+
+msgid "Plain examples::"
+msgstr ""
+
+msgid ""
+"  path:foo/bar   a name bar in a directory named foo in the root\n"
+"                 of the repository\n"
+"  path:path:name a file or directory named \"path:name\""
+msgstr ""
+
+msgid "Glob examples::"
+msgstr ""
+
+msgid ""
+"  glob:*.c       any name ending in \".c\" in the current directory\n"
+"  *.c            any name ending in \".c\" in the current directory\n"
+"  **.c           any name ending in \".c\" in any subdirectory of the\n"
+"                 current directory including itself.\n"
+"  foo/*.c        any name ending in \".c\" in the directory foo\n"
+"  foo/**.c       any name ending in \".c\" in any subdirectory of foo\n"
+"                 including itself."
+msgstr ""
+
+msgid "Regexp examples::"
+msgstr ""
+
+msgid ""
+"  re:.*\\.c$      any name ending in \".c\", anywhere in the repository\n"
+msgstr ""
+
+msgid "Mercurial supports several ways to specify individual revisions."
+msgstr ""
+
+msgid ""
+"A plain integer is treated as a revision number. Negative integers are\n"
+"treated as sequential offsets from the tip, with -1 denoting the tip,\n"
+"-2 denoting the revision prior to the tip, and so forth."
+msgstr ""
+
+msgid ""
+"A 40-digit hexadecimal string is treated as a unique revision\n"
+"identifier."
+msgstr ""
+
+msgid ""
+"A hexadecimal string less than 40 characters long is treated as a\n"
+"unique revision identifier and is referred to as a short-form\n"
+"identifier. A short-form identifier is only valid if it is the prefix\n"
+"of exactly one full-length identifier."
+msgstr ""
+
+msgid ""
+"Any other string is treated as a tag or branch name. A tag name is a\n"
+"symbolic name associated with a revision identifier. A branch name\n"
+"denotes the tipmost revision of that branch. Tag and branch names must\n"
+"not contain the \":\" character."
+msgstr ""
+
+msgid ""
+"The reserved name \"tip\" is a special tag that always identifies the\n"
+"most recent revision."
+msgstr ""
+
+msgid ""
+"The reserved name \"null\" indicates the null revision. This is the\n"
+"revision of an empty repository, and the parent of revision 0."
+msgstr ""
+
+msgid ""
+"The reserved name \".\" indicates the working directory parent. If no\n"
+"working directory is checked out, it is equivalent to null. If an\n"
+"uncommitted merge is in progress, \".\" is the revision of the first\n"
+"parent.\n"
+msgstr ""
+
+msgid ""
+"Mercurial supports a functional language for selecting a set of\n"
+"revisions."
+msgstr ""
+
+msgid ""
+"The language supports a number of predicates which are joined by infix\n"
+"operators. Parenthesis can be used for grouping."
+msgstr ""
+
+msgid ""
+"Identifiers such as branch names must be quoted with single or double\n"
+"quotes if they contain characters outside of\n"
+"``[._a-zA-Z0-9\\x80-\\xff]`` or if they match one of the predefined\n"
+"predicates. Special characters can be used in quoted identifiers by\n"
+"escaping them, e.g., ``\\n`` is interpreted as a newline."
+msgstr ""
+
+msgid "There is a single prefix operator:"
+msgstr ""
+
+msgid ""
+"``not x``\n"
+"  Changesets not in x. Short form is ``! x``."
+msgstr ""
+
+msgid "These are the supported infix operators:"
+msgstr ""
+
+msgid ""
+"``x::y``\n"
+"  A DAG range, meaning all changesets that are descendants of x and\n"
+"  ancestors of y, including x and y themselves. If the first endpoint\n"
+"  is left out, this is equivalent to ``ancestors(y)``, if the second\n"
+"  is left out it is equivalent to ``descendants(x)``."
+msgstr ""
+
+msgid "  An alternative syntax is ``x..y``."
+msgstr ""
+
+msgid ""
+"``x:y``\n"
+"  All changesets with revision numbers between x and y, both\n"
+"  inclusive. Either endpoint can be left out, they default to 0 and\n"
+"  tip."
+msgstr ""
+
+msgid ""
+"``x and y``\n"
+"  The intersection of changesets in x and y. Short form is ``x & y``."
+msgstr ""
+
+msgid ""
+"``x or y``\n"
+"  The union of changesets in x and y. There are two alternative short\n"
+"  forms: ``x | y`` and ``x + y``."
+msgstr ""
+
+msgid ""
+"``x - y``\n"
+"  Changesets in x but not in y."
+msgstr ""
+
+msgid "The following predicates are supported:"
+msgstr ""
+
+msgid ""
+"``adds(pattern)``\n"
+"  Changesets that add a file matching pattern."
+msgstr ""
+
+msgid ""
+"``all()``\n"
+"  All changesets, the same as ``0:tip``."
+msgstr ""
+
+msgid ""
+"``ancestor(single, single)``\n"
+"  Greatest common ancestor of the two changesets."
+msgstr ""
+
+msgid ""
+"``ancestors(set)``\n"
+"  Changesets that are ancestors of a changeset in set."
+msgstr ""
+
+msgid ""
+"``author(string)``\n"
+"  Alias for ``user(string)``."
+msgstr ""
+
+msgid ""
+"``branch(set)``\n"
+"  All changesets belonging to the branches of changesets in set."
+msgstr ""
+
+msgid ""
+"``children(set)``\n"
+"  Child changesets of changesets in set."
+msgstr ""
+
+msgid ""
+"``closed()``\n"
+"  Changeset is closed."
+msgstr ""
+
+msgid ""
+"``contains(pattern)``\n"
+"  Revision contains pattern."
+msgstr ""
+
+msgid ""
+"``date(interval)``\n"
+"  Changesets within the interval, see :hg:`help dates`."
+msgstr ""
+
+msgid ""
+"``descendants(set)``\n"
+"  Changesets which are descendants of changesets in set."
+msgstr ""
+
+msgid ""
+"``file(pattern)``\n"
+"  Changesets affecting files matched by pattern."
+msgstr ""
+
+msgid ""
+"``follow()``\n"
+"  An alias for ``::.`` (ancestors of the working copy's first parent)."
+msgstr ""
+
+msgid ""
+"``grep(regex)``\n"
+"  Like ``keyword(string)`` but accepts a regex."
+msgstr ""
+
+msgid ""
+"``head()``\n"
+"  Changeset is a head."
+msgstr ""
+
+msgid ""
+"``heads(set)``\n"
+"  Members of set with no children in set."
+msgstr ""
+
+msgid ""
+"``keyword(string)``\n"
+"  Search commit message, user name, and names of changed files for\n"
+"  string."
+msgstr ""
+
+msgid ""
+"``limit(set, n)``\n"
+"  First n members of set."
+msgstr ""
+
+msgid ""
+"``max(set)``\n"
+"  Changeset with highest revision number in set."
+msgstr ""
+
+msgid ""
+"``min(set)``\n"
+"  Changeset with lowest revision number in set."
+msgstr ""
+
+msgid ""
+"``merge()``\n"
+"  Changeset is a merge changeset."
+msgstr ""
+
+msgid ""
+"``modifies(pattern)``\n"
+"  Changesets modifying files matched by pattern."
+msgstr ""
+
+msgid ""
+"``outgoing([path])``\n"
+"  Changesets not found in the specified destination repository, or the\n"
+"  default push location."
+msgstr ""
+
+msgid ""
+"``p1(set)``\n"
+"  First parent of changesets in set."
+msgstr ""
+
+msgid ""
+"``p2(set)``\n"
+"  Second parent of changesets in set."
+msgstr ""
+
+msgid ""
+"``parents(set)``\n"
+"  The set of all parents for all changesets in set."
+msgstr ""
+
+msgid ""
+"``removes(pattern)``\n"
+"  Changesets which remove files matching pattern."
+msgstr ""
+
+msgid ""
+"``reverse(set)``\n"
+"  Reverse order of set."
+msgstr ""
+
+msgid ""
+"``roots(set)``\n"
+"  Changesets with no parent changeset in set."
+msgstr ""
+
+msgid ""
+"``sort(set[, [-]key...])``\n"
+"  Sort set by keys. The default sort order is ascending, specify a key\n"
+"  as ``-key`` to sort in descending order."
+msgstr ""
+
+msgid "  The keys can be:"
+msgstr ""
+
+msgid ""
+"  - ``rev`` for the revision number,\n"
+"  - ``branch`` for the branch name,\n"
+"  - ``desc`` for the commit message (description),\n"
+"  - ``user`` for user name (``author`` can be used as an alias),\n"
+"  - ``date`` for the commit date"
+msgstr ""
+
+msgid ""
+"``tagged()``\n"
+"  Changeset is tagged."
+msgstr ""
+
+msgid ""
+"``user(string)``\n"
+"  User name is string."
+msgstr ""
+
+msgid "Command line equivalents for :hg:`log`::"
+msgstr ""
+
+msgid ""
+"  -f    ->  ::.\n"
+"  -d x  ->  date(x)\n"
+"  -k x  ->  keyword(x)\n"
+"  -m    ->  merge()\n"
+"  -u x  ->  user(x)\n"
+"  -b x  ->  branch(x)\n"
+"  -P x  ->  !::x\n"
+"  -l x  ->  limit(expr, x)"
+msgstr ""
+
+msgid "Some sample queries::"
+msgstr ""
+
+msgid ""
+"  hg log -r 'branch(default)'\n"
+"  hg log -r 'branch(default) and 1.5:: and not merge()'\n"
+"  hg log -r '1.3::1.5 and keyword(bug) and file(\"hgext/*\")'\n"
+"  hg log -r 'sort(date(\"May 2008\"), user)'\n"
+"  hg log -r '(keyword(bug) or keyword(issue)) and not ancestors(tagged())'\n"
+msgstr ""
+
+msgid ""
+"Mercurial allows you to customize output of commands through\n"
+"templates. You can either pass in a template from the command\n"
+"line, via the --template option, or select an existing\n"
+"template-style (--style)."
+msgstr ""
+
+msgid ""
+"You can customize output for any \"log-like\" command: log,\n"
+"outgoing, incoming, tip, parents, heads and glog."
+msgstr ""
+
+msgid ""
+"Four styles are packaged with Mercurial: default (the style used\n"
+"when no explicit preference is passed), compact, changelog,\n"
+"and xml.\n"
+"Usage::"
+msgstr ""
+
+msgid "    $ hg log -r1 --style changelog"
+msgstr ""
+
+msgid ""
+"A template is a piece of text, with markup to invoke variable\n"
+"expansion::"
+msgstr ""
+
+msgid ""
+"    $ hg log -r1 --template \"{node}\\n\"\n"
+"    b56ce7b07c52de7d5fd79fb89701ea538af65746"
+msgstr ""
+
+msgid ""
+"Strings in curly braces are called keywords. The availability of\n"
+"keywords depends on the exact context of the templater. These\n"
+"keywords are usually available for templating a log-like command:"
+msgstr ""
+
+msgid ":author: String. The unmodified author of the changeset."
+msgstr ""
+
+msgid ""
+":branches: String. The name of the branch on which the changeset was\n"
+"    committed. Will be empty if the branch name was default."
+msgstr ""
+
+msgid ":children: List of strings. The children of the changeset."
+msgstr ""
+
+msgid ":date: Date information. The date when the changeset was committed."
+msgstr ""
+
+msgid ":desc: String. The text of the changeset description."
+msgstr ""
+
+msgid ""
+":diffstat: String. Statistics of changes with the following format:\n"
+"    \"modified files: +added/-removed lines\""
+msgstr ""
+
+msgid ""
+":files: List of strings. All files modified, added, or removed by this\n"
+"    changeset."
+msgstr ""
+
+msgid ":file_adds: List of strings. Files added by this changeset."
+msgstr ""
+
+msgid ""
+":file_copies: List of strings. Files copied in this changeset with\n"
+"    their sources."
+msgstr ""
+
+msgid ""
+":file_copies_switch: List of strings. Like \"file_copies\" but displayed\n"
+"    only if the --copied switch is set."
+msgstr ""
+
+msgid ":file_mods: List of strings. Files modified by this changeset."
+msgstr ""
+
+msgid ":file_dels: List of strings. Files removed by this changeset."
+msgstr ""
+
+msgid ""
+":node: String. The changeset identification hash, as a 40 hexadecimal\n"
+"    digit string."
+msgstr ""
+
+msgid ":parents: List of strings. The parents of the changeset."
+msgstr ""
+
+msgid ":rev: Integer. The repository-local changeset revision number."
+msgstr ""
+
+msgid ":tags: List of strings. Any tags associated with the changeset."
+msgstr ""
+
+msgid ""
+":latesttag: String. Most recent global tag in the ancestors of this\n"
+"    changeset."
+msgstr ""
+
+msgid ":latesttagdistance: Integer. Longest path to the latest tag."
+msgstr ""
+
+msgid ""
+"The \"date\" keyword does not produce human-readable output. If you\n"
+"want to use a date in your output, you can use a filter to process\n"
+"it. Filters are functions which return a string based on the input\n"
+"variable. Be sure to use the stringify filter first when you're\n"
+"applying a string-input filter to a list-like input variable.\n"
+"You can also use a chain of filters to get the desired output::"
+msgstr ""
+
+msgid ""
+"   $ hg tip --template \"{date|isodate}\\n\"\n"
+"   2008-08-21 18:22 +0000"
+msgstr ""
+
+msgid "List of filters:"
+msgstr ""
+
+msgid ""
+":addbreaks: Any text. Add an XHTML \"<br />\" tag before the end of\n"
+"    every line except the last."
+msgstr ""
+
+msgid ""
+":age: Date. Returns a human-readable date/time difference between the\n"
+"    given date/time and the current date/time."
+msgstr ""
+
+msgid ""
+":basename: Any text. Treats the text as a path, and returns the last\n"
+"    component of the path after splitting by the path separator\n"
+"    (ignoring trailing separators). For example, \"foo/bar/baz\" becomes\n"
+"    \"baz\" and \"foo/bar//\" becomes \"bar\"."
+msgstr ""
+
+msgid ""
+":stripdir: Treat the text as path and strip a directory level, if\n"
+"    possible. For example, \"foo\" and \"foo/bar\" becomes \"foo\"."
+msgstr ""
+
+msgid ""
+":date: Date. Returns a date in a Unix date format, including the\n"
+"    timezone: \"Mon Sep 04 15:13:13 2006 0700\"."
+msgstr ""
+
+msgid ""
+":domain: Any text. Finds the first string that looks like an email\n"
+"    address, and extracts just the domain component. Example: ``User\n"
+"    <user@example.com>`` becomes ``example.com``."
+msgstr ""
+
+msgid ""
+":email: Any text. Extracts the first string that looks like an email\n"
+"    address. Example: ``User <user@example.com>`` becomes\n"
+"    ``user@example.com``."
+msgstr ""
+
+msgid ""
+":escape: Any text. Replaces the special XML/XHTML characters \"&\", \"<\"\n"
+"    and \">\" with XML entities."
+msgstr ""
+
+msgid ":fill68: Any text. Wraps the text to fit in 68 columns."
+msgstr ""
+
+msgid ":fill76: Any text. Wraps the text to fit in 76 columns."
+msgstr ""
+
+msgid ":firstline: Any text. Returns the first line of text."
+msgstr ""
+
+msgid ":nonempty: Any text. Returns '(none)' if the string is empty."
+msgstr ""
+
+msgid ""
+":hgdate: Date. Returns the date as a pair of numbers: \"1157407993\n"
+"    25200\" (Unix timestamp, timezone offset)."
+msgstr ""
+
+msgid ""
+":isodate: Date. Returns the date in ISO 8601 format: \"2009-08-18 13:00\n"
+"    +0200\"."
+msgstr ""
+
+msgid ""
+":isodatesec: Date. Returns the date in ISO 8601 format, including\n"
+"    seconds: \"2009-08-18 13:00:13 +0200\". See also the rfc3339date\n"
+"    filter."
+msgstr ""
+
+msgid ":localdate: Date. Converts a date to local date."
+msgstr ""
+
+msgid ""
+":obfuscate: Any text. Returns the input text rendered as a sequence of\n"
+"    XML entities."
+msgstr ""
+
+msgid ":person: Any text. Returns the text before an email address."
+msgstr ""
+
+msgid ""
+":rfc822date: Date. Returns a date using the same format used in email\n"
+"    headers: \"Tue, 18 Aug 2009 13:00:13 +0200\"."
+msgstr ""
+
+msgid ""
+":rfc3339date: Date. Returns a date using the Internet date format\n"
+"    specified in RFC 3339: \"2009-08-18T13:00:13+02:00\"."
+msgstr ""
+
+msgid ""
+":short: Changeset hash. Returns the short form of a changeset hash,\n"
+"    i.e. a 12 hexadecimal digit string."
+msgstr ""
+
+msgid ":shortdate: Date. Returns a date like \"2006-09-18\"."
+msgstr ""
+
+msgid ":strip: Any text. Strips all leading and trailing whitespace."
+msgstr ""
+
+msgid ""
+":tabindent: Any text. Returns the text, with every line except the\n"
+"     first starting with a tab character."
+msgstr ""
+
+msgid ""
+":urlescape: Any text. Escapes all \"special\" characters. For example,\n"
+"    \"foo bar\" becomes \"foo%20bar\"."
+msgstr ""
+
+msgid ":user: Any text. Returns the user portion of an email address.\n"
+msgstr ""
+
+msgid "Valid URLs are of the form::"
+msgstr ""
+
+msgid ""
+"  local/filesystem/path[#revision]\n"
+"  file://local/filesystem/path[#revision]\n"
+"  http://[user[:pass]@]host[:port]/[path][#revision]\n"
+"  https://[user[:pass]@]host[:port]/[path][#revision]\n"
+"  ssh://[user[:pass]@]host[:port]/[path][#revision]"
+msgstr ""
+
+msgid ""
+"Paths in the local filesystem can either point to Mercurial\n"
+"repositories or to bundle files (as created by :hg:`bundle` or :hg:`\n"
+"incoming --bundle`)."
+msgstr ""
+
+msgid ""
+"An optional identifier after # indicates a particular branch, tag, or\n"
+"changeset to use from the remote repository. See also :hg:`help\n"
+"revisions`."
+msgstr ""
+
+msgid ""
+"Some features, such as pushing to http:// and https:// URLs are only\n"
+"possible if the feature is explicitly enabled on the remote Mercurial\n"
+"server."
+msgstr ""
+
+msgid "Some notes about using SSH with Mercurial:"
+msgstr ""
+
+msgid ""
+"- SSH requires an accessible shell account on the destination machine\n"
+"  and a copy of hg in the remote path or specified with as remotecmd.\n"
+"- path is relative to the remote user's home directory by default. Use\n"
+"  an extra slash at the start of a path to specify an absolute path::"
+msgstr ""
+
+msgid "    ssh://example.com//tmp/repository"
+msgstr ""
+
+msgid ""
+"- Mercurial doesn't use its own compression via SSH; the right thing\n"
+"  to do is to configure it in your ~/.ssh/config, e.g.::"
+msgstr ""
+
+msgid ""
+"    Host *.mylocalnetwork.example.com\n"
+"      Compression no\n"
+"    Host *\n"
+"      Compression yes"
+msgstr ""
+
+msgid ""
+"  Alternatively specify \"ssh -C\" as your ssh command in your hgrc or\n"
+"  with the --ssh command line option."
+msgstr ""
+
+msgid ""
+"These URLs can all be stored in your hgrc with path aliases under the\n"
+"[paths] section like so::"
+msgstr ""
+
+msgid ""
+"  [paths]\n"
+"  alias1 = URL1\n"
+"  alias2 = URL2\n"
+"  ..."
+msgstr ""
+
+msgid ""
+"You can then use the alias for any command that uses a URL (for\n"
+"example :hg:`pull alias1` will be treated as :hg:`pull URL1`)."
+msgstr ""
+
+msgid ""
+"Two path aliases are special because they are used as defaults when\n"
+"you do not provide the URL to a command:"
+msgstr ""
+
+msgid ""
+"default:\n"
+"  When you create a repository with hg clone, the clone command saves\n"
+"  the location of the source repository as the new repository's\n"
+"  'default' path. This is then used when you omit path from push- and\n"
+"  pull-like commands (including incoming and outgoing)."
+msgstr ""
+
+msgid ""
+"default-push:\n"
+"  The push command will look for a path named 'default-push', and\n"
+"  prefer it over 'default' if both are defined.\n"
+msgstr ""
+
+msgid "remote branch lookup not supported"
+msgstr ""
+
+msgid "dirstate branch not accessible"
+msgstr ""
+
+#, python-format
+msgid "unknown branch '%s'"
+msgstr ""
+
+msgid "can only share local repositories"
+msgstr ""
+
+msgid "destination already exists"
+msgstr ""
+
+msgid "updating working directory\n"
+msgstr ""
+
+#, python-format
+msgid "destination directory: %s\n"
+msgstr ""
+
+#, python-format
+msgid "destination '%s' already exists"
+msgstr ""
+
+#, python-format
+msgid "destination '%s' is not empty"
+msgstr ""
+
+msgid ""
+"src repository does not support revision lookup and so doesn't support clone "
+"by revision"
+msgstr ""
+
+msgid "clone from remote to remote not supported"
+msgstr ""
+
+#, python-format
+msgid "updating to branch %s\n"
+msgstr ""
+
+#, python-format
+msgid ""
+"%d files updated, %d files merged, %d files removed, %d files unresolved\n"
+msgstr ""
+
+msgid "use 'hg resolve' to retry unresolved file merges\n"
+msgstr ""
+
+msgid ""
+"use 'hg resolve' to retry unresolved file merges or 'hg update -C' to "
+"abandon\n"
+msgstr ""
+
+msgid "(branch merge, don't forget to commit)\n"
+msgstr ""
+
+#, python-format
+msgid "error reading %s/.hg/hgrc: %s\n"
+msgstr ""
+
+msgid "SSL support is unavailable"
+msgstr ""
+
+msgid "IPv6 is not available on this system"
+msgstr ""
+
+#, python-format
+msgid "cannot start server at '%s:%d': %s"
+msgstr ""
+
+#, python-format
+msgid "calling hook %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s hook is invalid (\"%s\" not in a module)"
+msgstr ""
+
+msgid "exception from first failed import attempt:\n"
+msgstr ""
+
+msgid "exception from second failed import attempt:\n"
+msgstr ""
+
+#, python-format
+msgid "%s hook is invalid (import of \"%s\" failed)"
+msgstr ""
+
+#, python-format
+msgid "%s hook is invalid (\"%s\" is not defined)"
+msgstr ""
+
+#, python-format
+msgid "%s hook is invalid (\"%s\" is not callable)"
+msgstr ""
+
+#, python-format
+msgid "error: %s hook failed: %s\n"
+msgstr ""
+
+#, python-format
+msgid "error: %s hook raised an exception: %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s hook failed"
+msgstr ""
+
+#, python-format
+msgid "warning: %s hook failed\n"
+msgstr ""
+
+#, python-format
+msgid "running hook %s: %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s hook %s"
+msgstr ""
+
+#, python-format
+msgid "warning: %s hook %s\n"
+msgstr ""
+
+msgid "connection ended unexpectedly"
+msgstr ""
+
+#, python-format
+msgid "unsupported URL component: \"%s\""
+msgstr ""
+
+msgid "operation not supported over http"
+msgstr ""
+
+msgid "authorization failed"
+msgstr ""
+
+msgid "http error, possibly caused by proxy setting"
+msgstr ""
+
+#, python-format
+msgid "real URL is %s\n"
+msgstr ""
+
+#, python-format
+msgid ""
+"'%s' does not appear to be an hg repository:\n"
+"---%%<--- (%s)\n"
+"%s\n"
+"---%%<---\n"
+msgstr ""
+
+#, python-format
+msgid "'%s' sent a broken Content-Type header (%s)"
+msgstr ""
+
+#, python-format
+msgid "'%s' uses newer protocol %s"
+msgstr ""
+
+#, python-format
+msgid "push failed: %s"
+msgstr ""
+
+msgid "Python support for SSL and HTTPS is not installed"
+msgstr ""
+
+msgid "cannot create new http repository"
+msgstr ""
+
+#, python-format
+msgid "ignoring invalid syntax '%s'"
+msgstr ""
+
+#, python-format
+msgid "skipping unreadable ignore file '%s': %s\n"
+msgstr ""
+
+#, python-format
+msgid "repository %s not found"
+msgstr "depozitul %s nu a fost găsit"
+
+#, python-format
+msgid "repository %s already exists"
+msgstr "depozitul %s există deja"
+
+#, python-format
+msgid "requirement '%s' not supported"
+msgstr ""
+
+#, python-format
+msgid ".hg/sharedpath points to nonexistent directory %s"
+msgstr ""
+
+#, python-format
+msgid "%r cannot be used in a tag name"
+msgstr ""
+
+#, python-format
+msgid "warning: tag %s conflicts with existing branch name\n"
+msgstr ""
+
+msgid "working copy of .hgtags is changed (please commit .hgtags manually)"
+msgstr ""
+
+#, python-format
+msgid "working directory has unknown parent '%s'!"
+msgstr ""
+
+#, python-format
+msgid "unknown revision '%s'"
+msgstr ""
+
+msgid "abandoned transaction found - run hg recover"
+msgstr ""
+
+msgid "rolling back interrupted transaction\n"
+msgstr ""
+
+msgid "no interrupted transaction available\n"
+msgstr ""
+
+#, python-format
+msgid "rolling back to revision %s (undo %s: %s)\n"
+msgstr ""
+
+#, python-format
+msgid "rolling back to revision %s (undo %s)\n"
+msgstr ""
+
+msgid "rolling back unknown transaction\n"
+msgstr ""
+
+#, python-format
+msgid "Named branch could not be reset, current branch still is: %s\n"
+msgstr ""
+
+msgid "no rollback information available\n"
+msgstr ""
+
+#, python-format
+msgid "waiting for lock on %s held by %r\n"
+msgstr ""
+
+#, python-format
+msgid "repository %s"
+msgstr "depozitul %s"
+
+#, python-format
+msgid "working directory of %s"
+msgstr "directorul de lucrul al %s"
+
+msgid "cannot partially commit a merge (do not specify files or patterns)"
+msgstr ""
+
+msgid "can't commit subrepos without .hgsub"
+msgstr ""
+
+msgid "file not found!"
+msgstr ""
+
+msgid "no match under directory!"
+msgstr ""
+
+msgid "file not tracked!"
+msgstr ""
+
+msgid "unresolved merge conflicts (see hg resolve)"
+msgstr ""
+
+#, python-format
+msgid "committing subrepository %s\n"
+msgstr ""
+
+#, python-format
+msgid "note: commit message saved in %s\n"
+msgstr ""
+
+#, python-format
+msgid "trouble committing %s!\n"
+msgstr ""
+
+msgid "requesting all changes\n"
+msgstr "se solicită toate modificările\n"
+
+msgid ""
+"Partial pull cannot be done because other repository doesn't support "
+"changegroupsubset."
+msgstr ""
+
+#, python-format
+msgid "%d changesets found\n"
+msgstr ""
+
+msgid "bundling changes"
+msgstr ""
+
+msgid "chunks"
+msgstr ""
+
+msgid "bundling manifests"
+msgstr ""
+
+#, python-format
+msgid "empty or missing revlog for %s"
+msgstr ""
+
+msgid "bundling files"
+msgstr ""
+
+msgid "adding changesets\n"
+msgstr "se adaugă seturile de modificări\n"
+
+msgid "changesets"
+msgstr ""
+
+msgid "received changelog group is empty"
+msgstr ""
+
+msgid "adding manifests\n"
+msgstr "se adaugă manifestele\n"
+
+msgid "manifests"
+msgstr ""
+
+msgid "adding file changes\n"
+msgstr "se adaugă modificările fișierelor\n"
+
+msgid "received file revlog group is empty"
+msgstr ""
+
+#, python-format
+msgid "missing file data for %s:%s - run hg verify"
+msgstr ""
+
+#, python-format
+msgid " (%+d heads)"
+msgstr "(%+d capete)"
+
+#, python-format
+msgid "added %d changesets with %d changes to %d files%s\n"
+msgstr ""
+"au fost adăugate %d seturi de modificări, conținând %d modificări în %d "
+"fișiere%s\n"
+
+msgid "Unexpected response from remote server:"
+msgstr ""
+
+msgid "operation forbidden by server"
+msgstr ""
+
+msgid "locking the remote repository failed"
+msgstr ""
+
+msgid "the server sent an unknown error code"
+msgstr ""
+
+msgid "streaming all changes\n"
+msgstr ""
+
+#, python-format
+msgid "%d files to transfer, %s of data\n"
+msgstr ""
+
+#, python-format
+msgid "transferred %s in %.1f seconds (%s/sec)\n"
+msgstr ""
+
+msgid "no [smtp]host in hgrc - cannot send mail"
+msgstr ""
+
+#, python-format
+msgid "sending mail: smtp host %s, port %s\n"
+msgstr ""
+
+msgid "can't use TLS: Python SSL support not installed"
+msgstr ""
+
+msgid "(using tls)\n"
+msgstr ""
+
+#, python-format
+msgid "(authenticating to mail server as %s)\n"
+msgstr ""
+
+#, python-format
+msgid "sending mail: %s\n"
+msgstr ""
+
+msgid "smtp specified as email transport, but no smtp host configured"
+msgstr ""
+
+#, python-format
+msgid "%r specified as email transport, but not in PATH"
+msgstr ""
+
+#, python-format
+msgid "ignoring invalid sendcharset: %s\n"
+msgstr ""
+
+#, python-format
+msgid "invalid email address: %s"
+msgstr ""
+
+#, python-format
+msgid "invalid local address: %s"
+msgstr ""
+
+#, python-format
+msgid "failed to remove %s from manifest"
+msgstr ""
+
+#, python-format
+msgid "diff context lines count must be an integer, not %r"
+msgstr ""
+
+#, python-format
+msgid ""
+"untracked file in working directory differs from file in requested revision: "
+"'%s'"
+msgstr ""
+
+#, python-format
+msgid "case-folding collision between %s and %s"
+msgstr ""
+
+#, python-format
+msgid ""
+" conflicting flags for %s\n"
+"(n)one, e(x)ec or sym(l)ink?"
+msgstr ""
+
+msgid "&None"
+msgstr ""
+
+msgid "E&xec"
+msgstr ""
+
+msgid "Sym&link"
+msgstr ""
+
+msgid "resolving manifests\n"
+msgstr "se determină manifestele\n"
+
+#, python-format
+msgid ""
+" local changed %s which remote deleted\n"
+"use (c)hanged version or (d)elete?"
+msgstr ""
+
+msgid "&Changed"
+msgstr ""
+
+msgid "&Delete"
+msgstr ""
+
+#, python-format
+msgid ""
+"remote changed %s which local deleted\n"
+"use (c)hanged version or leave (d)eleted?"
+msgstr ""
+
+msgid "&Deleted"
+msgstr ""
+
+msgid "updating"
+msgstr ""
+
+#, python-format
+msgid "update failed to remove %s: %s!\n"
+msgstr ""
+
+#, python-format
+msgid "getting %s\n"
+msgstr "se primește %s\n"
+
+#, python-format
+msgid "getting %s to %s\n"
+msgstr "se primește %s în %s\n"
+
+#, python-format
+msgid "warning: detected divergent renames of %s to:\n"
+msgstr ""
+
+#, python-format
+msgid "branch %s not found"
+msgstr ""
+
+msgid "merging with a working directory ancestor has no effect"
+msgstr ""
+
+msgid "nothing to merge (use 'hg update' or check 'hg heads')"
+msgstr ""
+
+msgid "outstanding uncommitted changes (use 'hg status' to list changes)"
+msgstr ""
+
+msgid ""
+"crosses branches (use 'hg merge' to merge or use 'hg update -C' to discard "
+"changes)"
+msgstr ""
+
+msgid "crosses branches (use 'hg merge' or use 'hg update -c')"
+msgstr ""
+
+#, python-format
+msgid "cannot create %s: destination already exists"
+msgstr ""
+
+#, python-format
+msgid "cannot create %s: unable to create destination directory"
+msgstr ""
+
+#, python-format
+msgid "unable to find '%s' for patching\n"
+msgstr ""
+
+#, python-format
+msgid "patching file %s\n"
+msgstr ""
+
+#, python-format
+msgid "%d out of %d hunks FAILED -- saving rejects to file %s\n"
+msgstr ""
+
+#, python-format
+msgid "bad hunk #%d %s (%d %d %d %d)"
+msgstr ""
+
+#, python-format
+msgid "file %s already exists\n"
+msgstr ""
+
+#, python-format
+msgid "Hunk #%d succeeded at %d with fuzz %d (offset %d lines).\n"
+msgstr ""
+
+#, python-format
+msgid "Hunk #%d succeeded at %d (offset %d lines).\n"
+msgstr ""
+
+#, python-format
+msgid "Hunk #%d FAILED at %d\n"
+msgstr ""
+
+#, python-format
+msgid "bad hunk #%d"
+msgstr ""
+
+#, python-format
+msgid "bad hunk #%d old text line %d"
+msgstr ""
+
+msgid "could not extract binary patch"
+msgstr ""
+
+#, python-format
+msgid "binary patch is %d bytes, not %d"
+msgstr ""
+
+#, python-format
+msgid "unable to strip away %d of %d dirs from %s"
+msgstr ""
+
+msgid "undefined source and destination files"
+msgstr ""
+
+#, python-format
+msgid "malformed patch %s %s"
+msgstr ""
+
+#, python-format
+msgid "unsupported parser state: %s"
+msgstr ""
+
+#, python-format
+msgid "patch command failed: %s"
+msgstr ""
+
+#, python-format
+msgid "Unsupported line endings type: %s"
+msgstr ""
+
+msgid ""
+"internal patcher failed\n"
+"please report details to http://mercurial.selenic.com/bts/\n"
+"or mercurial@selenic.com\n"
+msgstr ""
+
+#, python-format
+msgid " %d files changed, %d insertions(+), %d deletions(-)\n"
+msgstr ""
+
+#, python-format
+msgid "exited with status %d"
+msgstr ""
+
+#, python-format
+msgid "killed by signal %d"
+msgstr ""
+
+#, python-format
+msgid "saved backup bundle to %s\n"
+msgstr ""
+
+msgid "adding branch\n"
+msgstr "se adaugă ramura\n"
+
+#, python-format
+msgid "strip failed, full bundle stored in '%s'\n"
+msgstr ""
+
+#, python-format
+msgid "strip failed, partial bundle stored in '%s'\n"
+msgstr ""
+
+#, python-format
+msgid "cannot %s; remote repository does not support the %r capability"
+msgstr ""
+
+#, python-format
+msgid "unknown compression type %r"
+msgstr ""
+
+msgid "index entry flags need RevlogNG"
+msgstr ""
+
+#, python-format
+msgid "index %s unknown flags %#04x for format v0"
+msgstr ""
+
+#, python-format
+msgid "index %s unknown flags %#04x for revlogng"
+msgstr ""
+
+#, python-format
+msgid "index %s unknown format %d"
+msgstr ""
+
+#, python-format
+msgid "index %s is corrupted"
+msgstr ""
+
+msgid "no node"
+msgstr ""
+
+msgid "ambiguous identifier"
+msgstr ""
+
+msgid "no match found"
+msgstr ""
+
+#, python-format
+msgid "incompatible revision flag %x"
+msgstr ""
+
+#, python-format
+msgid "%s not found in the transaction"
+msgstr ""
+
+msgid "unknown base"
+msgstr ""
+
+msgid "consistency error adding group"
+msgstr "eroare de consistență la adăugarea grupului"
+
+msgid "unterminated string"
+msgstr ""
+
+msgid "syntax error"
+msgstr ""
+
+msgid "missing argument"
+msgstr ""
+
+#, python-format
+msgid "can't use %s here"
+msgstr ""
+
+msgid "can't use a list in this context"
+msgstr ""
+
+#, python-format
+msgid "not a function: %s"
+msgstr ""
+
+msgid "limit wants two arguments"
+msgstr ""
+
+msgid "limit wants a number"
+msgstr ""
+
+msgid "limit expects a number"
+msgstr ""
+
+msgid "ancestor wants two arguments"
+msgstr ""
+
+msgid "ancestor arguments must be single revisions"
+msgstr ""
+
+msgid "follow takes no arguments"
+msgstr ""
+
+msgid "date wants a string"
+msgstr ""
+
+msgid "keyword wants a string"
+msgstr ""
+
+msgid "grep wants a string"
+msgstr ""
+
+msgid "author wants a string"
+msgstr ""
+
+msgid "file wants a pattern"
+msgstr ""
+
+msgid "contains wants a pattern"
+msgstr ""
+
+msgid "modifies wants a pattern"
+msgstr ""
+
+msgid "adds wants a pattern"
+msgstr ""
+
+msgid "removes wants a pattern"
+msgstr ""
+
+msgid "merge takes no arguments"
+msgstr ""
+
+msgid "closed takes no arguments"
+msgstr ""
+
+msgid "head takes no arguments"
+msgstr ""
+
+msgid "sort wants one or two arguments"
+msgstr ""
+
+msgid "sort spec must be a string"
+msgstr ""
+
+#, python-format
+msgid "unknown sort key %r"
+msgstr ""
+
+msgid "all takes no arguments"
+msgstr ""
+
+msgid "outgoing wants a repository path"
+msgstr ""
+
+msgid "tagged takes no arguments"
+msgstr ""
+
+msgid "can't negate that"
+msgstr ""
+
+msgid "not a symbol"
+msgstr ""
+
+msgid "empty query"
+msgstr ""
+
+msgid "searching for exact renames"
+msgstr ""
+
+msgid "searching for similar files"
+msgstr ""
+
+#, python-format
+msgid "%s looks like a binary file."
+msgstr ""
+
+msgid "can only specify two labels."
+msgstr ""
+
+msgid "warning: conflicts during merge.\n"
+msgstr ""
+
+#, python-format
+msgid "couldn't parse location %s"
+msgstr ""
+
+msgid "could not create remote repo"
+msgstr ""
+
+msgid "no suitable response from remote hg"
+msgstr ""
+
+msgid "remote: "
+msgstr ""
+
+msgid "unexpected response:"
+msgstr ""
+
+#, python-format
+msgid "push refused: %s"
+msgstr ""
+
+#, python-format
+msgid "'%s' does not appear to be an hg repository"
+msgstr ""
+
+msgid "cannot lock static-http repository"
+msgstr ""
+
+msgid "cannot create new static-http repository"
+msgstr ""
+
+#, python-format
+msgid "invalid entry in fncache, line %s"
+msgstr ""
+
+#, python-format
+msgid "subrepo spec file %s not found"
+msgstr ""
+
+msgid "missing ] in subrepo source"
+msgstr ""
+
+#, python-format
+msgid ""
+" subrepository sources for %s differ\n"
+"use (l)ocal source (%s) or (r)emote source (%s)?"
+msgstr ""
+
+msgid "&Remote"
+msgstr ""
+
+#, python-format
+msgid ""
+" local changed subrepository %s which remote removed\n"
+"use (c)hanged version or (d)elete?"
+msgstr ""
+
+#, python-format
+msgid ""
+" remote changed subrepository %s which local removed\n"
+"use (c)hanged version or (d)elete?"
+msgstr ""
+
+#, python-format
+msgid "unknown subrepo type %s"
+msgstr ""
+
+#, python-format
+msgid "removing subrepo %s\n"
+msgstr ""
+
+#, python-format
+msgid "pulling subrepo %s from %s\n"
+msgstr ""
+
+#, python-format
+msgid "pushing subrepo %s to %s\n"
+msgstr ""
+
+msgid "cannot commit svn externals"
+msgstr ""
+
+#, python-format
+msgid "not removing repo %s because it has changes.\n"
+msgstr ""
+
+#, python-format
+msgid "%s, line %s: %s\n"
+msgstr ""
+
+msgid "cannot parse entry"
+msgstr ""
+
+#, python-format
+msgid "node '%s' is not well formed"
+msgstr ""
+
+msgid "unmatched quotes"
+msgstr ""
+
+#, python-format
+msgid "error expanding '%s%%%s'"
+msgstr ""
+
+#, python-format
+msgid "unknown filter '%s'"
+msgstr ""
+
+#, python-format
+msgid "style not found: %s"
+msgstr ""
+
+#, python-format
+msgid "template file %s: %s"
+msgstr ""
+
+msgid "cannot use transaction when it is already committed/aborted"
+msgstr ""
+
+#, python-format
+msgid "failed to truncate %s\n"
+msgstr ""
+
+msgid "transaction abort!\n"
+msgstr ""
+
+msgid "rollback completed\n"
+msgstr ""
+
+msgid "rollback failed - please run hg recover\n"
+msgstr ""
+
+#, python-format
+msgid "Not trusting file %s from untrusted user %s, group %s\n"
+msgstr ""
+
+#, python-format
+msgid "Ignored: %s\n"
+msgstr ""
+
+#, python-format
+msgid "ignoring untrusted configuration option %s.%s = %s\n"
+msgstr ""
+
+#, python-format
+msgid "%s.%s not a boolean ('%s')"
+msgstr ""
+
+msgid "enter a commit username:"
+msgstr ""
+
+#, python-format
+msgid "No username found, using '%s' instead\n"
+msgstr ""
+
+msgid "no username supplied (see \"hg help config\")"
+msgstr ""
+
+#, python-format
+msgid "username %s contains a newline\n"
+msgstr ""
+
+#, python-format
+msgid "(deprecated '%%' in path %s=%s from %s)\n"
+msgstr ""
+
+msgid "response expected"
+msgstr ""
+
+msgid "unrecognized response\n"
+msgstr ""
+
+msgid "password: "
+msgstr ""
+
+msgid "edit failed"
+msgstr ""
+
+msgid "http authorization required"
+msgstr ""
+
+msgid "http authorization required\n"
+msgstr ""
+
+#, python-format
+msgid "realm: %s\n"
+msgstr ""
+
+#, python-format
+msgid "user: %s\n"
+msgstr ""
+
+msgid "user:"
+msgstr ""
+
+#, python-format
+msgid "http auth: user %s, password %s\n"
+msgstr ""
+
+#, python-format
+msgid "ignoring invalid [auth] key '%s'\n"
+msgstr ""
+
+msgid "certificate checking requires Python 2.6"
+msgstr "verificarea certificatului necesită Python 2.6"
+
+msgid "server identity verification succeeded\n"
+msgstr ""
+
+#, python-format
+msgid "command '%s' failed: %s"
+msgstr ""
+
+#, python-format
+msgid "path contains illegal component: %s"
+msgstr ""
+
+#, python-format
+msgid "path %r is inside repo %r"
+msgstr ""
+
+#, python-format
+msgid "path %r traverses symbolic link %r"
+msgstr ""
+
+msgid "Hardlinks not supported"
+msgstr ""
+
+#, python-format
+msgid "could not symlink to %r: %s"
+msgstr ""
+
+#, python-format
+msgid "invalid date: %r "
+msgstr ""
+
+#, python-format
+msgid "date exceeds 32 bits: %d"
+msgstr ""
+
+#, python-format
+msgid "impossible time zone offset: %d"
+msgstr ""
+
+#, python-format
+msgid "invalid day spec: %s"
+msgstr ""
+
+#, python-format
+msgid "%.0f GB"
+msgstr ""
+
+#, python-format
+msgid "%.1f GB"
+msgstr ""
+
+#, python-format
+msgid "%.2f GB"
+msgstr ""
+
+#, python-format
+msgid "%.0f MB"
+msgstr ""
+
+#, python-format
+msgid "%.1f MB"
+msgstr ""
+
+#, python-format
+msgid "%.2f MB"
+msgstr ""
+
+#, python-format
+msgid "%.0f KB"
+msgstr ""
+
+#, python-format
+msgid "%.1f KB"
+msgstr ""
+
+#, python-format
+msgid "%.2f KB"
+msgstr ""
+
+#, python-format
+msgid "%.0f bytes"
+msgstr ""
+
+msgid "cannot verify bundle or remote repos"
+msgstr ""
+
+msgid "interrupted"
+msgstr ""
+
+#, python-format
+msgid "empty or missing %s"
+msgstr ""
+
+#, python-format
+msgid "data length off by %d bytes"
+msgstr ""
+
+#, python-format
+msgid "index contains %d extra bytes"
+msgstr ""
+
+#, python-format
+msgid "warning: `%s' uses revlog format 1"
+msgstr ""
+
+#, python-format
+msgid "warning: `%s' uses revlog format 0"
+msgstr ""
+
+#, python-format
+msgid "rev %d points to nonexistent changeset %d"
+msgstr ""
+
+#, python-format
+msgid "rev %d points to unexpected changeset %d"
+msgstr ""
+
+#, python-format
+msgid " (expected %s)"
+msgstr ""
+
+#, python-format
+msgid "unknown parent 1 %s of %s"
+msgstr ""
+
+#, python-format
+msgid "unknown parent 2 %s of %s"
+msgstr ""
+
+#, python-format
+msgid "checking parents of %s"
+msgstr "se verifică părinții lui %s"
+
+#, python-format
+msgid "duplicate revision %d (%d)"
+msgstr ""
+
+msgid "abandoned transaction found - run hg recover\n"
+msgstr ""
+
+#, python-format
+msgid "repository uses revlog format %d\n"
+msgstr ""
+
+msgid "checking changesets\n"
+msgstr "se verifică seturile de modificări\n"
+
+#, python-format
+msgid "unpacking changeset %s"
+msgstr ""
+
+msgid "checking manifests\n"
+msgstr "se verifică manifestele\n"
+
+#, python-format
+msgid "%s not in changesets"
+msgstr ""
+
+msgid "file without name in manifest"
+msgstr ""
+
+#, python-format
+msgid "reading manifest delta %s"
+msgstr ""
+
+msgid "crosschecking files in changesets and manifests\n"
+msgstr "se verifică încrucișat în seturile de modificări și manifeste\n"
+
+msgid "crosschecking"
+msgstr "se verifică încrucișat"
+
+#, python-format
+msgid "changeset refers to unknown manifest %s"
+msgstr ""
+
+msgid "in changeset but not in manifest"
+msgstr ""
+
+msgid "in manifest but not in changeset"
+msgstr ""
+
+msgid "checking files\n"
+msgstr "se verifică fișierele\n"
+
+#, python-format
+msgid "cannot decode filename '%s'"
+msgstr ""
+
+msgid "checking"
+msgstr "se verifică"
+
+#, python-format
+msgid "broken revlog! (%s)"
+msgstr ""
+
+msgid "missing revlog!"
+msgstr ""
+
+#, python-format
+msgid "%s not in manifests"
+msgstr ""
+
+#, python-format
+msgid "unpacked size is %s, %s expected"
+msgstr ""
+
+#, python-format
+msgid "unpacking %s"
+msgstr ""
+
+#, python-format
+msgid "warning: copy source of '%s' not in parents of %s"
+msgstr ""
+
+#, python-format
+msgid "empty or missing copy source revlog %s:%s"
+msgstr ""
+
+#, python-format
+msgid "warning: %s@%s: copy source revision is nullid %s:%s\n"
+msgstr ""
+
+#, python-format
+msgid "checking rename of %s"
+msgstr "se verifică redenumirea lui %s"
+
+#, python-format
+msgid "%s in manifests not found"
+msgstr ""
+
+#, python-format
+msgid "warning: orphan revlog '%s'"
+msgstr ""
+
+#, python-format
+msgid "%d files, %d changesets, %d total revisions\n"
+msgstr "%d fișiere, %d seturi de modificări, %d revizii totale\n"
+
+#, python-format
+msgid "%d warnings encountered!\n"
+msgstr ""
+
+#, python-format
+msgid "%d integrity errors encountered!\n"
+msgstr ""
+
+#, python-format
+msgid "(first damaged changeset appears to be %d)\n"
+msgstr ""
+
+msgid "user name not available - set USERNAME environment variable"
+msgstr ""
+
+msgid "look up remote revision"
+msgstr "se caută revizia"
+
+msgid "look up remote changes"
+msgstr "se caută modificări la distanță"
+
+msgid "push failed:"
+msgstr ""
+
+msgid "push failed (unexpected response):"
+msgstr ""
--- a/mercurial/archival.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/archival.py	Sat Aug 14 03:30:35 2010 +0200
@@ -12,7 +12,7 @@
 import cStringIO, os, stat, tarfile, time, zipfile
 import zlib, gzip
 
-def tidyprefix(dest, prefix, suffixes):
+def tidyprefix(dest, kind, prefix):
     '''choose prefix to use for names in archive.  make sure prefix is
     safe for consumers.'''
 
@@ -23,7 +23,7 @@
             raise ValueError('dest must be string if no prefix')
         prefix = os.path.basename(dest)
         lower = prefix.lower()
-        for sfx in suffixes:
+        for sfx in exts.get(kind, []):
             if lower.endswith(sfx):
                 prefix = prefix[:-len(sfx)]
                 break
@@ -35,6 +35,20 @@
         raise util.Abort(_('archive prefix contains illegal components'))
     return prefix
 
+exts = {
+    'tar': ['.tar'],
+    'tbz2': ['.tbz2', '.tar.bz2'],
+    'tgz': ['.tgz', '.tar.gz'],
+    'zip': ['.zip'],
+    }
+
+def guesskind(dest):
+    for kind, extensions in exts.iteritems():
+        if util.any(dest.endswith(ext) for ext in extensions):
+            return kind
+    return None
+
+
 class tarit(object):
     '''write archive to tar file or stream.  can write uncompressed,
     or compress with gzip or bzip2.'''
@@ -66,9 +80,7 @@
             if fname:
                 self.fileobj.write(fname + '\000')
 
-    def __init__(self, dest, prefix, mtime, kind=''):
-        self.prefix = tidyprefix(dest, prefix, ['.tar', '.tar.bz2', '.tar.gz',
-                                                '.tgz', '.tbz2'])
+    def __init__(self, dest, mtime, kind=''):
         self.mtime = mtime
 
         def taropen(name, mode, fileobj=None):
@@ -90,7 +102,7 @@
             self.z = taropen(name='', mode='w|', fileobj=dest)
 
     def addfile(self, name, mode, islink, data):
-        i = tarfile.TarInfo(self.prefix + name)
+        i = tarfile.TarInfo(name)
         i.mtime = self.mtime
         i.size = len(data)
         if islink:
@@ -129,8 +141,7 @@
     '''write archive to zip file or stream.  can write uncompressed,
     or compressed with deflate.'''
 
-    def __init__(self, dest, prefix, mtime, compress=True):
-        self.prefix = tidyprefix(dest, prefix, ('.zip',))
+    def __init__(self, dest, mtime, compress=True):
         if not isinstance(dest, str):
             try:
                 dest.tell()
@@ -142,7 +153,7 @@
         self.date_time = time.gmtime(mtime)[:6]
 
     def addfile(self, name, mode, islink, data):
-        i = zipfile.ZipInfo(self.prefix + name, self.date_time)
+        i = zipfile.ZipInfo(name, self.date_time)
         i.compress_type = self.z.compression
         # unzip will not honor unix file modes unless file creator is
         # set to unix (id 3).
@@ -160,9 +171,7 @@
 class fileit(object):
     '''write archive as files in directory.'''
 
-    def __init__(self, name, prefix, mtime):
-        if prefix:
-            raise util.Abort(_('cannot give prefix when archiving to files'))
+    def __init__(self, name, mtime):
         self.basedir = name
         self.opener = util.opener(self.basedir)
 
@@ -182,9 +191,9 @@
 archivers = {
     'files': fileit,
     'tar': tarit,
-    'tbz2': lambda name, prefix, mtime: tarit(name, prefix, mtime, 'bz2'),
-    'tgz': lambda name, prefix, mtime: tarit(name, prefix, mtime, 'gz'),
-    'uzip': lambda name, prefix, mtime: zipit(name, prefix, mtime, False),
+    'tbz2': lambda name, mtime: tarit(name, mtime, 'bz2'),
+    'tgz': lambda name, mtime: tarit(name, mtime, 'gz'),
+    'uzip': lambda name, mtime: zipit(name, mtime, False),
     'zip': zipit,
     }
 
@@ -204,19 +213,25 @@
 
     prefix is name of path to put before every archive member.'''
 
+    if kind == 'files':
+        if prefix:
+            raise util.Abort(_('cannot give prefix when archiving to files'))
+    else:
+        prefix = tidyprefix(dest, kind, prefix)
+
     def write(name, mode, islink, getdata):
         if matchfn and not matchfn(name):
             return
         data = getdata()
         if decode:
             data = repo.wwritedata(name, data)
-        archiver.addfile(name, mode, islink, data)
+        archiver.addfile(prefix + name, mode, islink, data)
 
     if kind not in archivers:
         raise util.Abort(_("unknown archive type '%s'") % kind)
 
     ctx = repo[node]
-    archiver = archivers[kind](dest, prefix, mtime or ctx.date()[0])
+    archiver = archivers[kind](dest, mtime or ctx.date()[0])
 
     if repo.ui.configbool("ui", "archivemeta", True):
         def metadata():
--- a/mercurial/changegroup.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/changegroup.py	Sat Aug 14 03:30:35 2010 +0200
@@ -61,8 +61,7 @@
     # We want to gather manifests needed and filelogs affected.
     def collect(node):
         c = cl.read(node)
-        for fn in c[3]:
-            files.setdefault(fn, fn)
+        files.update(c[3])
         mmfs.setdefault(c[0], node)
     return collect
 
--- a/mercurial/cmdutil.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/cmdutil.py	Sat Aug 14 03:30:35 2010 +0200
@@ -638,7 +638,7 @@
         fp.write("# HG changeset patch\n")
         fp.write("# User %s\n" % ctx.user())
         fp.write("# Date %d %d\n" % ctx.date())
-        if branch and (branch != 'default'):
+        if branch and branch != 'default':
             fp.write("# Branch %s\n" % branch)
         fp.write("# Node ID %s\n" % hex(node))
         fp.write("# Parent  %s\n" % hex(prev))
@@ -1045,36 +1045,43 @@
     fncache = {}
     change = util.cachefunc(repo.changectx)
 
+    # First step is to fill wanted, the set of revisions that we want to yield.
+    # When it does not induce extra cost, we also fill fncache for revisions in
+    # wanted: a cache of filenames that were changed (ctx.files()) and that
+    # match the file filtering conditions.
+
     if not slowpath and not match.files():
         # No files, no patterns.  Display all revs.
         wanted = set(revs)
     copies = []
 
     if not slowpath:
+        # We only have to read through the filelog to find wanted revisions
+
+        minrev, maxrev = min(revs), max(revs)
         # Only files, no patterns.  Check the history of each file.
-        def filerevgen(filelog, node):
+        def filerevgen(filelog, last):
             cl_count = len(repo)
-            if node is None:
-                last = len(filelog) - 1
-            else:
-                last = filelog.rev(node)
-            for i, window in increasing_windows(last, nullrev):
-                revs = []
-                for j in xrange(i - window, i + 1):
-                    n = filelog.node(j)
-                    revs.append((filelog.linkrev(j),
-                                 follow and filelog.renamed(n)))
-                for rev in reversed(revs):
-                    # only yield rev for which we have the changelog, it can
-                    # happen while doing "hg log" during a pull or commit
-                    if rev[0] < cl_count:
-                        yield rev
+            revs = []
+            for j in xrange(0, last + 1):
+                linkrev = filelog.linkrev(j)
+                if linkrev < minrev:
+                    continue
+                # only yield rev for which we have the changelog, it can
+                # happen while doing "hg log" during a pull or commit
+                if linkrev > maxrev or linkrev >= cl_count:
+                    break
+                n = filelog.node(j)
+                revs.append((filelog.linkrev(j),
+                             follow and filelog.renamed(n)))
+
+            for rev in reversed(revs):
+                yield rev
         def iterfiles():
             for filename in match.files():
                 yield filename, None
             for filename_node in copies:
                 yield filename_node
-        minrev, maxrev = min(revs), max(revs)
         for file_, node in iterfiles():
             filelog = repo.file(file_)
             if not len(filelog):
@@ -1088,31 +1095,33 @@
                     break
                 else:
                     continue
-            for rev, copied in filerevgen(filelog, node):
-                if rev <= maxrev:
-                    if rev < minrev:
-                        break
-                    fncache.setdefault(rev, [])
-                    fncache[rev].append(file_)
-                    wanted.add(rev)
-                    if copied:
-                        copies.append(copied)
+
+            if node is None:
+                last = len(filelog) - 1
+            else:
+                last = filelog.rev(node)
+
+            for rev, copied in filerevgen(filelog, last):
+                fncache.setdefault(rev, [])
+                fncache[rev].append(file_)
+                wanted.add(rev)
+                if copied:
+                    copies.append(copied)
     if slowpath:
+        # We have to read the changelog to match filenames against
+        # changed files
+
         if follow:
             raise util.Abort(_('can only follow copies/renames for explicit '
                                'filenames'))
 
         # The slow path checks files modified in every changeset.
-        def changerevgen():
-            for i, window in increasing_windows(len(repo) - 1, nullrev):
-                for j in xrange(i - window, i + 1):
-                    yield change(j)
-
-        for ctx in changerevgen():
+        for i in sorted(revs):
+            ctx = change(i)
             matches = filter(match, ctx.files())
             if matches:
-                fncache[ctx.rev()] = matches
-                wanted.add(ctx.rev())
+                fncache[i] = matches
+                wanted.add(i)
 
     class followfilter(object):
         def __init__(self, onlyfirst=False):
@@ -1161,6 +1170,8 @@
             if ff.match(x):
                 wanted.discard(x)
 
+    # Now that wanted is correctly initialized, we can iterate over the
+    # revision range, yielding only revisions in wanted.
     def iterate():
         if follow and not match.files():
             ff = followfilter(onlyfirst=opts.get('follow_first'))
@@ -1171,7 +1182,6 @@
                 return rev in wanted
 
         for i, window in increasing_windows(0, len(revs)):
-            change = util.cachefunc(repo.changectx)
             nrevs = [rev for rev in revs[i:i + window] if want(rev)]
             for rev in sorted(nrevs):
                 fns = fncache.get(rev)
--- a/mercurial/commands.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/commands.py	Sat Aug 14 03:30:35 2010 +0200
@@ -83,7 +83,7 @@
     Returns 0 if all files are successfully added.
     """
     try:
-        sim = float(opts.get('similarity') or 0)
+        sim = float(opts.get('similarity') or 100)
     except ValueError:
         raise util.Abort(_('similarity must be a number'))
     if sim < 0 or sim > 100:
@@ -197,20 +197,7 @@
     if os.path.realpath(dest) == repo.root:
         raise util.Abort(_('repository root cannot be destination'))
 
-    def guess_type():
-        exttypes = {
-            'tar': ['.tar'],
-            'tbz2': ['.tbz2', '.tar.bz2'],
-            'tgz': ['.tgz', '.tar.gz'],
-            'zip': ['.zip'],
-        }
-
-        for type, extensions in exttypes.items():
-            if util.any(dest.endswith(ext) for ext in extensions):
-                return type
-        return None
-
-    kind = opts.get('type') or guess_type() or 'files'
+    kind = opts.get('type') or archival.guesskind(dest) or 'files'
     prefix = opts.get('prefix')
 
     if dest == '-':
@@ -903,7 +890,7 @@
         # we don't want to fail in merges during buildup
         os.environ['HGMERGE'] = 'internal:local'
 
-    def writefile(fname, text, fmode="w"):
+    def writefile(fname, text, fmode="wb"):
         f = open(fname, fmode)
         try:
             f.write(text)
@@ -938,7 +925,7 @@
                 merge(ui, repo, node=p2)
 
             if mergeable_file:
-                f = open("mf", "r+")
+                f = open("mf", "rb+")
                 try:
                     lines = f.read().split("\n")
                     lines[id * linesperrev] += " r%i" % id
@@ -948,7 +935,7 @@
                     f.close()
 
             if appended_file:
-                writefile("af", "r%i\n" % id, "a")
+                writefile("af", "r%i\n" % id, "ab")
 
             if overwritten_file:
                 writefile("of", "r%i\n" % id)
@@ -1473,11 +1460,11 @@
     given using a format string. The formatting rules are as follows:
 
     :``%%``: literal "%" character
-    :``%H``: changeset hash (40 bytes of hexadecimal)
+    :``%H``: changeset hash (40 hexadecimal digits)
     :``%N``: number of patches being generated
     :``%R``: changeset revision number
     :``%b``: basename of the exporting repository
-    :``%h``: short-form changeset hash (12 bytes of hexadecimal)
+    :``%h``: short-form changeset hash (12 hexadecimal digits)
     :``%n``: zero-padded sequence number, starting at 1
     :``%r``: zero-padded changeset revision number
 
@@ -1869,7 +1856,10 @@
         if not doc:
             doc = _("(no help text available)")
         if hasattr(entry[0], 'definition'):  # aliased command
-            doc = _('alias for: hg %s\n\n%s') % (entry[0].definition, doc)
+            if entry[0].definition.startswith('!'):  # shell alias
+                doc = _('shell alias for::\n\n    %s') % entry[0].definition[1:]
+            else:
+                doc = _('alias for: hg %s\n\n%s') % (entry[0].definition, doc)
         if ui.quiet:
             doc = doc.splitlines()[0]
         keep = ui.verbose and ['verbose'] or []
--- a/mercurial/context.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/context.py	Sat Aug 14 03:30:35 2010 +0200
@@ -75,7 +75,7 @@
 
     @propertycache
     def substate(self):
-        return subrepo.state(self)
+        return subrepo.state(self, self._repo.ui)
 
     def __contains__(self, key):
         return key in self._manifest
@@ -352,12 +352,12 @@
     def size(self):
         return self._filelog.size(self._filerev)
 
-    def cmp(self, text):
-        """compare text with stored file revision
+    def cmp(self, fctx):
+        """compare with other file context
 
-        returns True if text is different than what is stored.
+        returns True if different than fctx.
         """
-        return self._filelog.cmp(self._filenode, text)
+        return self._filelog.cmp(self._filenode, fctx.data())
 
     def renamed(self):
         """check if file was actually renamed in this changeset revision
@@ -935,12 +935,14 @@
                 raise
             return (t, tz)
 
-    def cmp(self, text):
-        """compare text with disk content
+    def cmp(self, fctx):
+        """compare with other file context
 
-        returns True if text is different than what is on disk.
+        returns True if different than fctx.
         """
-        return self._repo.wread(self._path) != text
+        # fctx should be a filectx (not a wfctx)
+        # invert comparison to reuse the same code path
+        return fctx.cmp(self)
 
 class memctx(object):
     """Use memctx to perform in-memory commits via localrepo.commitctx().
--- a/mercurial/discovery.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/discovery.py	Sat Aug 14 03:30:35 2010 +0200
@@ -35,7 +35,9 @@
     exist on the remote side and that no child of a node of base exists
     in both remote and repo.
     Furthermore base will be updated to include the nodes that exists
-    in repo and remote but no children exists in repo and remote.
+    in repo and remote but no children exists in both repo and remote.
+    In other words, base is the set of heads of the DAG resulting from
+    the intersection of the nodes from repo and remote.
     If a list of heads is specified, return only nodes which are heads
     or ancestors of these heads.
 
@@ -172,18 +174,17 @@
 
     return base.keys(), list(fetch), heads
 
-def findoutgoing(repo, remote, base=None, heads=None, force=False):
+def findoutgoing(repo, remote, base=None, remoteheads=None, force=False):
     """Return list of nodes that are roots of subsets not in remote
 
     If base dict is specified, assume that these nodes and their parents
     exist on the remote side.
-    If a list of heads is specified, return only nodes which are heads
-    or ancestors of these heads, and return a second element which
-    contains all remote heads which get new children.
+    If remotehead is specified, assume it is the list of the heads from
+    the remote repository.
     """
     if base is None:
         base = {}
-        findincoming(repo, remote, base, heads, force=force)
+        findincoming(repo, remote, base, remoteheads, force=force)
 
     repo.ui.debug("common changesets up to "
                   + " ".join(map(short, base.keys())) + "\n")
@@ -203,22 +204,12 @@
     # find every node whose parents have been pruned
     subset = []
     # find every remote head that will get new children
-    updated_heads = set()
     for n in remain:
         p1, p2 = repo.changelog.parents(n)
         if p1 not in remain and p2 not in remain:
             subset.append(n)
-        if heads:
-            if p1 in heads:
-                updated_heads.add(p1)
-            if p2 in heads:
-                updated_heads.add(p2)
 
-    # this is the set of all roots we have to push
-    if heads:
-        return subset, list(updated_heads)
-    else:
-        return subset
+    return subset
 
 def prepush(repo, remote, force, revs, newbranch):
     '''Analyze the local and remote repositories and determine which
@@ -235,34 +226,18 @@
     successive changegroup chunks ready to be sent over the wire and
     remoteheads is the list of remote heads.'''
     common = {}
-    remote_heads = remote.heads()
-    inc = findincoming(repo, remote, common, remote_heads, force=force)
+    remoteheads = remote.heads()
+    inc = findincoming(repo, remote, common, remoteheads, force=force)
 
     cl = repo.changelog
-    update, updated_heads = findoutgoing(repo, remote, common, remote_heads)
+    update = findoutgoing(repo, remote, common, remoteheads)
     outg, bases, heads = cl.nodesbetween(update, revs)
 
     if not bases:
         repo.ui.status(_("no changes found\n"))
         return None, 1
 
-    if not force and remote_heads != [nullid]:
-
-        def fail_multiple_heads(unsynced, branch=None):
-            if branch:
-                msg = _("abort: push creates new remote heads"
-                        " on branch '%s'!\n") % branch
-            else:
-                msg = _("abort: push creates new remote heads!\n")
-            repo.ui.warn(msg)
-            if unsynced:
-                repo.ui.status(_("(you should pull and merge or"
-                                 " use push -f to force)\n"))
-            else:
-                repo.ui.status(_("(did you forget to merge?"
-                                 " use push -f to force)\n"))
-            return None, 0
-
+    if not force and remoteheads != [nullid]:
         if remote.capable('branchmap'):
             # Check for each named branch if we're creating new remote heads.
             # To be a remote head after push, node must be either:
@@ -281,12 +256,10 @@
             newbranches = branches - set(remotemap)
             if newbranches and not newbranch: # new branch requires --new-branch
                 branchnames = ', '.join(sorted(newbranches))
-                repo.ui.warn(_("abort: push creates "
-                               "new remote branches: %s!\n")
-                             % branchnames)
-                repo.ui.status(_("(use 'hg push --new-branch' to create new "
-                                 "remote branches)\n"))
-                return None, 0
+                raise util.Abort(_("push creates new remote branches: %s!")
+                                   % branchnames,
+                                 hint=_("use 'hg push --new-branch' to create"
+                                        " new remote branches"))
             branches.difference_update(newbranches)
 
             # 3. Construct the initial oldmap and newmap dicts.
@@ -299,11 +272,11 @@
             newmap = {}
             unsynced = set()
             for branch in branches:
-                remoteheads = remotemap[branch]
-                prunedheads = [h for h in remoteheads if h in cl.nodemap]
-                oldmap[branch] = prunedheads
-                newmap[branch] = list(prunedheads)
-                if len(remoteheads) > len(prunedheads):
+                remotebrheads = remotemap[branch]
+                prunedbrheads = [h for h in remotebrheads if h in cl.nodemap]
+                oldmap[branch] = prunedbrheads
+                newmap[branch] = list(prunedbrheads)
+                if len(remotebrheads) > len(prunedbrheads):
                     unsynced.add(branch)
 
             # 4. Update newmap with outgoing changes.
@@ -311,23 +284,12 @@
             ctxgen = (repo[n] for n in outg)
             repo._updatebranchcache(newmap, ctxgen)
 
-            # 5. Check for new heads.
-            # If there are more heads after the push than before, a suitable
-            # warning, depending on unsynced status, is displayed.
-            for branch in branches:
-                if len(newmap[branch]) > len(oldmap[branch]):
-                    return fail_multiple_heads(branch in unsynced, branch)
-
-            # 6. Check for unsynced changes on involved branches.
-            if unsynced:
-                repo.ui.warn(_("note: unsynced remote changes!\n"))
-
         else:
-            # Old servers: Check for new topological heads.
-            # Code based on _updatebranchcache.
-            newheads = set(h for h in remote_heads if h in cl.nodemap)
-            oldheadcnt = len(newheads)
-            newheads.update(outg)
+            # 1-4b. old servers: Check for new topological heads.
+            # Construct {old,new}map with branch = None (topological branch).
+            # (code based on _updatebranchcache)
+            oldheads = set(h for h in remoteheads if h in cl.nodemap)
+            newheads = oldheads.union(outg)
             if len(newheads) > 1:
                 for latest in reversed(outg):
                     if latest not in newheads:
@@ -336,10 +298,31 @@
                     reachable = cl.reachable(latest, cl.node(minhrev))
                     reachable.remove(latest)
                     newheads.difference_update(reachable)
-            if len(newheads) > oldheadcnt:
-                return fail_multiple_heads(inc)
-            if inc:
-                repo.ui.warn(_("note: unsynced remote changes!\n"))
+            branches = set([None])
+            newmap = {None: newheads}
+            oldmap = {None: oldheads}
+            unsynced = inc and branches or set()
+
+        # 5. Check for new heads.
+        # If there are more heads after the push than before, a suitable
+        # warning, depending on unsynced status, is displayed.
+        for branch in branches:
+            if len(newmap[branch]) > len(oldmap[branch]):
+                if branch:
+                    msg = _("push creates new remote heads "
+                            "on branch '%s'!") % branch
+                else:
+                    msg = _("push creates new remote heads!")
+
+                if branch in unsynced:
+                    hint = _("you should pull and merge or use push -f to force")
+                else:
+                    hint = _("did you forget to merge? use push -f to force")
+                raise util.Abort(msg, hint=hint)
+
+        # 6. Check for unsynced changes on involved branches.
+        if unsynced:
+            repo.ui.warn(_("note: unsynced remote changes!\n"))
 
     if revs is None:
         # use the fast path, no race possible on push
@@ -347,4 +330,4 @@
         cg = repo._changegroup(nodes, 'push')
     else:
         cg = repo.changegroupsubset(update, revs, 'push')
-    return cg, remote_heads
+    return cg, remoteheads
--- a/mercurial/dispatch.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/dispatch.py	Sat Aug 14 03:30:35 2010 +0200
@@ -6,7 +6,7 @@
 # GNU General Public License version 2 or any later version.
 
 from i18n import _
-import os, sys, atexit, signal, pdb, socket, errno, shlex, time
+import os, sys, atexit, signal, pdb, socket, errno, shlex, time, traceback
 import util, commands, hg, fancyopts, extensions, hook, error
 import cmdutil, encoding
 import ui as uimod
@@ -23,6 +23,8 @@
             u.setconfig('ui', 'traceback', 'on')
     except util.Abort, inst:
         sys.stderr.write(_("abort: %s\n") % inst)
+        if inst.hint:
+            sys.stderr.write(_("(%s)\n") % inst.hint)
         return -1
     except error.ParseError, inst:
         if len(inst.args) > 1:
@@ -49,6 +51,8 @@
         try:
             # enter the debugger before command execution
             if '--debugger' in args:
+                ui.warn(_("entering debugger - "
+                        "type c to continue starting hg or h for help\n"))
                 pdb.set_trace()
             try:
                 return _dispatch(ui, args)
@@ -57,6 +61,7 @@
         except:
             # enter the debugger when we hit an exception
             if '--debugger' in args:
+                traceback.print_exc()
                 pdb.post_mortem(sys.exc_info()[2])
             ui.traceback()
             raise
@@ -113,6 +118,8 @@
             commands.help_(ui, 'shortlist')
     except util.Abort, inst:
         ui.warn(_("abort: %s\n") % inst)
+        if inst.hint:
+            ui.warn(_("(%s)\n") % inst.hint)
     except ImportError, inst:
         ui.warn(_("abort: %s!\n") % inst)
         m = str(inst).split()[-1]
@@ -205,10 +212,29 @@
 
             return
 
+        if self.definition.startswith('!'):
+            def fn(ui, *args):
+                cmd = '%s %s' % (self.definition[1:], ' '.join(args))
+                return util.system(cmd)
+            self.fn = fn
+            return
+
         args = shlex.split(self.definition)
         cmd = args.pop(0)
         args = map(util.expandpath, args)
 
+        for invalidarg in ("--cwd", "-R", "--repository", "--repo"):
+            if _earlygetopt([invalidarg], args):
+                def fn(ui, *args):
+                    ui.warn(_("error in definition for alias '%s': %s may only "
+                              "be given on the command line\n")
+                            % (self.name, invalidarg))
+                    return 1
+
+                self.fn = fn
+                self.badalias = True
+                return
+
         try:
             tableentry = cmdutil.findcmd(cmd, cmdtable, False)[1]
             if len(tableentry) > 2:
--- a/mercurial/error.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/error.py	Sat Aug 14 03:30:35 2010 +0200
@@ -32,6 +32,9 @@
 
 class Abort(Exception):
     """Raised if a command needs to print an error and exit."""
+    def __init__(self, *args, **kw):
+        Exception.__init__(self, *args)
+        self.hint = kw.get('hint')
 
 class ConfigError(Abort):
     'Exception raised when parsing config files'
--- a/mercurial/filemerge.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/filemerge.py	Sat Aug 14 03:30:35 2010 +0200
@@ -135,7 +135,7 @@
         except IOError:
             return False
 
-    if not fco.cmp(fcd.data()): # files identical?
+    if not fco.cmp(fcd): # files identical?
         return None
 
     if fca == fco: # backwards, use working dir parent as ancestor
--- a/mercurial/help/glossary.txt	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/help/glossary.txt	Sat Aug 14 03:30:35 2010 +0200
@@ -16,7 +16,7 @@
     a remote repository, since new heads may be created by these
     operations. Note that the term branch can also be used informally
     to describe a development process in which certain development is
-    done independently of other development.This is sometimes done
+    done independently of other development. This is sometimes done
     explicitly with a named branch, but it can also be done locally,
     using bookmarks or clones and anonymous branches.
 
@@ -83,8 +83,8 @@
 
 Changeset id
     A SHA-1 hash that uniquely identifies a changeset. It may be
-    represented as either a "long" 40-byte hexadecimal string, or a
-    "short" 12-byte hexadecimal string.
+    represented as either a "long" 40 hexadecimal digit string, or a
+    "short" 12 hexadecimal digit string.
 
 Changeset, merge
     A changeset with two parents. This occurs when a merge is
--- a/mercurial/help/revsets.txt	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/help/revsets.txt	Sat Aug 14 03:30:35 2010 +0200
@@ -58,8 +58,7 @@
   Alias for ``user(string)``.
 
 ``branch(set)``
-  The branch names are found for changesets in set, and the result is
-  all changesets belonging to one those branches.
+  All changesets belonging to the branches of changesets in set.
 
 ``children(set)``
   Child changesets of changesets in set.
@@ -74,10 +73,10 @@
   Changesets within the interval, see :hg:`help dates`.
 
 ``descendants(set)``
-  Changesets which are decendants of changesets in set.
+  Changesets which are descendants of changesets in set.
 
 ``file(pattern)``
-  Changesets which manually affected files matching pattern.
+  Changesets affecting files matched by pattern.
 
 ``follow()``
   An alias for ``::.`` (ancestors of the working copy's first parent).
@@ -101,14 +100,18 @@
 ``max(set)``
   Changeset with highest revision number in set.
 
+``min(set)``
+  Changeset with lowest revision number in set.
+
 ``merge()``
   Changeset is a merge changeset.
 
 ``modifies(pattern)``
-  Changesets which modify files matching pattern.
+  Changesets modifying files matched by pattern.
 
 ``outgoing([path])``
-  Changesets missing in path.
+  Changesets not found in the specified destination repository, or the
+  default push location.
 
 ``p1(set)``
   First parent of changesets in set.
--- a/mercurial/help/templates.txt	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/help/templates.txt	Sat Aug 14 03:30:35 2010 +0200
@@ -28,6 +28,8 @@
 :branches: String. The name of the branch on which the changeset was
     committed. Will be empty if the branch name was default.
 
+:children: List of strings. The children of the changeset.
+
 :date: Date information. The date when the changeset was committed.
 
 :desc: String. The text of the changeset description.
@@ -50,8 +52,8 @@
 
 :file_dels: List of strings. Files removed by this changeset.
 
-:node: String. The changeset identification hash, as a 40-character
-    hexadecimal string.
+:node: String. The changeset identification hash, as a 40 hexadecimal
+    digit string.
 
 :parents: List of strings. The parents of the changeset.
 
@@ -136,7 +138,7 @@
     specified in RFC 3339: "2009-08-18T13:00:13+02:00".
 
 :short: Changeset hash. Returns the short form of a changeset hash,
-    i.e. a 12-byte hexadecimal string.
+    i.e. a 12 hexadecimal digit string.
 
 :shortdate: Date. Returns a date like "2006-09-18".
 
--- a/mercurial/hgweb/hgweb_mod.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/hgweb/hgweb_mod.py	Sat Aug 14 03:30:35 2010 +0200
@@ -6,8 +6,8 @@
 # This software may be used and distributed according to the terms of the
 # GNU General Public License version 2 or any later version.
 
-import os
-from mercurial import ui, hg, hook, error, encoding, templater
+import os, sys, urllib
+from mercurial import ui, hg, hook, error, encoding, templater, util
 from common import get_mtime, ErrorResponse, permhooks
 from common import HTTP_OK, HTTP_BAD_REQUEST, HTTP_NOT_FOUND, HTTP_SERVER_ERROR
 from request import wsgirequest
@@ -112,24 +112,18 @@
         # and the clients always use the old URL structure
 
         cmd = req.form.get('cmd', [''])[0]
-        if cmd and cmd in protocol.__all__:
+        if protocol.iscmd(cmd):
             if query:
                 raise ErrorResponse(HTTP_NOT_FOUND)
-            try:
-                if cmd in perms:
-                    try:
-                        self.check_perm(req, perms[cmd])
-                    except ErrorResponse, inst:
-                        if cmd == 'unbundle':
-                            req.drain()
-                        raise
-                method = getattr(protocol, cmd)
-                return method(self.repo, req)
-            except ErrorResponse, inst:
-                req.respond(inst, protocol.HGTYPE)
-                if not inst.message:
-                    return []
-                return '0\n%s\n' % inst.message,
+            if cmd in perms:
+                try:
+                    self.check_perm(req, perms[cmd])
+                except ErrorResponse, inst:
+                    if cmd == 'unbundle':
+                        req.drain()
+                    req.respond(inst, protocol.HGTYPE)
+                    return '0\n%s\n' % inst.message
+            return protocol.call(self.repo, req, cmd)
 
         # translate user-visible url structure to internal structure
 
--- a/mercurial/hgweb/protocol.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/hgweb/protocol.py	Sat Aug 14 03:30:35 2010 +0200
@@ -5,221 +5,64 @@
 # This software may be used and distributed according to the terms of the
 # GNU General Public License version 2 or any later version.
 
-import cStringIO, zlib, tempfile, errno, os, sys, urllib, copy
-from mercurial import util, streamclone, pushkey
-from mercurial.node import bin, hex
-from mercurial import changegroup as changegroupmod
-from common import ErrorResponse, HTTP_OK, HTTP_NOT_FOUND, HTTP_SERVER_ERROR
-
-# __all__ is populated with the allowed commands. Be sure to add to it if
-# you're adding a new command, or the new command won't work.
-
-__all__ = [
-   'lookup', 'heads', 'branches', 'between', 'changegroup',
-   'changegroupsubset', 'capabilities', 'unbundle', 'stream_out',
-   'branchmap', 'pushkey', 'listkeys'
-]
+import cStringIO, zlib, sys, urllib
+from mercurial import util, wireproto
+from common import HTTP_OK
 
 HGTYPE = 'application/mercurial-0.1'
-basecaps = 'lookup changegroupsubset branchmap pushkey'.split()
-
-def lookup(repo, req):
-    try:
-        r = hex(repo.lookup(req.form['key'][0]))
-        success = 1
-    except Exception, inst:
-        r = str(inst)
-        success = 0
-    resp = "%s %s\n" % (success, r)
-    req.respond(HTTP_OK, HGTYPE, length=len(resp))
-    yield resp
-
-def heads(repo, req):
-    resp = " ".join(map(hex, repo.heads())) + "\n"
-    req.respond(HTTP_OK, HGTYPE, length=len(resp))
-    yield resp
-
-def branchmap(repo, req):
-    branches = repo.branchmap()
-    heads = []
-    for branch, nodes in branches.iteritems():
-        branchname = urllib.quote(branch)
-        branchnodes = [hex(node) for node in nodes]
-        heads.append('%s %s' % (branchname, ' '.join(branchnodes)))
-    resp = '\n'.join(heads)
-    req.respond(HTTP_OK, HGTYPE, length=len(resp))
-    yield resp
-
-def branches(repo, req):
-    nodes = []
-    if 'nodes' in req.form:
-        nodes = map(bin, req.form['nodes'][0].split(" "))
-    resp = cStringIO.StringIO()
-    for b in repo.branches(nodes):
-        resp.write(" ".join(map(hex, b)) + "\n")
-    resp = resp.getvalue()
-    req.respond(HTTP_OK, HGTYPE, length=len(resp))
-    yield resp
-
-def between(repo, req):
-    pairs = [map(bin, p.split("-"))
-             for p in req.form['pairs'][0].split(" ")]
-    resp = ''.join(" ".join(map(hex, b)) + "\n" for b in repo.between(pairs))
-    req.respond(HTTP_OK, HGTYPE, length=len(resp))
-    yield resp
-
-def changegroup(repo, req):
-    req.respond(HTTP_OK, HGTYPE)
-    nodes = []
-
-    if 'roots' in req.form:
-        nodes = map(bin, req.form['roots'][0].split(" "))
-
-    z = zlib.compressobj()
-    f = repo.changegroup(nodes, 'serve')
-    while 1:
-        chunk = f.read(4096)
-        if not chunk:
-            break
-        yield z.compress(chunk)
-
-    yield z.flush()
-
-def changegroupsubset(repo, req):
-    req.respond(HTTP_OK, HGTYPE)
-    bases = []
-    heads = []
-
-    if 'bases' in req.form:
-        bases = [bin(x) for x in req.form['bases'][0].split(' ')]
-    if 'heads' in req.form:
-        heads = [bin(x) for x in req.form['heads'][0].split(' ')]
-
-    z = zlib.compressobj()
-    f = repo.changegroupsubset(bases, heads, 'serve')
-    while 1:
-        chunk = f.read(4096)
-        if not chunk:
-            break
-        yield z.compress(chunk)
-
-    yield z.flush()
-
-def capabilities(repo, req):
-    caps = copy.copy(basecaps)
-    if streamclone.allowed(repo.ui):
-        caps.append('stream=%d' % repo.changelog.version)
-    if changegroupmod.bundlepriority:
-        caps.append('unbundle=%s' % ','.join(changegroupmod.bundlepriority))
-    rsp = ' '.join(caps)
-    req.respond(HTTP_OK, HGTYPE, length=len(rsp))
-    yield rsp
-
-def unbundle(repo, req):
-
-    proto = req.env.get('wsgi.url_scheme') or 'http'
-    their_heads = req.form['heads'][0].split(' ')
 
-    def check_heads():
-        heads = map(hex, repo.heads())
-        return their_heads == [hex('force')] or their_heads == heads
-
-    # fail early if possible
-    if not check_heads():
-        req.drain()
-        raise ErrorResponse(HTTP_OK, 'unsynced changes')
-
-    # do not lock repo until all changegroup data is
-    # streamed. save to temporary file.
-
-    fd, tempname = tempfile.mkstemp(prefix='hg-unbundle-')
-    fp = os.fdopen(fd, 'wb+')
-    try:
-        length = int(req.env['CONTENT_LENGTH'])
-        for s in util.filechunkiter(req, limit=length):
+class webproto(object):
+    def __init__(self, req):
+        self.req = req
+        self.response = ''
+    def getargs(self, args):
+        data = {}
+        keys = args.split()
+        for k in keys:
+            if k == '*':
+                star = {}
+                for key in self.req.form.keys():
+                    if key not in keys:
+                        star[key] = self.req.form[key][0]
+                data['*'] = star
+            else:
+                data[k] = self.req.form[k][0]
+        return [data[k] for k in keys]
+    def getfile(self, fp):
+        length = int(self.req.env['CONTENT_LENGTH'])
+        for s in util.filechunkiter(self.req, limit=length):
             fp.write(s)
-
-        try:
-            lock = repo.lock()
-            try:
-                if not check_heads():
-                    raise ErrorResponse(HTTP_OK, 'unsynced changes')
-
-                fp.seek(0)
-                header = fp.read(6)
-                if header.startswith('HG') and not header.startswith('HG10'):
-                    raise ValueError('unknown bundle version')
-                elif header not in changegroupmod.bundletypes:
-                    raise ValueError('unknown bundle compression type')
-                gen = changegroupmod.unbundle(header, fp)
-
-                # send addchangegroup output to client
-
-                oldio = sys.stdout, sys.stderr
-                sys.stderr = sys.stdout = cStringIO.StringIO()
+    def redirect(self):
+        self.oldio = sys.stdout, sys.stderr
+        sys.stderr = sys.stdout = cStringIO.StringIO()
+    def groupchunks(self, cg):
+        z = zlib.compressobj()
+        while 1:
+            chunk = cg.read(4096)
+            if not chunk:
+                break
+            yield z.compress(chunk)
+        yield z.flush()
+    def _client(self):
+        return 'remote:%s:%s:%s' % (
+            self.req.env.get('wsgi.url_scheme') or 'http',
+            urllib.quote(self.req.env.get('REMOTE_HOST', '')),
+            urllib.quote(self.req.env.get('REMOTE_USER', '')))
 
-                try:
-                    url = 'remote:%s:%s:%s' % (
-                          proto,
-                          urllib.quote(req.env.get('REMOTE_HOST', '')),
-                          urllib.quote(req.env.get('REMOTE_USER', '')))
-                    try:
-                        ret = repo.addchangegroup(gen, 'serve', url, lock=lock)
-                    except util.Abort, inst:
-                        sys.stdout.write("abort: %s\n" % inst)
-                        ret = 0
-                finally:
-                    val = sys.stdout.getvalue()
-                    sys.stdout, sys.stderr = oldio
-                req.respond(HTTP_OK, HGTYPE)
-                return '%d\n%s' % (ret, val),
-            finally:
-                lock.release()
-        except ValueError, inst:
-            raise ErrorResponse(HTTP_OK, inst)
-        except (OSError, IOError), inst:
-            error = getattr(inst, 'strerror', 'Unknown error')
-            if not isinstance(error, str):
-                error = 'Error: %s' % str(error)
-            if inst.errno == errno.ENOENT:
-                code = HTTP_NOT_FOUND
-            else:
-                code = HTTP_SERVER_ERROR
-            filename = getattr(inst, 'filename', '')
-            # Don't send our filesystem layout to the client
-            if filename and filename.startswith(repo.root):
-                filename = filename[len(repo.root)+1:]
-                text = '%s: %s' % (error, filename)
-            else:
-                text = error.replace(repo.root + os.path.sep, '')
-            raise ErrorResponse(code, text)
-    finally:
-        fp.close()
-        os.unlink(tempname)
+def iscmd(cmd):
+    return cmd in wireproto.commands
 
-def stream_out(repo, req):
-    req.respond(HTTP_OK, HGTYPE)
-    try:
-        for chunk in streamclone.stream_out(repo):
-            yield chunk
-    except streamclone.StreamException, inst:
-        yield str(inst)
-
-def pushkey(repo, req):
-    namespace = req.form['namespace'][0]
-    key = req.form['key'][0]
-    old = req.form['old'][0]
-    new = req.form['new'][0]
-
-    r = repo.pushkey(namespace, key, old, new)
-    r = '%d\n' % int(r)
-    req.respond(HTTP_OK, HGTYPE, length=len(r))
-    yield r
-
-def listkeys(repo, req):
-    namespace = req.form['namespace'][0]
-    d = repo.listkeys(namespace).items()
-    t = '\n'.join(['%s\t%s' % (k.encode('string-escape'),
-                               v.encode('string-escape')) for k, v in d])
-    req.respond(HTTP_OK, HGTYPE, length=len(t))
-    yield t
+def call(repo, req, cmd):
+    p = webproto(req)
+    rsp = wireproto.dispatch(repo, p, cmd)
+    if isinstance(rsp, str):
+        req.respond(HTTP_OK, HGTYPE, length=len(rsp))
+        return [rsp]
+    elif isinstance(rsp, wireproto.streamres):
+        req.respond(HTTP_OK, HGTYPE)
+        return rsp.gen
+    elif isinstance(rsp, wireproto.pushres):
+        val = sys.stdout.getvalue()
+        sys.stdout, sys.stderr = p.oldio
+        req.respond(HTTP_OK, HGTYPE)
+        return ['%d\n%s' % (rsp.res, val)]
--- a/mercurial/httprepo.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/httprepo.py	Sat Aug 14 03:30:35 2010 +0200
@@ -8,7 +8,7 @@
 
 from node import bin, hex, nullid
 from i18n import _
-import repo, changegroup, statichttprepo, error, url, util, pushkey
+import repo, changegroup, statichttprepo, error, url, util, wireproto
 import os, urllib, urllib2, urlparse, zlib, httplib
 import errno, socket
 import encoding
@@ -24,7 +24,7 @@
         raise IOError(None, _('connection ended unexpectedly'))
     yield zd.flush()
 
-class httprepository(repo.repository):
+class httprepository(wireproto.wirerepository):
     def __init__(self, ui, path):
         self.path = path
         self.caps = None
@@ -56,7 +56,7 @@
     def get_caps(self):
         if self.caps is None:
             try:
-                self.caps = set(self.do_read('capabilities').split())
+                self.caps = set(self._call('capabilities').split())
             except error.RepoError:
                 self.caps = set()
             self.ui.debug('capabilities: %s\n' %
@@ -68,7 +68,7 @@
     def lock(self):
         raise util.Abort(_('operation not supported over http'))
 
-    def do_cmd(self, cmd, **args):
+    def _callstream(self, cmd, **args):
         data = args.pop('data', None)
         headers = args.pop('headers', {})
         self.ui.debug("sending %s command\n" % cmd)
@@ -132,90 +132,15 @@
 
         return resp
 
-    def do_read(self, cmd, **args):
-        fp = self.do_cmd(cmd, **args)
+    def _call(self, cmd, **args):
+        fp = self._callstream(cmd, **args)
         try:
             return fp.read()
         finally:
             # if using keepalive, allow connection to be reused
             fp.close()
 
-    def lookup(self, key):
-        self.requirecap('lookup', _('look up remote revision'))
-        d = self.do_cmd("lookup", key = key).read()
-        success, data = d[:-1].split(' ', 1)
-        if int(success):
-            return bin(data)
-        raise error.RepoError(data)
-
-    def heads(self):
-        d = self.do_read("heads")
-        try:
-            return map(bin, d[:-1].split(" "))
-        except:
-            raise error.ResponseError(_("unexpected response:"), d)
-
-    def branchmap(self):
-        d = self.do_read("branchmap")
-        try:
-            branchmap = {}
-            for branchpart in d.splitlines():
-                branchheads = branchpart.split(' ')
-                branchname = urllib.unquote(branchheads[0])
-                # Earlier servers (1.3.x) send branch names in (their) local
-                # charset. The best we can do is assume it's identical to our
-                # own local charset, in case it's not utf-8.
-                try:
-                    branchname.decode('utf-8')
-                except UnicodeDecodeError:
-                    branchname = encoding.fromlocal(branchname)
-                branchheads = [bin(x) for x in branchheads[1:]]
-                branchmap[branchname] = branchheads
-            return branchmap
-        except:
-            raise error.ResponseError(_("unexpected response:"), d)
-
-    def branches(self, nodes):
-        n = " ".join(map(hex, nodes))
-        d = self.do_read("branches", nodes=n)
-        try:
-            br = [tuple(map(bin, b.split(" "))) for b in d.splitlines()]
-            return br
-        except:
-            raise error.ResponseError(_("unexpected response:"), d)
-
-    def between(self, pairs):
-        batch = 8 # avoid giant requests
-        r = []
-        for i in xrange(0, len(pairs), batch):
-            n = " ".join(["-".join(map(hex, p)) for p in pairs[i:i + batch]])
-            d = self.do_read("between", pairs=n)
-            try:
-                r += [l and map(bin, l.split(" ")) or []
-                      for l in d.splitlines()]
-            except:
-                raise error.ResponseError(_("unexpected response:"), d)
-        return r
-
-    def changegroup(self, nodes, kind):
-        n = " ".join(map(hex, nodes))
-        f = self.do_cmd("changegroup", roots=n)
-        return util.chunkbuffer(zgenerator(f))
-
-    def changegroupsubset(self, bases, heads, source):
-        self.requirecap('changegroupsubset', _('look up remote changes'))
-        baselst = " ".join([hex(n) for n in bases])
-        headlst = " ".join([hex(n) for n in heads])
-        f = self.do_cmd("changegroupsubset", bases=baselst, heads=headlst)
-        return util.chunkbuffer(zgenerator(f))
-
-    def unbundle(self, cg, heads, source):
-        '''Send cg (a readable file-like object representing the
-        changegroup to push, typically a chunkbuffer object) to the
-        remote server as a bundle. Return an integer response code:
-        non-zero indicates a successful push (see
-        localrepository.addchangegroup()), and zero indicates either
-        error or nothing to push.'''
+    def _callpush(self, cmd, cg, **args):
         # have to stream bundle to a temp file because we do not have
         # http 1.1 chunked transfer.
 
@@ -235,56 +160,25 @@
 
         tempname = changegroup.writebundle(cg, None, type)
         fp = url.httpsendfile(tempname, "rb")
+        headers = {'Content-Type': 'application/mercurial-0.1'}
+
         try:
             try:
-                resp = self.do_read(
-                     'unbundle', data=fp,
-                     headers={'Content-Type': 'application/mercurial-0.1'},
-                     heads=' '.join(map(hex, heads)))
-                resp_code, output = resp.split('\n', 1)
-                try:
-                    ret = int(resp_code)
-                except ValueError, err:
-                    raise error.ResponseError(
-                            _('push failed (unexpected response):'), resp)
-                for l in output.splitlines(True):
-                    self.ui.status(_('remote: '), l)
-                return ret
+                r = self._call(cmd, data=fp, headers=headers, **args)
+                return r.split('\n', 1)
             except socket.error, err:
-                if err[0] in (errno.ECONNRESET, errno.EPIPE):
-                    raise util.Abort(_('push failed: %s') % err[1])
-                raise util.Abort(err[1])
+                if err.args[0] in (errno.ECONNRESET, errno.EPIPE):
+                    raise util.Abort(_('push failed: %s') % err.args[1])
+                raise util.Abort(err.args[1])
         finally:
             fp.close()
             os.unlink(tempname)
 
-    def stream_out(self):
-        return self.do_cmd('stream_out')
+    def _abort(self, exception):
+        raise exception
 
-    def pushkey(self, namespace, key, old, new):
-        if not self.capable('pushkey'):
-            return False
-        d = self.do_cmd("pushkey", data="", # force a POST
-                        namespace=namespace, key=key, old=old, new=new).read()
-        code, output = d.split('\n', 1)
-        try:
-            ret = bool(int(code))
-        except ValueError, err:
-            raise error.ResponseError(
-                _('push failed (unexpected response):'), d)
-        for l in output.splitlines(True):
-            self.ui.status(_('remote: '), l)
-        return ret
-
-    def listkeys(self, namespace):
-        if not self.capable('pushkey'):
-            return {}
-        d = self.do_cmd("listkeys", namespace=namespace).read()
-        r = {}
-        for l in d.splitlines():
-            k, v = l.split('\t')
-            r[k.decode('string-escape')] = v.decode('string-escape')
-        return r
+    def _decompress(self, stream):
+        return util.chunkbuffer(zgenerator(stream))
 
 class httpsrepository(httprepository):
     def __init__(self, ui, path):
--- a/mercurial/localrepo.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/localrepo.py	Sat Aug 14 03:30:35 2010 +0200
@@ -510,7 +510,7 @@
     def _link(self, f):
         return os.path.islink(self.wjoin(f))
 
-    def _filter(self, filter, filename, data):
+    def _loadfilter(self, filter):
         if filter not in self.filterpats:
             l = []
             for pat, cmd in self.ui.configitems(filter):
@@ -533,6 +533,9 @@
                 l.append((mf, fn, params))
             self.filterpats[filter] = l
 
+    def _filter(self, filter, filename, data):
+        self._loadfilter(filter)
+
         for mf, fn, cmd in self.filterpats[filter]:
             if mf(filename):
                 self.ui.debug("filtering %s through %s\n" % (filename, cmd))
@@ -1059,16 +1062,16 @@
                 # do a full compare of any files that might have changed
                 for f in sorted(cmp):
                     if (f not in ctx1 or ctx2.flags(f) != ctx1.flags(f)
-                        or ctx1[f].cmp(ctx2[f].data())):
+                        or ctx1[f].cmp(ctx2[f])):
                         modified.append(f)
                     else:
                         fixup.append(f)
 
-                if listclean:
-                    clean += fixup
-
                 # update dirstate for files that are actually clean
                 if fixup:
+                    if listclean:
+                        clean += fixup
+
                     try:
                         # updating the dirstate is optional
                         # so we don't wait on the lock
@@ -1103,7 +1106,7 @@
                 if fn in mf1:
                     if (mf1.flags(fn) != mf2.flags(fn) or
                         (mf1[fn] != mf2[fn] and
-                         (mf2[fn] or ctx1[fn].cmp(ctx2[fn].data())))):
+                         (mf2[fn] or ctx1[fn].cmp(ctx2[fn])))):
                         modified.append(fn)
                     elif listclean:
                         clean.append(fn)
@@ -1223,46 +1226,34 @@
         # unbundle assumes local user cannot lock remote repo (new ssh
         # servers, http servers).
 
-        if remote.capable('unbundle'):
-            return self.push_unbundle(remote, force, revs, newbranch)
-        return self.push_addchangegroup(remote, force, revs, newbranch)
-
-    def push_addchangegroup(self, remote, force, revs, newbranch):
-        '''Push a changegroup by locking the remote and sending the
-        addchangegroup command to it. Used for local and old SSH repos.
-        Return an integer: see push().
-        '''
-        lock = remote.lock()
+        lock = None
+        unbundle = remote.capable('unbundle')
+        if not unbundle:
+            lock = remote.lock()
         try:
             ret = discovery.prepush(self, remote, force, revs, newbranch)
-            if ret[0] is not None:
-                cg, remote_heads = ret
+            if ret[0] is None:
+                # and here we return 0 for "nothing to push" or 1 for
+                # "something to push but I refuse"
+                return ret[1]
+
+            cg, remote_heads = ret
+            if unbundle:
+                # local repo finds heads on server, finds out what revs it must
+                # push.  once revs transferred, if server finds it has
+                # different heads (someone else won commit/push race), server
+                # aborts.
+                if force:
+                    remote_heads = ['force']
+                # ssh: return remote's addchangegroup()
+                # http: return remote's addchangegroup() or 0 for error
+                return remote.unbundle(cg, remote_heads, 'push')
+            else:
                 # we return an integer indicating remote head count change
                 return remote.addchangegroup(cg, 'push', self.url(), lock=lock)
-            # and here we return 0 for "nothing to push" or 1 for
-            # "something to push but I refuse"
-            return ret[1]
         finally:
-            lock.release()
-
-    def push_unbundle(self, remote, force, revs, newbranch):
-        '''Push a changegroup by unbundling it on the remote.  Used for new
-        SSH and HTTP repos. Return an integer: see push().'''
-        # local repo finds heads on server, finds out what revs it
-        # must push.  once revs transferred, if server finds it has
-        # different heads (someone else won commit/push race), server
-        # aborts.
-
-        ret = discovery.prepush(self, remote, force, revs, newbranch)
-        if ret[0] is not None:
-            cg, remote_heads = ret
-            if force:
-                remote_heads = ['force']
-            # ssh: return remote's addchangegroup()
-            # http: return remote's addchangegroup() or 0 for error
-            return remote.unbundle(cg, remote_heads, 'push')
-        # as in push_addchangegroup()
-        return ret[1]
+            if lock is not None:
+                lock.release()
 
     def changegroupinfo(self, nodes, source):
         if self.ui.verbose or source == 'bundle':
@@ -1296,8 +1287,10 @@
         # Set up some initial variables
         # Make it easy to refer to self.changelog
         cl = self.changelog
-        # msng is short for missing - compute the list of changesets in this
-        # changegroup.
+        # Compute the list of changesets in this changegroup.
+        # Some bases may turn out to be superfluous, and some heads may be
+        # too.  nodesbetween will return the minimal set of bases and heads
+        # necessary to re-create the changegroup.
         if not bases:
             bases = [nullid]
         msng_cl_lst, bases, heads = cl.nodesbetween(bases, heads)
@@ -1314,31 +1307,9 @@
         self.hook('preoutgoing', throw=True, source=source)
 
         self.changegroupinfo(msng_cl_lst, source)
-        # Some bases may turn out to be superfluous, and some heads may be
-        # too.  nodesbetween will return the minimal set of bases and heads
-        # necessary to re-create the changegroup.
 
-        # Known heads are the list of heads that it is assumed the recipient
-        # of this changegroup will know about.
-        knownheads = set()
-        # We assume that all parents of bases are known heads.
-        for n in bases:
-            knownheads.update(cl.parents(n))
-        knownheads.discard(nullid)
-        knownheads = list(knownheads)
-        if knownheads:
-            # Now that we know what heads are known, we can compute which
-            # changesets are known.  The recipient must know about all
-            # changesets required to reach the known heads from the null
-            # changeset.
-            has_cl_set, junk, junk = cl.nodesbetween(None, knownheads)
-            junk = None
-            # Transform the list into a set.
-            has_cl_set = set(has_cl_set)
-        else:
-            # If there were no known heads, the recipient cannot be assumed to
-            # know about any changesets.
-            has_cl_set = set()
+        # We assume that all ancestors of bases are known
+        commonrevs = set(cl.ancestors(*[cl.rev(n) for n in bases]))
 
         # Make it easy to refer to self.manifest
         mnfst = self.manifest
@@ -1355,19 +1326,6 @@
         def identity(x):
             return x
 
-        # If we determine that a particular file or manifest node must be a
-        # node that the recipient of the changegroup will already have, we can
-        # also assume the recipient will have all the parents.  This function
-        # prunes them from the set of missing nodes.
-        def prune_parents(revlog, hasset, msngset):
-            for r in revlog.ancestors(*[revlog.rev(n) for n in hasset]):
-                msngset.pop(revlog.node(r), None)
-
-        # Use the information collected in collect_manifests_and_files to say
-        # which changenode any manifestnode belongs to.
-        def lookup_manifest_link(mnfstnode):
-            return msng_mnfst_set[mnfstnode]
-
         # A function generating function that sets up the initial environment
         # the inner function.
         def filenode_collector(changedfiles):
@@ -1386,10 +1344,9 @@
                     deltamf = mnfst.readdelta(mnfstnode)
                     # For each line in the delta
                     for f, fnode in deltamf.iteritems():
-                        f = changedfiles.get(f, None)
                         # And if the file is in the list of files we care
                         # about.
-                        if f is not None:
+                        if f in changedfiles:
                             # Get the changenode this manifest belongs to
                             clnode = msng_mnfst_set[mnfstnode]
                             # Create the set of filenodes for the file if
@@ -1412,28 +1369,23 @@
                             ndset.setdefault(fnode, clnode)
             return collect_msng_filenodes
 
-        # We have a list of filenodes we think we need for a file, lets remove
-        # all those we know the recipient must have.
-        def prune_filenodes(f, filerevlog):
-            msngset = msng_filenode_set[f]
+        # If we determine that a particular file or manifest node must be a
+        # node that the recipient of the changegroup will already have, we can
+        # also assume the recipient will have all the parents.  This function
+        # prunes them from the set of missing nodes.
+        def prune(revlog, missingnodes):
             hasset = set()
             # If a 'missing' filenode thinks it belongs to a changenode we
             # assume the recipient must have, then the recipient must have
             # that filenode.
-            for n in msngset:
-                clnode = cl.node(filerevlog.linkrev(filerevlog.rev(n)))
-                if clnode in has_cl_set:
+            for n in missingnodes:
+                clrev = revlog.linkrev(revlog.rev(n))
+                if clrev in commonrevs:
                     hasset.add(n)
-            prune_parents(filerevlog, hasset, msngset)
-
-        # A function generator function that sets up the a context for the
-        # inner function.
-        def lookup_filenode_link_func(fname):
-            msngset = msng_filenode_set[fname]
-            # Lookup the changenode the filenode belongs to.
-            def lookup_filenode_link(fnode):
-                return msngset[fnode]
-            return lookup_filenode_link
+            for n in hasset:
+                missingnodes.pop(n, None)
+            for r in revlog.ancestors(*[revlog.rev(n) for n in hasset]):
+                missingnodes.pop(revlog.node(r), None)
 
         # Add the nodes that were explicitly requested.
         def add_extra_nodes(name, nodes):
@@ -1448,45 +1400,30 @@
         # logically divide up the task, generate the group.
         def gengroup():
             # The set of changed files starts empty.
-            changedfiles = {}
+            changedfiles = set()
             collect = changegroup.collector(cl, msng_mnfst_set, changedfiles)
 
             # Create a changenode group generator that will call our functions
             # back to lookup the owning changenode and collect information.
             group = cl.group(msng_cl_lst, identity, collect)
-            cnt = 0
-            for chnk in group:
+            for cnt, chnk in enumerate(group):
                 yield chnk
                 self.ui.progress(_('bundling changes'), cnt, unit=_('chunks'))
-                cnt += 1
             self.ui.progress(_('bundling changes'), None)
 
-
-            # Figure out which manifest nodes (of the ones we think might be
-            # part of the changegroup) the recipient must know about and
-            # remove them from the changegroup.
-            has_mnfst_set = set()
-            for n in msng_mnfst_set:
-                # If a 'missing' manifest thinks it belongs to a changenode
-                # the recipient is assumed to have, obviously the recipient
-                # must have that manifest.
-                linknode = cl.node(mnfst.linkrev(mnfst.rev(n)))
-                if linknode in has_cl_set:
-                    has_mnfst_set.add(n)
-            prune_parents(mnfst, has_mnfst_set, msng_mnfst_set)
+            prune(mnfst, msng_mnfst_set)
             add_extra_nodes(1, msng_mnfst_set)
             msng_mnfst_lst = msng_mnfst_set.keys()
             # Sort the manifestnodes by revision number.
             msng_mnfst_lst.sort(key=mnfst.rev)
             # Create a generator for the manifestnodes that calls our lookup
             # and data collection functions back.
-            group = mnfst.group(msng_mnfst_lst, lookup_manifest_link,
+            group = mnfst.group(msng_mnfst_lst,
+                                lambda mnode: msng_mnfst_set[mnode],
                                 filenode_collector(changedfiles))
-            cnt = 0
-            for chnk in group:
+            for cnt, chnk in enumerate(group):
                 yield chnk
                 self.ui.progress(_('bundling manifests'), cnt, unit=_('chunks'))
-                cnt += 1
             self.ui.progress(_('bundling manifests'), None)
 
             # These are no longer needed, dereference and toss the memory for
@@ -1499,7 +1436,7 @@
                     if isinstance(fname, int):
                         continue
                     msng_filenode_set.setdefault(fname, {})
-                    changedfiles[fname] = 1
+                    changedfiles.add(fname)
             # Go through all our files in order sorted by name.
             cnt = 0
             for fname in sorted(changedfiles):
@@ -1508,32 +1445,27 @@
                     raise util.Abort(_("empty or missing revlog for %s") % fname)
                 # Toss out the filenodes that the recipient isn't really
                 # missing.
-                if fname in msng_filenode_set:
-                    prune_filenodes(fname, filerevlog)
-                    add_extra_nodes(fname, msng_filenode_set[fname])
-                    msng_filenode_lst = msng_filenode_set[fname].keys()
-                else:
-                    msng_filenode_lst = []
+                missingfnodes = msng_filenode_set.pop(fname, {})
+                prune(filerevlog, missingfnodes)
+                add_extra_nodes(fname, missingfnodes)
                 # If any filenodes are left, generate the group for them,
                 # otherwise don't bother.
-                if len(msng_filenode_lst) > 0:
+                if missingfnodes:
                     yield changegroup.chunkheader(len(fname))
                     yield fname
-                    # Sort the filenodes by their revision #
-                    msng_filenode_lst.sort(key=filerevlog.rev)
+                    # Sort the filenodes by their revision # (topological order)
+                    nodeiter = list(missingfnodes)
+                    nodeiter.sort(key=filerevlog.rev)
                     # Create a group generator and only pass in a changenode
                     # lookup function as we need to collect no information
                     # from filenodes.
-                    group = filerevlog.group(msng_filenode_lst,
-                                             lookup_filenode_link_func(fname))
+                    group = filerevlog.group(nodeiter,
+                                             lambda fnode: missingfnodes[fnode])
                     for chnk in group:
                         self.ui.progress(
                             _('bundling files'), cnt, item=fname, unit=_('chunks'))
                         cnt += 1
                         yield chnk
-                if fname in msng_filenode_set:
-                    # Don't need this anymore, toss it to free memory.
-                    del msng_filenode_set[fname]
             # Signal that no more groups are left.
             yield changegroup.closechunk()
             self.ui.progress(_('bundling files'), None)
@@ -1571,31 +1503,28 @@
                 if log.linkrev(r) in revset:
                     yield log.node(r)
 
-        def lookuprevlink_func(revlog):
-            def lookuprevlink(n):
+        def lookuplinkrev_func(revlog):
+            def lookuplinkrev(n):
                 return cl.node(revlog.linkrev(revlog.rev(n)))
-            return lookuprevlink
+            return lookuplinkrev
 
         def gengroup():
             '''yield a sequence of changegroup chunks (strings)'''
             # construct a list of all changed files
-            changedfiles = {}
+            changedfiles = set()
             mmfs = {}
             collect = changegroup.collector(cl, mmfs, changedfiles)
 
-            cnt = 0
-            for chnk in cl.group(nodes, identity, collect):
+            for cnt, chnk in enumerate(cl.group(nodes, identity, collect)):
                 self.ui.progress(_('bundling changes'), cnt, unit=_('chunks'))
-                cnt += 1
                 yield chnk
             self.ui.progress(_('bundling changes'), None)
 
             mnfst = self.manifest
             nodeiter = gennodelst(mnfst)
-            cnt = 0
-            for chnk in mnfst.group(nodeiter, lookuprevlink_func(mnfst)):
+            for cnt, chnk in enumerate(mnfst.group(nodeiter,
+                                                   lookuplinkrev_func(mnfst))):
                 self.ui.progress(_('bundling manifests'), cnt, unit=_('chunks'))
-                cnt += 1
                 yield chnk
             self.ui.progress(_('bundling manifests'), None)
 
@@ -1609,7 +1538,7 @@
                 if nodeiter:
                     yield changegroup.chunkheader(len(fname))
                     yield fname
-                    lookup = lookuprevlink_func(filerevlog)
+                    lookup = lookuplinkrev_func(filerevlog)
                     for chnk in filerevlog.group(nodeiter, lookup):
                         self.ui.progress(
                             _('bundling files'), cnt, item=fname, unit=_('chunks'))
--- a/mercurial/manifest.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/manifest.py	Sat Aug 14 03:30:35 2010 +0200
@@ -84,7 +84,7 @@
                 hi = start
         end = advance(lo, '\0')
         found = m[lo:end]
-        if cmp(s, found) == 0:
+        if s == found:
             # we know that after the null there are 40 bytes of sha1
             end = advance(end + 40, '\n')
             return (lo, end + 1)
--- a/mercurial/merge.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/merge.py	Sat Aug 14 03:30:35 2010 +0200
@@ -73,7 +73,7 @@
 def _checkunknown(wctx, mctx):
     "check for collisions between unknown files and files in mctx"
     for f in wctx.unknown():
-        if f in mctx and mctx[f].cmp(wctx[f].data()):
+        if f in mctx and mctx[f].cmp(wctx[f]):
             raise util.Abort(_("untracked file in working directory differs"
                                " from file in requested revision: '%s'") % f)
 
@@ -117,7 +117,7 @@
 
 def manifestmerge(repo, p1, p2, pa, overwrite, partial):
     """
-    Merge p1 and p2 with ancestor ma and generate merge action list
+    Merge p1 and p2 with ancestor pa and generate merge action list
 
     overwrite = whether we clobber working files
     partial = function to filter file lists
--- a/mercurial/patch.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/patch.py	Sat Aug 14 03:30:35 2010 +0200
@@ -927,8 +927,8 @@
     createfunc = hunk.createfile
     missing = not goodb and not gooda and not createfunc()
 
-    # some diff programs apparently produce create patches where the
-    # afile is not /dev/null, but afile starts with bfile
+    # some diff programs apparently produce patches where the afile is
+    # not /dev/null, but afile starts with bfile
     abasedir = afile[:afile.rfind('/') + 1]
     bbasedir = bfile[:bfile.rfind('/') + 1]
     if missing and abasedir == bbasedir and afile.startswith(bfile):
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mercurial/py3kcompat.py	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,65 @@
+# py3kcompat.py - compatibility definitions for running hg in py3k
+#
+# Copyright 2010 Renato Cunha <renatoc@gmail.com>
+#
+# This software may be used and distributed according to the terms of the
+# GNU General Public License version 2 or any later version.
+
+import os, builtins
+
+from numbers import Number
+
+def bytesformatter(format, args):
+    '''Custom implementation of a formatter for bytestrings.
+
+    This function currently relias on the string formatter to do the
+    formatting and always returns bytes objects.
+
+    >>> bytesformatter(20, 10)
+    0
+    >>> bytesformatter('unicode %s, %s!', ('string', 'foo'))
+    b'unicode string, foo!'
+    >>> bytesformatter(b'test %s', 'me')
+    b'test me'
+    >>> bytesformatter('test %s', 'me')
+    b'test me'
+    >>> bytesformatter(b'test %s', b'me')
+    b'test me'
+    >>> bytesformatter('test %s', b'me')
+    b'test me'
+    >>> bytesformatter('test %d: %s', (1, b'result'))
+    b'test 1: result'
+    '''
+    # The current implementation just converts from bytes to unicode, do
+    # what's needed and then convert the results back to bytes.
+    # Another alternative is to use the Python C API implementation.
+    if isinstance(format, Number):
+        # If the fixer erroneously passes a number remainder operation to
+        # bytesformatter, we just return the correct operation
+        return format % args
+    if isinstance(format, bytes):
+        format = format.decode('utf-8', 'surrogateescape')
+    if isinstance(args, bytes):
+        args = args.decode('utf-8', 'surrogateescape')
+    if isinstance(args, tuple):
+        newargs = []
+        for arg in args:
+            if isinstance(arg, bytes):
+                arg = arg.decode('utf-8', 'surrogateescape')
+            newargs.append(arg)
+        args = tuple(newargs)
+    ret = format % args
+    return ret.encode('utf-8', 'surrogateescape')
+builtins.bytesformatter = bytesformatter
+
+# Create bytes equivalents for os.environ values
+for key in list(os.environ.keys()):
+    # UTF-8 is fine for us
+    bkey = key.encode('utf-8', 'surrogateescape')
+    bvalue = os.environ[key].encode('utf-8', 'surrogateescape')
+    os.environ[bkey] = bvalue
+
+if __name__ == '__main__':
+    import doctest
+    doctest.testmod()
+
--- a/mercurial/repair.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/repair.py	Sat Aug 14 03:30:35 2010 +0200
@@ -11,14 +11,18 @@
 from i18n import _
 import os
 
-def _bundle(repo, bases, heads, node, suffix, extranodes=None):
+def _bundle(repo, bases, heads, node, suffix, extranodes=None, compress=True):
     """create a bundle with the specified revisions as a backup"""
     cg = repo.changegroupsubset(bases, heads, 'strip', extranodes)
     backupdir = repo.join("strip-backup")
     if not os.path.isdir(backupdir):
         os.mkdir(backupdir)
     name = os.path.join(backupdir, "%s-%s.hg" % (short(node), suffix))
-    return changegroup.writebundle(cg, name, "HG10BZ")
+    if compress:
+        bundletype = "HG10BZ"
+    else:
+        bundletype = "HG10UN"
+    return changegroup.writebundle(cg, name, bundletype)
 
 def _collectfiles(repo, striprev):
     """find out the filelogs affected by the strip"""
@@ -69,6 +73,8 @@
     # TODO delete the undo files, and handle undo of merge sets
     striprev = cl.rev(node)
 
+    keeppartialbundle = backup == 'strip'
+
     # Some revisions with rev > striprev may not be descendants of striprev.
     # We have to find these revisions and put them in a bundle, so that
     # we can restore them after the truncations.
@@ -110,8 +116,9 @@
         backupfile = _bundle(repo, [node], cl.heads(), node, 'backup')
         repo.ui.status(_("saved backup bundle to %s\n") % backupfile)
     if saveheads or extranodes:
+        # do not compress partial bundle if we remove it from disk later
         chgrpfile = _bundle(repo, savebases, saveheads, node, 'temp',
-                            extranodes)
+                            extranodes=extranodes, compress=keeppartialbundle)
 
     mfst = repo.manifest
 
@@ -146,7 +153,7 @@
             if not repo.ui.verbose:
                 repo.ui.popbuffer()
             f.close()
-            if backup != "strip":
+            if not keeppartialbundle:
                 os.unlink(chgrpfile)
     except:
         if backupfile:
--- a/mercurial/revlog.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/revlog.py	Sat Aug 14 03:30:35 2010 +0200
@@ -23,13 +23,19 @@
 _decompress = zlib.decompress
 _sha = util.sha1
 
-# revlog flags
+# revlog header flags
 REVLOGV0 = 0
 REVLOGNG = 1
 REVLOGNGINLINEDATA = (1 << 16)
+REVLOGSHALLOW = (1 << 17)
 REVLOG_DEFAULT_FLAGS = REVLOGNGINLINEDATA
 REVLOG_DEFAULT_FORMAT = REVLOGNG
 REVLOG_DEFAULT_VERSION = REVLOG_DEFAULT_FORMAT | REVLOG_DEFAULT_FLAGS
+REVLOGNG_FLAGS = REVLOGNGINLINEDATA | REVLOGSHALLOW
+
+# revlog index flags
+REVIDX_PUNCHED_FLAG = 2
+REVIDX_KNOWN_FLAGS = REVIDX_PUNCHED_FLAG
 
 # amount of data read unconditionally, should be >= 4
 # when not inline: threshold for using lazy index
@@ -131,7 +137,7 @@
         self.dataf = dataf
         self.s = struct.calcsize(indexformatng)
         self.datasize = size
-        self.l = size / self.s
+        self.l = size // self.s
         self.index = [None] * self.l
         self.map = {nullid: nullrev}
         self.allmap = 0
@@ -176,8 +182,8 @@
                 # limit blocksize so that we don't get too much data.
                 blocksize = max(self.datasize - blockstart, 0)
             data = self.dataf.read(blocksize)
-        lend = len(data) / self.s
-        i = blockstart / self.s
+        lend = len(data) // self.s
+        i = blockstart // self.s
         off = 0
         # lazyindex supports __delitem__
         if lend > len(self.index) - i:
@@ -420,7 +426,7 @@
     remove data, and can use some simple techniques to avoid the need
     for locking while reading.
     """
-    def __init__(self, opener, indexfile):
+    def __init__(self, opener, indexfile, shallowroot=None):
         """
         create a revlog object
 
@@ -434,12 +440,15 @@
         self._chunkcache = (0, '')
         self.nodemap = {nullid: nullrev}
         self.index = []
+        self._shallowroot = shallowroot
 
         v = REVLOG_DEFAULT_VERSION
         if hasattr(opener, 'options') and 'defversion' in opener.options:
             v = opener.options['defversion']
             if v & REVLOGNG:
                 v |= REVLOGNGINLINEDATA
+        if shallowroot:
+            v |= REVLOGSHALLOW
 
         i = ''
         try:
@@ -456,12 +465,13 @@
 
         self.version = v
         self._inline = v & REVLOGNGINLINEDATA
+        self._shallow = v & REVLOGSHALLOW
         flags = v & ~0xFFFF
         fmt = v & 0xFFFF
         if fmt == REVLOGV0 and flags:
             raise RevlogError(_("index %s unknown flags %#04x for format v0")
                               % (self.indexfile, flags >> 16))
-        elif fmt == REVLOGNG and flags & ~REVLOGNGINLINEDATA:
+        elif fmt == REVLOGNG and flags & ~REVLOGNG_FLAGS:
             raise RevlogError(_("index %s unknown flags %#04x for revlogng")
                               % (self.indexfile, flags >> 16))
         elif fmt > REVLOGNG:
@@ -533,6 +543,8 @@
         return self.index[rev][1]
     def base(self, rev):
         return self.index[rev][3]
+    def flags(self, rev):
+        return self.index[rev][0] & 0xFFFF
 
     def size(self, rev):
         """return the length of the uncompressed text for a given revision"""
@@ -1020,9 +1032,9 @@
         base = self.base(rev)
 
         # check rev flags
-        if self.index[rev][0] & 0xFFFF:
+        if self.flags(rev) & ~REVIDX_KNOWN_FLAGS:
             raise RevlogError(_('incompatible revision flag %x') %
-                              (self.index[rev][0] & 0xFFFF))
+                              (self.flags(rev) & ~REVIDX_KNOWN_FLAGS))
 
         # do we have useful data cached?
         if self._cache and self._cache[1] >= base and self._cache[1] < rev:
@@ -1040,7 +1052,8 @@
         bins = [self._chunk(r) for r in xrange(base + 1, rev + 1)]
         text = mdiff.patches(text, bins)
         p1, p2 = self.parents(node)
-        if node != hash(text, p1, p2):
+        if (node != hash(text, p1, p2) and
+            not (self.flags(rev) & REVIDX_PUNCHED_FLAG)):
             raise RevlogError(_("integrity check failed on %s:%d")
                               % (self.indexfile, rev))
 
@@ -1126,7 +1139,9 @@
 
         # full versions are inserted when the needed deltas
         # become comparable to the uncompressed text
-        if not curr or dist > len(text) * 2:
+        # or the base revision is punched
+        if (not curr or dist > len(text) * 2 or
+            (self.flags(base) & REVIDX_PUNCHED_FLAG)):
             data = compress(text)
             l = len(data[1]) + len(data[0])
             base = curr
@@ -1196,14 +1211,7 @@
                 d = self.revdiff(a, b)
             yield changegroup.chunkheader(len(meta) + len(d))
             yield meta
-            if len(d) > 2**20:
-                pos = 0
-                while pos < len(d):
-                    pos2 = pos + 2 ** 18
-                    yield d[pos:pos2]
-                    pos = pos2
-            else:
-                yield d
+            yield d
 
         yield changegroup.closechunk()
 
--- a/mercurial/revset.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/revset.py	Sat Aug 14 03:30:35 2010 +0200
@@ -195,6 +195,14 @@
             return [m]
     return []
 
+def minrev(repo, subset, x):
+    s = getset(repo, subset, x)
+    if s:
+        m = min(s)
+        if m in subset:
+            return [m]
+    return []
+
 def limit(repo, subset, x):
     l = getargs(x, 2, 2, _("limit wants two arguments"))
     try:
@@ -466,6 +474,7 @@
     "keyword": keyword,
     "limit": limit,
     "max": maxrev,
+    "min": minrev,
     "merge": merge,
     "modifies": modifies,
     "outgoing": outgoing,
--- a/mercurial/sshrepo.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/sshrepo.py	Sat Aug 14 03:30:35 2010 +0200
@@ -5,10 +5,9 @@
 # This software may be used and distributed according to the terms of the
 # GNU General Public License version 2 or any later version.
 
-from node import bin, hex
 from i18n import _
-import repo, util, error, encoding
-import re, urllib
+import repo, util, error, wireproto
+import re
 
 class remotelock(object):
     def __init__(self, repo):
@@ -20,14 +19,14 @@
         if self.repo:
             self.release()
 
-class sshrepository(repo.repository):
+class sshrepository(wireproto.wirerepository):
     def __init__(self, ui, path, create=0):
         self._url = path
         self.ui = ui
 
         m = re.match(r'^ssh://(([^@]+)@)?([^:/]+)(:(\d+))?(/(.*))?$', path)
         if not m:
-            self.abort(error.RepoError(_("couldn't parse location %s") % path))
+            self._abort(error.RepoError(_("couldn't parse location %s") % path))
 
         self.user = m.group(2)
         self.host = m.group(3)
@@ -46,7 +45,7 @@
             ui.note(_('running %s\n') % cmd)
             res = util.system(cmd)
             if res != 0:
-                self.abort(error.RepoError(_("could not create remote repo")))
+                self._abort(error.RepoError(_("could not create remote repo")))
 
         self.validate_repo(ui, sshcmd, args, remotecmd)
 
@@ -65,8 +64,8 @@
         self.pipeo, self.pipei, self.pipee = util.popen3(cmd)
 
         # skip any noise generated by remote shell
-        self.do_cmd("hello")
-        r = self.do_cmd("between", pairs=("%s-%s" % ("0"*40, "0"*40)))
+        self._callstream("hello")
+        r = self._callstream("between", pairs=("%s-%s" % ("0"*40, "0"*40)))
         lines = ["", "dummy"]
         max_noise = 500
         while lines[-1] and max_noise:
@@ -79,7 +78,7 @@
             lines.append(l)
             max_noise -= 1
         else:
-            self.abort(error.RepoError(_("no suitable response from remote hg")))
+            self._abort(error.RepoError(_("no suitable response from remote hg")))
 
         self.capabilities = set()
         for l in reversed(lines):
@@ -97,7 +96,7 @@
                 break
             self.ui.status(_("remote: "), l)
 
-    def abort(self, exception):
+    def _abort(self, exception):
         self.cleanup()
         raise exception
 
@@ -114,7 +113,7 @@
 
     __del__ = cleanup
 
-    def do_cmd(self, cmd, **args):
+    def _callstream(self, cmd, **args):
         self.ui.debug("sending %s command\n" % cmd)
         self.pipeo.write("%s\n" % cmd)
         for k, v in sorted(args.iteritems()):
@@ -124,17 +123,35 @@
 
         return self.pipei
 
-    def call(self, cmd, **args):
-        self.do_cmd(cmd, **args)
+    def _call(self, cmd, **args):
+        self._callstream(cmd, **args)
         return self._recv()
 
+    def _callpush(self, cmd, fp, **args):
+        r = self._call(cmd, **args)
+        if r:
+            return '', r
+        while 1:
+            d = fp.read(4096)
+            if not d:
+                break
+            self._send(d)
+        self._send("", flush=True)
+        r = self._recv()
+        if r:
+            return '', r
+        return self._recv(), ''
+
+    def _decompress(self, stream):
+        return stream
+
     def _recv(self):
         l = self.pipei.readline()
         self.readerr()
         try:
             l = int(l)
         except:
-            self.abort(error.ResponseError(_("unexpected response:"), l))
+            self._abort(error.ResponseError(_("unexpected response:"), l))
         return self.pipei.read(l)
 
     def _send(self, data, flush=False):
@@ -146,112 +163,19 @@
         self.readerr()
 
     def lock(self):
-        self.call("lock")
+        self._call("lock")
         return remotelock(self)
 
     def unlock(self):
-        self.call("unlock")
-
-    def lookup(self, key):
-        self.requirecap('lookup', _('look up remote revision'))
-        d = self.call("lookup", key=key)
-        success, data = d[:-1].split(" ", 1)
-        if int(success):
-            return bin(data)
-        else:
-            self.abort(error.RepoError(data))
-
-    def heads(self):
-        d = self.call("heads")
-        try:
-            return map(bin, d[:-1].split(" "))
-        except:
-            self.abort(error.ResponseError(_("unexpected response:"), d))
-
-    def branchmap(self):
-        d = self.call("branchmap")
-        try:
-            branchmap = {}
-            for branchpart in d.splitlines():
-                branchheads = branchpart.split(' ')
-                branchname = urllib.unquote(branchheads[0])
-                # Earlier servers (1.3.x) send branch names in (their) local
-                # charset. The best we can do is assume it's identical to our
-                # own local charset, in case it's not utf-8.
-                try:
-                    branchname.decode('utf-8')
-                except UnicodeDecodeError:
-                    branchname = encoding.fromlocal(branchname)
-                branchheads = [bin(x) for x in branchheads[1:]]
-                branchmap[branchname] = branchheads
-            return branchmap
-        except:
-            raise error.ResponseError(_("unexpected response:"), d)
-
-    def branches(self, nodes):
-        n = " ".join(map(hex, nodes))
-        d = self.call("branches", nodes=n)
-        try:
-            br = [tuple(map(bin, b.split(" "))) for b in d.splitlines()]
-            return br
-        except:
-            self.abort(error.ResponseError(_("unexpected response:"), d))
-
-    def between(self, pairs):
-        n = " ".join(["-".join(map(hex, p)) for p in pairs])
-        d = self.call("between", pairs=n)
-        try:
-            p = [l and map(bin, l.split(" ")) or [] for l in d.splitlines()]
-            return p
-        except:
-            self.abort(error.ResponseError(_("unexpected response:"), d))
-
-    def changegroup(self, nodes, kind):
-        n = " ".join(map(hex, nodes))
-        return self.do_cmd("changegroup", roots=n)
-
-    def changegroupsubset(self, bases, heads, kind):
-        self.requirecap('changegroupsubset', _('look up remote changes'))
-        bases = " ".join(map(hex, bases))
-        heads = " ".join(map(hex, heads))
-        return self.do_cmd("changegroupsubset", bases=bases, heads=heads)
-
-    def unbundle(self, cg, heads, source):
-        '''Send cg (a readable file-like object representing the
-        changegroup to push, typically a chunkbuffer object) to the
-        remote server as a bundle. Return an integer indicating the
-        result of the push (see localrepository.addchangegroup()).'''
-        d = self.call("unbundle", heads=' '.join(map(hex, heads)))
-        if d:
-            # remote may send "unsynced changes"
-            self.abort(error.RepoError(_("push refused: %s") % d))
-
-        while 1:
-            d = cg.read(4096)
-            if not d:
-                break
-            self._send(d)
-
-        self._send("", flush=True)
-
-        r = self._recv()
-        if r:
-            # remote may send "unsynced changes"
-            self.abort(error.RepoError(_("push failed: %s") % r))
-
-        r = self._recv()
-        try:
-            return int(r)
-        except:
-            self.abort(error.ResponseError(_("unexpected response:"), r))
+        self._call("unlock")
 
     def addchangegroup(self, cg, source, url):
         '''Send a changegroup to the remote server.  Return an integer
         similar to unbundle(). DEPRECATED, since it requires locking the
         remote.'''
-        d = self.call("addchangegroup")
+        d = self._call("addchangegroup")
         if d:
-            self.abort(error.RepoError(_("push refused: %s") % d))
+            self._abort(error.RepoError(_("push refused: %s") % d))
         while 1:
             d = cg.read(4096)
             if not d:
@@ -268,26 +192,6 @@
         try:
             return int(r)
         except:
-            self.abort(error.ResponseError(_("unexpected response:"), r))
-
-    def stream_out(self):
-        return self.do_cmd('stream_out')
-
-    def pushkey(self, namespace, key, old, new):
-        if not self.capable('pushkey'):
-            return False
-        d = self.call("pushkey",
-                      namespace=namespace, key=key, old=old, new=new)
-        return bool(int(d))
-
-    def listkeys(self, namespace):
-        if not self.capable('pushkey'):
-            return {}
-        d = self.call("listkeys", namespace=namespace)
-        r = {}
-        for l in d.splitlines():
-            k, v = l.split('\t')
-            r[k.decode('string-escape')] = v.decode('string-escape')
-        return r
+            self._abort(error.ResponseError(_("unexpected response:"), r))
 
 instance = sshrepository
--- a/mercurial/sshserver.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/sshserver.py	Sat Aug 14 03:30:35 2010 +0200
@@ -7,14 +7,10 @@
 # GNU General Public License version 2 or any later version.
 
 from i18n import _
-from node import bin, hex
-import streamclone, util, hook, pushkey
-import os, sys, tempfile, urllib, copy
+import util, hook, wireproto
+import os, sys
 
 class sshserver(object):
-
-    caps = 'unbundle lookup changegroupsubset branchmap pushkey'.split()
-
     def __init__(self, ui, repo):
         self.ui = ui
         self.repo = repo
@@ -29,17 +25,61 @@
         util.set_binary(self.fin)
         util.set_binary(self.fout)
 
-    def getarg(self):
-        argline = self.fin.readline()[:-1]
-        arg, l = argline.split()
-        val = self.fin.read(int(l))
-        return arg, val
+    def getargs(self, args):
+        data = {}
+        keys = args.split()
+        count = len(keys)
+        for n in xrange(len(keys)):
+            argline = self.fin.readline()[:-1]
+            arg, l = argline.split()
+            val = self.fin.read(int(l))
+            if arg not in keys:
+                raise util.Abort("unexpected parameter %r" % arg)
+            if arg == '*':
+                star = {}
+                for n in xrange(int(l)):
+                    arg, l = argline.split()
+                    val = self.fin.read(int(l))
+                    star[arg] = val
+                data['*'] = star
+            else:
+                data[arg] = val
+        return [data[k] for k in keys]
 
-    def respond(self, v):
+    def getarg(self, name):
+        return self.getargs(name)[0]
+
+    def getfile(self, fpout):
+        self.sendresponse('')
+        count = int(self.fin.readline())
+        while count:
+            fpout.write(self.fin.read(count))
+            count = int(self.fin.readline())
+
+    def redirect(self):
+        pass
+
+    def groupchunks(self, changegroup):
+        while True:
+            d = changegroup.read(4096)
+            if not d:
+                break
+            yield d
+
+    def sendresponse(self, v):
         self.fout.write("%d\n" % len(v))
         self.fout.write(v)
         self.fout.flush()
 
+    def sendstream(self, source):
+        for chunk in source.gen:
+            self.fout.write(chunk)
+        self.fout.flush()
+
+    def sendpushresponse(self, rsp):
+        self.sendresponse('')
+        self.sendresponse(str(rsp.res))
+
     def serve_forever(self):
         try:
             while self.serve_one():
@@ -49,57 +89,31 @@
                 self.lock.release()
         sys.exit(0)
 
+    handlers = {
+        str: sendresponse,
+        wireproto.streamres: sendstream,
+        wireproto.pushres: sendpushresponse,
+    }
+
     def serve_one(self):
         cmd = self.fin.readline()[:-1]
-        if cmd:
+        if cmd and cmd in wireproto.commands:
+            rsp = wireproto.dispatch(self.repo, self, cmd)
+            self.handlers[rsp.__class__](self, rsp)
+        elif cmd:
             impl = getattr(self, 'do_' + cmd, None)
             if impl:
-                impl()
-            else: self.respond("")
+                r = impl()
+                if r is not None:
+                    self.sendresponse(r)
+            else: self.sendresponse("")
         return cmd != ''
 
-    def do_lookup(self):
-        arg, key = self.getarg()
-        assert arg == 'key'
-        try:
-            r = hex(self.repo.lookup(key))
-            success = 1
-        except Exception, inst:
-            r = str(inst)
-            success = 0
-        self.respond("%s %s\n" % (success, r))
-
-    def do_branchmap(self):
-        branchmap = self.repo.branchmap()
-        heads = []
-        for branch, nodes in branchmap.iteritems():
-            branchname = urllib.quote(branch)
-            branchnodes = [hex(node) for node in nodes]
-            heads.append('%s %s' % (branchname, ' '.join(branchnodes)))
-        self.respond('\n'.join(heads))
-
-    def do_heads(self):
-        h = self.repo.heads()
-        self.respond(" ".join(map(hex, h)) + "\n")
-
-    def do_hello(self):
-        '''the hello command returns a set of lines describing various
-        interesting things about the server, in an RFC822-like format.
-        Currently the only one defined is "capabilities", which
-        consists of a line in the form:
-
-        capabilities: space separated list of tokens
-        '''
-        caps = copy.copy(self.caps)
-        if streamclone.allowed(self.repo.ui):
-            caps.append('stream=%d' % self.repo.changelog.version)
-        self.respond("capabilities: %s\n" % (' '.join(caps),))
-
     def do_lock(self):
         '''DEPRECATED - allowing remote client to lock repo is not safe'''
 
         self.lock = self.repo.lock()
-        self.respond("")
+        return ""
 
     def do_unlock(self):
         '''DEPRECATED'''
@@ -107,136 +121,20 @@
         if self.lock:
             self.lock.release()
         self.lock = None
-        self.respond("")
-
-    def do_branches(self):
-        arg, nodes = self.getarg()
-        nodes = map(bin, nodes.split(" "))
-        r = []
-        for b in self.repo.branches(nodes):
-            r.append(" ".join(map(hex, b)) + "\n")
-        self.respond("".join(r))
-
-    def do_between(self):
-        arg, pairs = self.getarg()
-        pairs = [map(bin, p.split("-")) for p in pairs.split(" ")]
-        r = []
-        for b in self.repo.between(pairs):
-            r.append(" ".join(map(hex, b)) + "\n")
-        self.respond("".join(r))
-
-    def do_changegroup(self):
-        nodes = []
-        arg, roots = self.getarg()
-        nodes = map(bin, roots.split(" "))
-
-        cg = self.repo.changegroup(nodes, 'serve')
-        while True:
-            d = cg.read(4096)
-            if not d:
-                break
-            self.fout.write(d)
-
-        self.fout.flush()
-
-    def do_changegroupsubset(self):
-        argmap = dict([self.getarg(), self.getarg()])
-        bases = [bin(n) for n in argmap['bases'].split(' ')]
-        heads = [bin(n) for n in argmap['heads'].split(' ')]
-
-        cg = self.repo.changegroupsubset(bases, heads, 'serve')
-        while True:
-            d = cg.read(4096)
-            if not d:
-                break
-            self.fout.write(d)
-
-        self.fout.flush()
+        return ""
 
     def do_addchangegroup(self):
         '''DEPRECATED'''
 
         if not self.lock:
-            self.respond("not locked")
-            return
-
-        self.respond("")
-        r = self.repo.addchangegroup(self.fin, 'serve', self.client_url(),
-                                     lock=self.lock)
-        self.respond(str(r))
-
-    def client_url(self):
-        client = os.environ.get('SSH_CLIENT', '').split(' ', 1)[0]
-        return 'remote:ssh:' + client
-
-    def do_unbundle(self):
-        their_heads = self.getarg()[1].split()
-
-        def check_heads():
-            heads = map(hex, self.repo.heads())
-            return their_heads == [hex('force')] or their_heads == heads
-
-        # fail early if possible
-        if not check_heads():
-            self.respond(_('unsynced changes'))
+            self.sendresponse("not locked")
             return
 
-        self.respond('')
-
-        # write bundle data to temporary file because it can be big
-        fd, tempname = tempfile.mkstemp(prefix='hg-unbundle-')
-        fp = os.fdopen(fd, 'wb+')
-        try:
-            count = int(self.fin.readline())
-            while count:
-                fp.write(self.fin.read(count))
-                count = int(self.fin.readline())
-
-            was_locked = self.lock is not None
-            if not was_locked:
-                self.lock = self.repo.lock()
-            try:
-                if not check_heads():
-                    # someone else committed/pushed/unbundled while we
-                    # were transferring data
-                    self.respond(_('unsynced changes'))
-                    return
-                self.respond('')
-
-                # push can proceed
+        self.sendresponse("")
+        r = self.repo.addchangegroup(self.fin, 'serve', self._client(),
+                                     lock=self.lock)
+        return str(r)
 
-                fp.seek(0)
-                r = self.repo.addchangegroup(fp, 'serve', self.client_url(),
-                                             lock=self.lock)
-                self.respond(str(r))
-            finally:
-                if not was_locked:
-                    self.lock.release()
-                    self.lock = None
-        finally:
-            fp.close()
-            os.unlink(tempname)
-
-    def do_stream_out(self):
-        try:
-            for chunk in streamclone.stream_out(self.repo):
-                self.fout.write(chunk)
-            self.fout.flush()
-        except streamclone.StreamException, inst:
-            self.fout.write(str(inst))
-            self.fout.flush()
-
-    def do_pushkey(self):
-        arg, key = self.getarg()
-        arg, namespace = self.getarg()
-        arg, new = self.getarg()
-        arg, old = self.getarg()
-        r = pushkey.push(self.repo, namespace, key, old, new)
-        self.respond('%s\n' % int(r))
-
-    def do_listkeys(self):
-        arg, namespace = self.getarg()
-        d = pushkey.list(self.repo, namespace).items()
-        t = '\n'.join(['%s\t%s' % (k.encode('string-escape'),
-                                   v.encode('string-escape')) for k, v in d])
-        self.respond(t)
+    def _client(self):
+        client = os.environ.get('SSH_CLIENT', '').split(' ', 1)[0]
+        return 'remote:ssh:' + client
--- a/mercurial/store.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/store.py	Sat Aug 14 03:30:35 2010 +0200
@@ -22,7 +22,7 @@
             .replace(".d/", ".d.hg/"))
 
 def decodedir(path):
-    if not path.startswith('data/'):
+    if not path.startswith('data/') or ".hg/" not in path:
         return path
     return (path
             .replace(".d.hg/", ".d/")
--- a/mercurial/streamclone.py	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,69 +0,0 @@
-# streamclone.py - streaming clone server support for mercurial
-#
-# Copyright 2006 Vadim Gelfer <vadim.gelfer@gmail.com>
-#
-# This software may be used and distributed according to the terms of the
-# GNU General Public License version 2 or any later version.
-
-import util, error
-
-from mercurial import store
-
-class StreamException(Exception):
-    def __init__(self, code):
-        Exception.__init__(self)
-        self.code = code
-    def __str__(self):
-        return '%i\n' % self.code
-
-# if server supports streaming clone, it advertises "stream"
-# capability with value that is version+flags of repo it is serving.
-# client only streams if it can read that repo format.
-
-# stream file format is simple.
-#
-# server writes out line that says how many files, how many total
-# bytes.  separator is ascii space, byte counts are strings.
-#
-# then for each file:
-#
-#   server writes out line that says filename, how many bytes in
-#   file.  separator is ascii nul, byte count is string.
-#
-#   server writes out raw file data.
-
-def allowed(ui):
-    return ui.configbool('server', 'uncompressed', True, untrusted=True)
-
-def stream_out(repo):
-    '''stream out all metadata files in repository.
-    writes to file-like object, must support write() and optional flush().'''
-
-    if not allowed(repo.ui):
-        raise StreamException(1)
-
-    entries = []
-    total_bytes = 0
-    try:
-        # get consistent snapshot of repo, lock during scan
-        lock = repo.lock()
-        try:
-            repo.ui.debug('scanning\n')
-            for name, ename, size in repo.store.walk():
-                entries.append((name, size))
-                total_bytes += size
-        finally:
-            lock.release()
-    except error.LockError:
-        raise StreamException(2)
-
-    yield '0\n'
-    repo.ui.debug('%d files, %d bytes to transfer\n' %
-                  (len(entries), total_bytes))
-    yield '%d %d\n' % (len(entries), total_bytes)
-    for name, size in entries:
-        repo.ui.debug('sending %s (%d bytes)\n' % (name, size))
-        # partially encode name over the wire for backwards compat
-        yield '%s\0%d\n' % (store.encodedir(name), size)
-        for chunk in util.filechunkiter(repo.sopener(name), limit=size):
-            yield chunk
--- a/mercurial/subrepo.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/subrepo.py	Sat Aug 14 03:30:35 2010 +0200
@@ -12,7 +12,7 @@
 
 nullstate = ('', '', 'empty')
 
-def state(ctx):
+def state(ctx, ui):
     """return a state dict, mapping subrepo paths configured in .hgsub
     to tuple: (source from .hgsub, revision from .hgsubstate, kind
     (key in types dict))
@@ -27,6 +27,9 @@
     if '.hgsub' in ctx:
         read('.hgsub')
 
+    for path, src in ui.configitems('subpaths'):
+        p.set('subpaths', path, src, ui.configsource('subpaths', path))
+
     rev = {}
     if '.hgsubstate' in ctx:
         try:
@@ -45,6 +48,14 @@
                 raise util.Abort(_('missing ] in subrepo source'))
             kind, src = src.split(']', 1)
             kind = kind[1:]
+
+        for pattern, repl in p.items('subpaths'):
+            try:
+                src = re.sub(pattern, repl, src, 1)
+            except re.error, e:
+                raise util.Abort(_("bad subrepository pattern in %s: %s")
+                                 % (p.source('subpaths', pattern), e))
+
         state[path] = (src.strip(), rev.get(path, ''), kind)
 
     return state
@@ -182,22 +193,49 @@
         raise util.Abort(_('unknown subrepo type %s') % state[2])
     return types[state[2]](ctx, path, state[:2])
 
-# subrepo classes need to implement the following methods:
-# __init__(self, ctx, path, state)
-# dirty(self): returns true if the dirstate of the subrepo
-#   does not match current stored state
-# commit(self, text, user, date): commit the current changes
-#   to the subrepo with the given log message. Use given
-#   user and date if possible. Return the new state of the subrepo.
-# remove(self): remove the subrepo (should verify the dirstate
-#   is not dirty first)
-# get(self, state): run whatever commands are needed to put the
-#   subrepo into this state
-# merge(self, state): merge currently-saved state with the new state.
-# push(self, force): perform whatever action is analogous to 'hg push'
-#   This may be a no-op on some systems.
+# subrepo classes need to implement the following abstract class:
+
+class abstractsubrepo(object):
+
+    def dirty(self):
+        """returns true if the dirstate of the subrepo does not match
+        current stored state
+        """
+        raise NotImplementedError
+
+    def commit(self, text, user, date):
+        """commit the current changes to the subrepo with the given
+        log message. Use given user and date if possible. Return the
+        new state of the subrepo.
+        """
+        raise NotImplementedError
+
+    def remove(self):
+        """remove the subrepo
 
-class hgsubrepo(object):
+        (should verify the dirstate is not dirty first)
+        """
+        raise NotImplementedError
+
+    def get(self, state):
+        """run whatever commands are needed to put the subrepo into
+        this state
+        """
+        raise NotImplementedError
+
+    def merge(self, state):
+        """merge currently-saved state with the new state."""
+        raise NotImplementedError
+
+    def push(self, force):
+        """perform whatever action is analogous to 'hg push'
+
+        This may be a no-op on some systems.
+        """
+        raise NotImplementedError
+
+
+class hgsubrepo(abstractsubrepo):
     def __init__(self, ctx, path, state):
         self._path = path
         self._state = state
@@ -294,15 +332,15 @@
         other = hg.repository(self._repo.ui, dsturl)
         return self._repo.push(other, force)
 
-class svnsubrepo(object):
+class svnsubrepo(abstractsubrepo):
     def __init__(self, ctx, path, state):
         self._path = path
         self._state = state
         self._ctx = ctx
         self._ui = ctx._repo.ui
 
-    def _svncommand(self, commands):
-        path = os.path.join(self._ctx._repo.origroot, self._path)
+    def _svncommand(self, commands, filename=''):
+        path = os.path.join(self._ctx._repo.origroot, self._path, filename)
         cmd = ['svn'] + commands + [path]
         cmd = [util.shellquote(arg) for arg in cmd]
         cmd = util.quotecommand(' '.join(cmd))
--- a/mercurial/templatekw.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/templatekw.py	Sat Aug 14 03:30:35 2010 +0200
@@ -151,6 +151,11 @@
         branch = encoding.tolocal(branch)
         return showlist('branch', [branch], plural='branches', **args)
 
+def showchildren(**args):
+    ctx = args['ctx']
+    childrevs = ['%d:%s' % (cctx, cctx) for cctx in ctx.children()]
+    return showlist('children', childrevs, **args)
+
 def showdate(repo, ctx, templ, **args):
     return ctx.date()
 
@@ -245,6 +250,7 @@
 keywords = {
     'author': showauthor,
     'branches': showbranches,
+    'children': showchildren,
     'date': showdate,
     'desc': showdescription,
     'diffstat': showdiffstat,
--- a/mercurial/transaction.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/transaction.py	Sat Aug 14 03:30:35 2010 +0200
@@ -115,7 +115,7 @@
     def release(self):
         if self.count > 0:
             self.usages -= 1
-        # of the transaction scopes are left without being closed, fail
+        # if the transaction scopes are left without being closed, fail
         if self.count > 0 and self.usages == 0:
             self._abort()
 
--- a/mercurial/url.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/url.py	Sat Aug 14 03:30:35 2010 +0200
@@ -156,7 +156,7 @@
                 continue
             group, setting = key.split('.', 1)
             gdict = config.setdefault(group, dict())
-            if setting in ('cert', 'key'):
+            if setting in ('username', 'cert', 'key'):
                 val = util.expandpath(val)
             gdict[setting] = val
 
--- a/mercurial/util.h	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/util.h	Sat Aug 14 03:30:35 2010 +0200
@@ -12,6 +12,48 @@
 
 #define IS_PY3K
 #define PyInt_FromLong PyLong_FromLong
+#define PyInt_AsLong PyLong_AsLong
+
+/*
+ Mapping of some of the python < 2.x PyString* functions to py3k's PyUnicode.
+
+ The commented names below represent those that are present in the PyBytes
+ definitions for python < 2.6 (below in this file) that don't have a direct
+ implementation.
+*/
+
+#define PyStringObject PyUnicodeObject
+#define PyString_Type PyUnicode_Type
+
+#define PyString_Check PyUnicode_Check
+#define PyString_CheckExact PyUnicode_CheckExact
+#define PyString_CHECK_INTERNED PyUnicode_CHECK_INTERNED
+#define PyString_AS_STRING PyUnicode_AsLatin1String
+#define PyString_GET_SIZE PyUnicode_GET_SIZE
+
+#define PyString_FromStringAndSize PyUnicode_FromStringAndSize
+#define PyString_FromString PyUnicode_FromString
+#define PyString_FromFormatV PyUnicode_FromFormatV
+#define PyString_FromFormat PyUnicode_FromFormat
+/* #define PyString_Size PyUnicode_GET_SIZE */
+/* #define PyString_AsString */
+/* #define PyString_Repr */
+#define PyString_Concat PyUnicode_Concat
+#define PyString_ConcatAndDel PyUnicode_AppendAndDel
+#define _PyString_Resize PyUnicode_Resize
+/* #define _PyString_Eq */
+#define PyString_Format PyUnicode_Format
+/* #define _PyString_FormatLong */
+/* #define PyString_DecodeEscape */
+#define _PyString_Join PyUnicode_Join
+#define PyString_Decode PyUnicode_Decode
+#define PyString_Encode PyUnicode_Encode
+#define PyString_AsEncodedObject PyUnicode_AsEncodedObject
+#define PyString_AsEncodedString PyUnicode_AsEncodedString
+#define PyString_AsDecodedObject PyUnicode_AsDecodedObject
+#define PyString_AsDecodedString PyUnicode_AsDecodedUnicode
+/* #define PyString_AsStringAndSize */
+#define _PyString_InsertThousandsGrouping _PyUnicode_InsertThousandsGrouping
 
 #endif /* PY_MAJOR_VERSION */
 
--- a/mercurial/util.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/mercurial/util.py	Sat Aug 14 03:30:35 2010 +0200
@@ -38,9 +38,15 @@
 
 import __builtin__
 
-def fakebuffer(sliceable, offset=0):
-    return sliceable[offset:]
-if not hasattr(__builtin__, 'buffer'):
+if sys.version_info[0] < 3:
+    def fakebuffer(sliceable, offset=0):
+        return sliceable[offset:]
+else:
+    def fakebuffer(sliceable, offset=0):
+        return memoryview(sliceable)[offset:]
+try:
+    buffer
+except NameError:
     __builtin__.buffer = fakebuffer
 
 import subprocess
@@ -908,7 +914,17 @@
     def __init__(self, in_iter):
         """in_iter is the iterator that's iterating over the input chunks.
         targetsize is how big a buffer to try to maintain."""
-        self.iter = iter(in_iter)
+        def splitbig(chunks):
+            for chunk in chunks:
+                if len(chunk) > 2**20:
+                    pos = 0
+                    while pos < len(chunk):
+                        end = pos + 2 ** 18
+                        yield chunk[pos:end]
+                        pos = end
+                else:
+                    yield chunk
+        self.iter = splitbig(in_iter)
         self._queue = []
 
     def read(self, l):
@@ -938,8 +954,7 @@
                 buf += chunk
 
         return buf
-
-
+        
 def filechunkiter(f, size=65536, limit=None):
     """Create a generator that produces the data in the file size
     (default 65536) bytes at a time, up to optional limit (default is
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mercurial/wireproto.py	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,332 @@
+# wireproto.py - generic wire protocol support functions
+#
+# Copyright 2005-2010 Matt Mackall <mpm@selenic.com>
+#
+# This software may be used and distributed according to the terms of the
+# GNU General Public License version 2 or any later version.
+
+import urllib, tempfile, os
+from i18n import _
+from node import bin, hex
+import changegroup as changegroupmod
+import repo, error, encoding, util, store
+import pushkey as pushkey_
+
+# list of nodes encoding / decoding
+
+def decodelist(l, sep=' '):
+    return map(bin, l.split(sep))
+
+def encodelist(l, sep=' '):
+    return sep.join(map(hex, l))
+
+# client side
+
+class wirerepository(repo.repository):
+    def lookup(self, key):
+        self.requirecap('lookup', _('look up remote revision'))
+        d = self._call("lookup", key=key)
+        success, data = d[:-1].split(" ", 1)
+        if int(success):
+            return bin(data)
+        self._abort(error.RepoError(data))
+
+    def heads(self):
+        d = self._call("heads")
+        try:
+            return decodelist(d[:-1])
+        except:
+            self.abort(error.ResponseError(_("unexpected response:"), d))
+
+    def branchmap(self):
+        d = self._call("branchmap")
+        try:
+            branchmap = {}
+            for branchpart in d.splitlines():
+                branchname, branchheads = branchpart.split(' ', 1)
+                branchname = urllib.unquote(branchname)
+                # Earlier servers (1.3.x) send branch names in (their) local
+                # charset. The best we can do is assume it's identical to our
+                # own local charset, in case it's not utf-8.
+                try:
+                    branchname.decode('utf-8')
+                except UnicodeDecodeError:
+                    branchname = encoding.fromlocal(branchname)
+                branchheads = decodelist(branchheads)
+                branchmap[branchname] = branchheads
+            return branchmap
+        except TypeError:
+            self._abort(error.ResponseError(_("unexpected response:"), d))
+
+    def branches(self, nodes):
+        n = encodelist(nodes)
+        d = self._call("branches", nodes=n)
+        try:
+            br = [tuple(decodelist(b)) for b in d.splitlines()]
+            return br
+        except:
+            self._abort(error.ResponseError(_("unexpected response:"), d))
+
+    def between(self, pairs):
+        batch = 8 # avoid giant requests
+        r = []
+        for i in xrange(0, len(pairs), batch):
+            n = " ".join([encodelist(p, '-') for p in pairs[i:i + batch]])
+            d = self._call("between", pairs=n)
+            try:
+                r.extend(l and decodelist(l) or [] for l in d.splitlines())
+            except:
+                self._abort(error.ResponseError(_("unexpected response:"), d))
+        return r
+
+    def pushkey(self, namespace, key, old, new):
+        if not self.capable('pushkey'):
+            return False
+        d = self._call("pushkey",
+                      namespace=namespace, key=key, old=old, new=new)
+        return bool(int(d))
+
+    def listkeys(self, namespace):
+        if not self.capable('pushkey'):
+            return {}
+        d = self._call("listkeys", namespace=namespace)
+        r = {}
+        for l in d.splitlines():
+            k, v = l.split('\t')
+            r[k.decode('string-escape')] = v.decode('string-escape')
+        return r
+
+    def stream_out(self):
+        return self._callstream('stream_out')
+
+    def changegroup(self, nodes, kind):
+        n = encodelist(nodes)
+        f = self._callstream("changegroup", roots=n)
+        return self._decompress(f)
+
+    def changegroupsubset(self, bases, heads, kind):
+        self.requirecap('changegroupsubset', _('look up remote changes'))
+        bases = encodelist(bases)
+        heads = encodelist(heads)
+        return self._decompress(self._callstream("changegroupsubset",
+                                                 bases=bases, heads=heads))
+
+    def unbundle(self, cg, heads, source):
+        '''Send cg (a readable file-like object representing the
+        changegroup to push, typically a chunkbuffer object) to the
+        remote server as a bundle. Return an integer indicating the
+        result of the push (see localrepository.addchangegroup()).'''
+
+        ret, output = self._callpush("unbundle", cg, heads=encodelist(heads))
+        if ret == "":
+            raise error.ResponseError(
+                _('push failed:'), output)
+        try:
+            ret = int(ret)
+        except ValueError, err:
+            raise error.ResponseError(
+                _('push failed (unexpected response):'), ret)
+
+        for l in output.splitlines(True):
+            self.ui.status(_('remote: '), l)
+        return ret
+
+# server side
+
+class streamres(object):
+    def __init__(self, gen):
+        self.gen = gen
+
+class pushres(object):
+    def __init__(self, res):
+        self.res = res
+
+def dispatch(repo, proto, command):
+    func, spec = commands[command]
+    args = proto.getargs(spec)
+    return func(repo, proto, *args)
+
+def between(repo, proto, pairs):
+    pairs = [decodelist(p, '-') for p in pairs.split(" ")]
+    r = []
+    for b in repo.between(pairs):
+        r.append(encodelist(b) + "\n")
+    return "".join(r)
+
+def branchmap(repo, proto):
+    branchmap = repo.branchmap()
+    heads = []
+    for branch, nodes in branchmap.iteritems():
+        branchname = urllib.quote(branch)
+        branchnodes = encodelist(nodes)
+        heads.append('%s %s' % (branchname, branchnodes))
+    return '\n'.join(heads)
+
+def branches(repo, proto, nodes):
+    nodes = decodelist(nodes)
+    r = []
+    for b in repo.branches(nodes):
+        r.append(encodelist(b) + "\n")
+    return "".join(r)
+
+def capabilities(repo, proto):
+    caps = 'lookup changegroupsubset branchmap pushkey'.split()
+    if _allowstream(repo.ui):
+        caps.append('stream=%d' % repo.changelog.version)
+    caps.append('unbundle=%s' % ','.join(changegroupmod.bundlepriority))
+    return ' '.join(caps)
+
+def changegroup(repo, proto, roots):
+    nodes = decodelist(roots)
+    cg = repo.changegroup(nodes, 'serve')
+    return streamres(proto.groupchunks(cg))
+
+def changegroupsubset(repo, proto, bases, heads):
+    bases = decodelist(bases)
+    heads = decodelist(heads)
+    cg = repo.changegroupsubset(bases, heads, 'serve')
+    return streamres(proto.groupchunks(cg))
+
+def heads(repo, proto):
+    h = repo.heads()
+    return encodelist(h) + "\n"
+
+def hello(repo, proto):
+    '''the hello command returns a set of lines describing various
+    interesting things about the server, in an RFC822-like format.
+    Currently the only one defined is "capabilities", which
+    consists of a line in the form:
+
+    capabilities: space separated list of tokens
+    '''
+    return "capabilities: %s\n" % (capabilities(repo, proto))
+
+def listkeys(repo, proto, namespace):
+    d = pushkey_.list(repo, namespace).items()
+    t = '\n'.join(['%s\t%s' % (k.encode('string-escape'),
+                               v.encode('string-escape')) for k, v in d])
+    return t
+
+def lookup(repo, proto, key):
+    try:
+        r = hex(repo.lookup(key))
+        success = 1
+    except Exception, inst:
+        r = str(inst)
+        success = 0
+    return "%s %s\n" % (success, r)
+
+def pushkey(repo, proto, namespace, key, old, new):
+    r = pushkey_.push(repo, namespace, key, old, new)
+    return '%s\n' % int(r)
+
+def _allowstream(ui):
+    return ui.configbool('server', 'uncompressed', True, untrusted=True)
+
+def stream(repo, proto):
+    '''If the server supports streaming clone, it advertises the "stream"
+    capability with a value representing the version and flags of the repo
+    it is serving. Client checks to see if it understands the format.
+
+    The format is simple: the server writes out a line with the amount
+    of files, then the total amount of bytes to be transfered (separated
+    by a space). Then, for each file, the server first writes the filename
+    and filesize (separated by the null character), then the file contents.
+    '''
+
+    if not _allowstream(repo.ui):
+        return '1\n'
+
+    entries = []
+    total_bytes = 0
+    try:
+        # get consistent snapshot of repo, lock during scan
+        lock = repo.lock()
+        try:
+            repo.ui.debug('scanning\n')
+            for name, ename, size in repo.store.walk():
+                entries.append((name, size))
+                total_bytes += size
+        finally:
+            lock.release()
+    except error.LockError:
+        return '2\n' # error: 2
+
+    def streamer(repo, entries, total):
+        '''stream out all metadata files in repository.'''
+        yield '0\n' # success
+        repo.ui.debug('%d files, %d bytes to transfer\n' %
+                      (len(entries), total_bytes))
+        yield '%d %d\n' % (len(entries), total_bytes)
+        for name, size in entries:
+            repo.ui.debug('sending %s (%d bytes)\n' % (name, size))
+            # partially encode name over the wire for backwards compat
+            yield '%s\0%d\n' % (store.encodedir(name), size)
+            for chunk in util.filechunkiter(repo.sopener(name), limit=size):
+                yield chunk
+
+    return streamres(streamer(repo, entries, total_bytes))
+
+def unbundle(repo, proto, heads):
+    their_heads = decodelist(heads)
+
+    def check_heads():
+        heads = repo.heads()
+        return their_heads == ['force'] or their_heads == heads
+
+    # fail early if possible
+    if not check_heads():
+        return 'unsynced changes'
+
+    # write bundle data to temporary file because it can be big
+    fd, tempname = tempfile.mkstemp(prefix='hg-unbundle-')
+    fp = os.fdopen(fd, 'wb+')
+    r = 0
+    proto.redirect()
+    try:
+        proto.getfile(fp)
+        lock = repo.lock()
+        try:
+            if not check_heads():
+                # someone else committed/pushed/unbundled while we
+                # were transferring data
+                return 'unsynced changes'
+
+            # push can proceed
+            fp.seek(0)
+            header = fp.read(6)
+            if header.startswith('HG'):
+                if not header.startswith('HG10'):
+                    raise ValueError('unknown bundle version')
+                elif header not in changegroupmod.bundletypes:
+                    raise ValueError('unknown bundle compression type')
+            gen = changegroupmod.unbundle(header, fp)
+
+            try:
+                r = repo.addchangegroup(gen, 'serve', proto._client(),
+                                        lock=lock)
+            except util.Abort, inst:
+                sys.stderr.write("abort: %s\n" % inst)
+        finally:
+            lock.release()
+            return pushres(r)
+
+    finally:
+        fp.close()
+        os.unlink(tempname)
+
+commands = {
+    'between': (between, 'pairs'),
+    'branchmap': (branchmap, ''),
+    'branches': (branches, 'nodes'),
+    'capabilities': (capabilities, ''),
+    'changegroup': (changegroup, 'roots'),
+    'changegroupsubset': (changegroupsubset, 'bases heads'),
+    'heads': (heads, ''),
+    'hello': (hello, ''),
+    'listkeys': (listkeys, 'namespace'),
+    'lookup': (lookup, 'key'),
+    'pushkey': (pushkey, 'namespace key old new'),
+    'stream_out': (stream, ''),
+    'unbundle': (unbundle, 'heads'),
+}
--- a/setup.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/setup.py	Sat Aug 14 03:30:35 2010 +0200
@@ -9,6 +9,17 @@
 if not hasattr(sys, 'version_info') or sys.version_info < (2, 4, 0, 'final'):
     raise SystemExit("Mercurial requires Python 2.4 or later.")
 
+if sys.version_info[0] >= 3:
+    def b(s):
+        '''A helper function to emulate 2.6+ bytes literals using string
+        literals.'''
+        return s.encode('latin1')
+else:
+    def b(s):
+        '''A helper function to emulate 2.6+ bytes literals using string
+        literals.'''
+        return s
+
 # Solaris Python packaging brain damage
 try:
     import hashlib
@@ -114,8 +125,8 @@
     # fine, we don't want to load it anyway.  Python may warn about
     # a missing __init__.py in mercurial/locale, we also ignore that.
     err = [e for e in err.splitlines()
-           if not e.startswith('Not trusting file') \
-              and not e.startswith('warning: Not importing')]
+           if not e.startswith(b('Not trusting file')) \
+              and not e.startswith(b('warning: Not importing'))]
     if err:
         return ''
     return out
@@ -275,7 +286,8 @@
     cc = new_compiler()
     if hasfunction(cc, 'inotify_add_watch'):
         inotify = Extension('hgext.inotify.linux._inotify',
-                            ['hgext/inotify/linux/_inotify.c'])
+                            ['hgext/inotify/linux/_inotify.c'],
+                            ['mercurial'])
         inotify.optional = True
         extmodules.append(inotify)
         packages.extend(['hgext.inotify', 'hgext.inotify.linux'])
--- a/tests/run-tests.py	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/run-tests.py	Sat Aug 14 03:30:35 2010 +0200
@@ -52,6 +52,7 @@
 import sys
 import tempfile
 import time
+import re
 
 closefds = os.name == 'posix'
 def Popen4(cmd, bufsize=-1):
@@ -441,6 +442,94 @@
 def alarmed(signum, frame):
     raise Timeout
 
+def pytest(test, options):
+    py3kswitch = options.py3k_warnings and ' -3' or ''
+    cmd = '%s%s "%s"' % (PYTHON, py3kswitch, test)
+    vlog("# Running", cmd)
+    return run(cmd, options)
+
+def shtest(test, options):
+    cmd = '"%s"' % test
+    vlog("# Running", cmd)
+    return run(cmd, options)
+
+def battest(test, options):
+    # To reliably get the error code from batch files on WinXP,
+    # the "cmd /c call" prefix is needed. Grrr
+    cmd = 'cmd /c call "%s"' % testpath
+    vlog("# Running", cmd)
+    return run(cmd, options)
+
+def tsttest(test, options):
+    t = open(test)
+    out = []
+    script = []
+    salt = "SALT" + str(time.time())
+
+    pos = prepos = -1
+    after = {}
+    expected = {}
+    for n, l in enumerate(t):
+        if l.startswith('  $ '): # commands
+            after.setdefault(pos, []).append(l)
+            prepos = pos
+            pos = n
+            script.append('echo %s %s\n' % (salt, n))
+            script.append(l[4:])
+        elif l.startswith('  > '): # continuations
+            after.setdefault(prepos, []).append(l)
+            script.append(l[4:])
+        elif l.startswith('  '): # results
+            # queue up a list of expected results
+            expected.setdefault(pos, []).append(l[2:])
+        else:
+            # non-command/result - queue up for merged output
+            after.setdefault(pos, []).append(l)
+
+    fd, name = tempfile.mkstemp(suffix='hg-tst')
+
+    try:
+        for l in script:
+            os.write(fd, l)
+        os.close(fd)
+
+        cmd = '/bin/sh "%s"' % name
+        vlog("# Running", cmd)
+        exitcode, output = run(cmd, options)
+    finally:
+        os.remove(name)
+
+    def rematch(el, l):
+        try:
+            return re.match(el, l)
+        except re.error:
+            # el is an invalid regex
+            return False
+
+    pos = -1
+    postout = []
+    for n, l in enumerate(output):
+        if l.startswith(salt):
+            if pos in after:
+                postout += after.pop(pos)
+            pos = int(l.split()[1])
+        else:
+            el = None
+            if pos in expected and expected[pos]:
+                el = expected[pos].pop(0)
+
+            if el == l: # perfect match (fast)
+                postout.append("  " + l)
+            elif el and rematch(el, l): # fallback regex match
+                postout.append("  " + el)
+            else: # mismatch - let diff deal with it
+                postout.append("  " + l)
+
+    if pos in after:
+        postout += after.pop(pos)
+
+    return exitcode, postout
+
 def run(cmd, options):
     """Run command in a sub-process, capturing the output (stdout and stderr).
     Return a tuple (exitcode, output).  output is None in debug mode."""
@@ -537,15 +626,15 @@
     lctest = test.lower()
 
     if lctest.endswith('.py') or firstline == '#!/usr/bin/env python':
-        py3kswitch = options.py3k_warnings and ' -3' or ''
-        cmd = '%s%s "%s"' % (PYTHON, py3kswitch, testpath)
+        runner = pytest
     elif lctest.endswith('.bat'):
         # do not run batch scripts on non-windows
         if os.name != 'nt':
             return skip("batch script")
-        # To reliably get the error code from batch files on WinXP,
-        # the "cmd /c call" prefix is needed. Grrr
-        cmd = 'cmd /c call "%s"' % testpath
+        runner = battest
+    elif lctest.endswith('.t'):
+        runner = tsttest
+        ref = testpath
     else:
         # do not run shell scripts on windows
         if os.name == 'nt':
@@ -555,7 +644,7 @@
             return fail("does not exist")
         elif not os.access(testpath, os.X_OK):
             return skip("not executable")
-        cmd = '"%s"' % testpath
+        runner = shtest
 
     # Make a tmp subdirectory to work in
     tmpd = os.path.join(HGTMP, test)
@@ -565,8 +654,7 @@
     if options.timeout > 0:
         signal.alarm(options.timeout)
 
-    vlog("# Running", cmd)
-    ret, out = run(cmd, options)
+    ret, out = runner(testpath, options)
     vlog("# Ret was:", ret)
 
     if options.timeout > 0:
@@ -807,7 +895,10 @@
                     print "Accept this change? [n] ",
                     answer = sys.stdin.readline().strip()
                     if answer.lower() in "y yes".split():
-                        rename(test + ".err", test + ".out")
+                        if test.endswith(".t"):
+                            rename(test + ".err", test)
+                        else:
+                            rename(test + ".err", test + ".out")
                         tested += 1
                         fails.pop()
                         continue
@@ -944,7 +1035,7 @@
     for test in args:
         if (test.startswith("test-") and '~' not in test and
             ('.' not in test or test.endswith('.py') or
-             test.endswith('.bat'))):
+             test.endswith('.bat') or test.endswith('.t'))):
             tests.append(test)
     if not tests:
         print "# Ran 0 tests, 0 skipped, 0 failed."
--- a/tests/test-1102	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,16 +0,0 @@
-#!/bin/sh
-
-rm -rf a
-hg init a
-cd a
-echo a > a
-hg ci -Am0
-hg tag t1 # 1
-hg tag --remove t1 # 2
-
-hg co 1
-hg tag -r0 t1
-hg tags
-
-
-
--- a/tests/test-1102.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,4 +0,0 @@
-adding a
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-tip                                3:a49829c4fc11
-t1                                 0:f7b1eb17ad24
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-1102.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,16 @@
+  $ rm -rf a
+  $ hg init a
+  $ cd a
+  $ echo a > a
+  $ hg ci -Am0
+  adding a
+  $ hg tag t1 # 1
+  $ hg tag --remove t1 # 2
+
+  $ hg co 1
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg tag -r0 t1
+  $ hg tags
+  tip                                3:a49829c4fc11
+  t1                                 0:f7b1eb17ad24
+
--- a/tests/test-586	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,49 +0,0 @@
-#!/bin/sh
-# a test for issue586
-
-hg init a
-cd a
-echo a > a
-hg ci -Ama
-
-hg init ../b
-cd ../b
-echo b > b
-hg ci -Amb
-
-hg pull -f ../a
-hg merge
-hg rm -f a
-hg ci -Amc
-
-hg st -A
-cd ..
-
-# a test for issue 1433, related to issue586
-echo % create test repos
-hg init repoa
-touch repoa/a
-hg -R repoa ci -Am adda
-
-hg init repob
-touch repob/b
-hg -R repob ci -Am addb
-
-hg init repoc
-cd repoc
-hg pull ../repoa
-hg update
-mkdir tst
-hg mv * tst
-hg ci -m "import a in tst"
-hg pull -f ../repob
-echo % merge both repos
-hg merge
-mkdir src
-echo % move b content
-hg mv b src
-hg ci -m "import b in src"
-hg manifest
-
-
-
--- a/tests/test-586.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,38 +0,0 @@
-adding a
-adding b
-pulling from ../a
-searching for changes
-warning: repository is unrelated
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-C b
-% create test repos
-adding a
-adding b
-pulling from ../repoa
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-(run 'hg update' to get a working copy)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-pulling from ../repob
-searching for changes
-warning: repository is unrelated
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-% merge both repos
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-% move b content
-src/b
-tst/a
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-586.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,87 @@
+a test for issue586
+
+  $ hg init a
+  $ cd a
+  $ echo a > a
+  $ hg ci -Ama
+  adding a
+
+  $ hg init ../b
+  $ cd ../b
+  $ echo b > b
+  $ hg ci -Amb
+  adding b
+
+  $ hg pull -f ../a
+  pulling from ../a
+  searching for changes
+  warning: repository is unrelated
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+  $ hg merge
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg rm -f a
+  $ hg ci -Amc
+
+  $ hg st -A
+  C b
+  $ cd ..
+
+a test for issue 1433, related to issue586
+
+create test repos
+
+  $ hg init repoa
+  $ touch repoa/a
+  $ hg -R repoa ci -Am adda
+  adding a
+
+  $ hg init repob
+  $ touch repob/b
+  $ hg -R repob ci -Am addb
+  adding b
+
+  $ hg init repoc
+  $ cd repoc
+  $ hg pull ../repoa
+  pulling from ../repoa
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  (run 'hg update' to get a working copy)
+  $ hg update
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ mkdir tst
+  $ hg mv * tst
+  $ hg ci -m "import a in tst"
+  $ hg pull -f ../repob
+  pulling from ../repob
+  searching for changes
+  warning: repository is unrelated
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+
+merge both repos
+
+  $ hg merge
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ mkdir src
+
+move b content
+
+  $ hg mv b src
+  $ hg ci -m "import b in src"
+  $ hg manifest
+  src/b
+  tst/a
+
--- a/tests/test-abort-checkin	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,28 +0,0 @@
-#!/bin/sh
-
-cat > abortcommit.py <<EOF
-from mercurial import util
-
-def hook(**args):
-    raise util.Abort("no commits allowed")
-
-def reposetup(ui, repo):
-    repo.ui.setconfig("hooks", "pretxncommit.nocommits", hook)
-EOF
-abspath=`pwd`/abortcommit.py
-
-echo "[extensions]" >> $HGRCPATH
-echo "mq=" >> $HGRCPATH
-echo "abortcommit = $abspath" >> $HGRCPATH
-
-hg init foo
-cd foo
-echo foo > foo
-hg add foo
-
-# mq may keep a reference to the repository so __del__ will not be called
-# and .hg/journal.dirstate will not be deleted:
-hg ci -m foo
-hg ci -m foo
-
-exit 0
--- a/tests/test-abort-checkin.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,8 +0,0 @@
-error: pretxncommit.nocommits hook failed: no commits allowed
-transaction abort!
-rollback completed
-abort: no commits allowed
-error: pretxncommit.nocommits hook failed: no commits allowed
-transaction abort!
-rollback completed
-abort: no commits allowed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-abort-checkin.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,33 @@
+  $ cat > abortcommit.py <<EOF
+  > from mercurial import util
+  > def hook(**args):
+  >     raise util.Abort("no commits allowed")
+  > def reposetup(ui, repo):
+  >     repo.ui.setconfig("hooks", "pretxncommit.nocommits", hook)
+  > EOF
+  $ abspath=`pwd`/abortcommit.py
+
+  $ echo "[extensions]" >> $HGRCPATH
+  $ echo "mq=" >> $HGRCPATH
+  $ echo "abortcommit = $abspath" >> $HGRCPATH
+
+  $ hg init foo
+  $ cd foo
+  $ echo foo > foo
+  $ hg add foo
+
+mq may keep a reference to the repository so __del__ will not be
+called and .hg/journal.dirstate will not be deleted:
+
+  $ hg ci -m foo
+  error: pretxncommit.nocommits hook failed: no commits allowed
+  transaction abort!
+  rollback completed
+  abort: no commits allowed
+  $ hg ci -m foo
+  error: pretxncommit.nocommits hook failed: no commits allowed
+  transaction abort!
+  rollback completed
+  abort: no commits allowed
+
+  $ exit 0
--- a/tests/test-acl	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,176 +0,0 @@
-#!/bin/sh
-
-do_push()
-{
-    user=$1
-    shift
-
-    echo "Pushing as user $user"
-    echo 'hgrc = """'
-    sed -e 1,2d b/.hg/hgrc | grep -v fakegroups.py
-    echo '"""'
-    if test -f acl.config; then
-	echo 'acl.config = """'
-	cat acl.config
-	echo '"""'
-    fi
-    # On AIX /etc/profile sets LOGNAME read-only. So
-    #  LOGNAME=$user hg --cws a --debug push ../b
-    # fails with "This variable is read only."
-    # Use env to work around this.
-    env LOGNAME=$user hg --cwd a --debug push ../b
-    hg --cwd b rollback
-    hg --cwd b --quiet tip
-    echo
-}
-
-init_config()
-{
-cat > fakegroups.py <<EOF
-from hgext import acl
-def fakegetusers(ui, group):
-    try:
-        return acl._getusersorig(ui, group)
-    except:
-        return ["fred", "betty"]
-acl._getusersorig = acl._getusers
-acl._getusers = fakegetusers
-EOF
-
-rm -f acl.config
-cat > $config <<EOF
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[extensions]
-f=`pwd`/fakegroups.py
-EOF
-}
-
-hg init a
-cd a
-mkdir foo foo/Bar quux
-echo 'in foo' > foo/file.txt
-echo 'in foo/Bar' > foo/Bar/file.txt
-echo 'in quux' > quux/file.py
-hg add -q
-hg ci -m 'add files' -d '1000000 0'
-echo >> foo/file.txt
-hg ci -m 'change foo/file' -d '1000001 0'
-echo >> foo/Bar/file.txt
-hg ci -m 'change foo/Bar/file' -d '1000002 0'
-echo >> quux/file.py
-hg ci -m 'change quux/file' -d '1000003 0'
-hg tip --quiet
-
-cd ..
-hg clone -r 0 a b
-
-echo '[extensions]' >> $HGRCPATH
-echo 'acl =' >> $HGRCPATH
-
-config=b/.hg/hgrc
-
-echo
-
-echo 'Extension disabled for lack of a hook'
-do_push fred
-
-echo '[hooks]' >> $config
-echo 'pretxnchangegroup.acl = python:hgext.acl.hook' >> $config
-
-echo 'Extension disabled for lack of acl.sources'
-do_push fred
-
-echo 'No [acl.allow]/[acl.deny]'
-echo '[acl]' >> $config
-echo 'sources = push' >> $config
-do_push fred
-
-echo 'Empty [acl.allow]'
-echo '[acl.allow]' >> $config
-do_push fred
-
-echo 'fred is allowed inside foo/'
-echo 'foo/** = fred' >> $config
-do_push fred
-
-echo 'Empty [acl.deny]'
-echo '[acl.deny]' >> $config
-do_push barney
-
-echo 'fred is allowed inside foo/, but not foo/bar/ (case matters)'
-echo 'foo/bar/** = fred' >> $config
-do_push fred
-
-echo 'fred is allowed inside foo/, but not foo/Bar/'
-echo 'foo/Bar/** = fred' >> $config
-do_push fred
-
-echo 'barney is not mentioned => not allowed anywhere'
-do_push barney
-
-echo 'barney is allowed everywhere'
-echo '[acl.allow]' >> $config
-echo '** = barney' >> $config
-do_push barney
-
-echo 'wilma can change files with a .txt extension'
-echo '**/*.txt = wilma' >> $config
-do_push wilma
-
-echo 'file specified by acl.config does not exist'
-echo '[acl]' >> $config
-echo 'config = ../acl.config' >> $config
-do_push barney
-
-echo 'betty is allowed inside foo/ by a acl.config file'
-echo '[acl.allow]' >> acl.config
-echo 'foo/** = betty' >> acl.config
-do_push betty
-
-echo 'acl.config can set only [acl.allow]/[acl.deny]'
-echo '[hooks]' >> acl.config
-echo 'changegroup.acl = false' >> acl.config
-do_push barney
-
-# asterisk
-
-init_config
-
-echo 'asterisk test'
-echo '[acl.allow]' >> $config
-echo "** = fred" >> $config
-echo "fred is always allowed"
-do_push fred
-
-echo '[acl.deny]' >> $config
-echo "foo/Bar/** = *" >> $config
-echo "no one is allowed inside foo/Bar/"
-do_push fred
-
-# Groups
-
-init_config
-
-echo 'OS-level groups'
-echo '[acl.allow]' >> $config
-echo "** = @group1" >> $config
-echo "@group1 is always allowed"
-do_push fred
-
-echo '[acl.deny]' >> $config
-echo "foo/Bar/** = @group1" >> $config
-echo "@group is allowed inside anything but foo/Bar/"
-do_push fred
-
-echo 'Invalid group'
-# Disable the fakegroups trick to get real failures
-grep -v fakegroups $config > config.tmp
-mv config.tmp $config
-echo '[acl.allow]' >> $config
-echo "** = @unlikelytoexist" >> $config
-do_push fred 2>&1 | grep unlikelytoexist
-
-true
--- a/tests/test-acl.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1564 +0,0 @@
-3:911600dab2ae
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 3 changes to 3 files
-updating to branch default
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-Extension disabled for lack of a hook
-Pushing as user fred
-hgrc = """
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-updating the branch cache
-rolling back to revision 0 (undo push)
-0:6675d58eff77
-
-Extension disabled for lack of acl.sources
-Pushing as user fred
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-invalidating branch cache (tip differs)
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: changes have source "push" - skipping
-updating the branch cache
-rolling back to revision 0 (undo push)
-0:6675d58eff77
-
-No [acl.allow]/[acl.deny]
-Pushing as user fred
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-invalidating branch cache (tip differs)
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow not enabled
-acl: acl.deny not enabled
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: allowing changeset f9cafe1212c8
-acl: branch access granted: "911600dab2ae" on branch "default"
-acl: allowing changeset 911600dab2ae
-updating the branch cache
-rolling back to revision 0 (undo push)
-0:6675d58eff77
-
-Empty [acl.allow]
-Pushing as user fred
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-invalidating branch cache (tip differs)
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 0 entries for user fred
-acl: acl.deny not enabled
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: user fred not allowed on foo/file.txt
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset ef1ea85a6374
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset ef1ea85a6374
-no rollback information available
-0:6675d58eff77
-
-fred is allowed inside foo/
-Pushing as user fred
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 1 entries for user fred
-acl: acl.deny not enabled
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: allowing changeset f9cafe1212c8
-acl: branch access granted: "911600dab2ae" on branch "default"
-acl: user fred not allowed on quux/file.py
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset 911600dab2ae
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset 911600dab2ae
-no rollback information available
-0:6675d58eff77
-
-Empty [acl.deny]
-Pushing as user barney
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-[acl.deny]
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 0 entries for user barney
-acl: acl.deny enabled, 0 entries for user barney
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: user barney not allowed on foo/file.txt
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset ef1ea85a6374
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset ef1ea85a6374
-no rollback information available
-0:6675d58eff77
-
-fred is allowed inside foo/, but not foo/bar/ (case matters)
-Pushing as user fred
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-[acl.deny]
-foo/bar/** = fred
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 1 entries for user fred
-acl: acl.deny enabled, 1 entries for user fred
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: allowing changeset f9cafe1212c8
-acl: branch access granted: "911600dab2ae" on branch "default"
-acl: user fred not allowed on quux/file.py
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset 911600dab2ae
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset 911600dab2ae
-no rollback information available
-0:6675d58eff77
-
-fred is allowed inside foo/, but not foo/Bar/
-Pushing as user fred
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-[acl.deny]
-foo/bar/** = fred
-foo/Bar/** = fred
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 1 entries for user fred
-acl: acl.deny enabled, 2 entries for user fred
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: user fred denied on foo/Bar/file.txt
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset f9cafe1212c8
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset f9cafe1212c8
-no rollback information available
-0:6675d58eff77
-
-barney is not mentioned => not allowed anywhere
-Pushing as user barney
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-[acl.deny]
-foo/bar/** = fred
-foo/Bar/** = fred
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 0 entries for user barney
-acl: acl.deny enabled, 0 entries for user barney
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: user barney not allowed on foo/file.txt
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset ef1ea85a6374
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset ef1ea85a6374
-no rollback information available
-0:6675d58eff77
-
-barney is allowed everywhere
-Pushing as user barney
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-[acl.deny]
-foo/bar/** = fred
-foo/Bar/** = fred
-[acl.allow]
-** = barney
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 1 entries for user barney
-acl: acl.deny enabled, 0 entries for user barney
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: allowing changeset f9cafe1212c8
-acl: branch access granted: "911600dab2ae" on branch "default"
-acl: allowing changeset 911600dab2ae
-updating the branch cache
-rolling back to revision 0 (undo push)
-0:6675d58eff77
-
-wilma can change files with a .txt extension
-Pushing as user wilma
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-[acl.deny]
-foo/bar/** = fred
-foo/Bar/** = fred
-[acl.allow]
-** = barney
-**/*.txt = wilma
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-invalidating branch cache (tip differs)
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 1 entries for user wilma
-acl: acl.deny enabled, 0 entries for user wilma
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: allowing changeset f9cafe1212c8
-acl: branch access granted: "911600dab2ae" on branch "default"
-acl: user wilma not allowed on quux/file.py
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset 911600dab2ae
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset 911600dab2ae
-no rollback information available
-0:6675d58eff77
-
-file specified by acl.config does not exist
-Pushing as user barney
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-[acl.deny]
-foo/bar/** = fred
-foo/Bar/** = fred
-[acl.allow]
-** = barney
-**/*.txt = wilma
-[acl]
-config = ../acl.config
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-error: pretxnchangegroup.acl hook raised an exception: [Errno 2] No such file or directory: '../acl.config'
-transaction abort!
-rollback completed
-abort: No such file or directory: ../acl.config
-no rollback information available
-0:6675d58eff77
-
-betty is allowed inside foo/ by a acl.config file
-Pushing as user betty
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-[acl.deny]
-foo/bar/** = fred
-foo/Bar/** = fred
-[acl.allow]
-** = barney
-**/*.txt = wilma
-[acl]
-config = ../acl.config
-"""
-acl.config = """
-[acl.allow]
-foo/** = betty
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 1 entries for user betty
-acl: acl.deny enabled, 0 entries for user betty
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: allowing changeset f9cafe1212c8
-acl: branch access granted: "911600dab2ae" on branch "default"
-acl: user betty not allowed on quux/file.py
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset 911600dab2ae
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset 911600dab2ae
-no rollback information available
-0:6675d58eff77
-
-acl.config can set only [acl.allow]/[acl.deny]
-Pushing as user barney
-hgrc = """
-[hooks]
-pretxnchangegroup.acl = python:hgext.acl.hook
-[acl]
-sources = push
-[acl.allow]
-foo/** = fred
-[acl.deny]
-foo/bar/** = fred
-foo/Bar/** = fred
-[acl.allow]
-** = barney
-**/*.txt = wilma
-[acl]
-config = ../acl.config
-"""
-acl.config = """
-[acl.allow]
-foo/** = betty
-[hooks]
-changegroup.acl = false
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 1 entries for user barney
-acl: acl.deny enabled, 0 entries for user barney
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: allowing changeset f9cafe1212c8
-acl: branch access granted: "911600dab2ae" on branch "default"
-acl: allowing changeset 911600dab2ae
-updating the branch cache
-rolling back to revision 0 (undo push)
-0:6675d58eff77
-
-asterisk test
-fred is always allowed
-Pushing as user fred
-hgrc = """
-[acl]
-sources = push
-[extensions]
-[acl.allow]
-** = fred
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-invalidating branch cache (tip differs)
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 1 entries for user fred
-acl: acl.deny not enabled
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: allowing changeset f9cafe1212c8
-acl: branch access granted: "911600dab2ae" on branch "default"
-acl: allowing changeset 911600dab2ae
-updating the branch cache
-rolling back to revision 0 (undo push)
-0:6675d58eff77
-
-no one is allowed inside foo/Bar/
-Pushing as user fred
-hgrc = """
-[acl]
-sources = push
-[extensions]
-[acl.allow]
-** = fred
-[acl.deny]
-foo/Bar/** = *
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-invalidating branch cache (tip differs)
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: acl.allow enabled, 1 entries for user fred
-acl: acl.deny enabled, 1 entries for user fred
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: user fred denied on foo/Bar/file.txt
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset f9cafe1212c8
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset f9cafe1212c8
-no rollback information available
-0:6675d58eff77
-
-OS-level groups
-@group1 is always allowed
-Pushing as user fred
-hgrc = """
-[acl]
-sources = push
-[extensions]
-[acl.allow]
-** = @group1
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: "group1" not defined in [acl.groups]
-acl: acl.allow enabled, 1 entries for user fred
-acl: acl.deny not enabled
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: allowing changeset f9cafe1212c8
-acl: branch access granted: "911600dab2ae" on branch "default"
-acl: allowing changeset 911600dab2ae
-updating the branch cache
-rolling back to revision 0 (undo push)
-0:6675d58eff77
-
-@group is allowed inside anything but foo/Bar/
-Pushing as user fred
-hgrc = """
-[acl]
-sources = push
-[extensions]
-[acl.allow]
-** = @group1
-[acl.deny]
-foo/Bar/** = @group1
-"""
-pushing to ../b
-searching for changes
-common changesets up to 6675d58eff77
-invalidating branch cache (tip differs)
-3 changesets found
-list of changesets:
-ef1ea85a6374b77d6da9dcda9541f498f2d17df7
-f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
-911600dab2ae7a9baff75958b84fe606851ce955
-adding changesets
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling changes: 7 chunks
-bundling changes: 8 chunks
-bundling changes: 9 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling manifests: 7 chunks
-bundling manifests: 8 chunks
-bundling manifests: 9 chunks
-bundling files: foo/Bar/file.txt 0 chunks
-bundling files: foo/Bar/file.txt 1 chunks
-bundling files: foo/Bar/file.txt 2 chunks
-bundling files: foo/Bar/file.txt 3 chunks
-bundling files: foo/file.txt 4 chunks
-bundling files: foo/file.txt 5 chunks
-bundling files: foo/file.txt 6 chunks
-bundling files: foo/file.txt 7 chunks
-bundling files: quux/file.py 8 chunks
-bundling files: quux/file.py 9 chunks
-bundling files: quux/file.py 10 chunks
-bundling files: quux/file.py 11 chunks
-changesets: 1 chunks
-add changeset ef1ea85a6374
-changesets: 2 chunks
-add changeset f9cafe1212c8
-changesets: 3 chunks
-add changeset 911600dab2ae
-adding manifests
-manifests: 1/3 chunks (33.33%)
-manifests: 2/3 chunks (66.67%)
-manifests: 3/3 chunks (100.00%)
-adding file changes
-adding foo/Bar/file.txt revisions
-files: 1/3 chunks (33.33%)
-adding foo/file.txt revisions
-files: 2/3 chunks (66.67%)
-adding quux/file.py revisions
-files: 3/3 chunks (100.00%)
-added 3 changesets with 3 changes to 3 files
-calling hook pretxnchangegroup.acl: hgext.acl.hook
-acl: acl.allow.branches not enabled
-acl: acl.deny.branches not enabled
-acl: "group1" not defined in [acl.groups]
-acl: acl.allow enabled, 1 entries for user fred
-acl: "group1" not defined in [acl.groups]
-acl: acl.deny enabled, 1 entries for user fred
-acl: branch access granted: "ef1ea85a6374" on branch "default"
-acl: allowing changeset ef1ea85a6374
-acl: branch access granted: "f9cafe1212c8" on branch "default"
-acl: user fred denied on foo/Bar/file.txt
-error: pretxnchangegroup.acl hook failed: acl: access denied for changeset f9cafe1212c8
-transaction abort!
-rollback completed
-abort: acl: access denied for changeset f9cafe1212c8
-no rollback information available
-0:6675d58eff77
-
-Invalid group
-** = @unlikelytoexist
-acl: "unlikelytoexist" not defined in [acl.groups]
-error: pretxnchangegroup.acl hook failed: group 'unlikelytoexist' is undefined
-abort: group 'unlikelytoexist' is undefined
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-acl.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,1738 @@
+  > do_push()
+  > {
+  >     user=$1
+  >     shift
+  >     echo "Pushing as user $user"
+  >     echo 'hgrc = """'
+  >     sed -e 1,2d b/.hg/hgrc | grep -v fakegroups.py
+  >     echo '"""'
+  >     if test -f acl.config; then
+  >         echo 'acl.config = """'
+  >         cat acl.config
+  >         echo '"""'
+  >     fi
+  >     # On AIX /etc/profile sets LOGNAME read-only. So
+  >     #  LOGNAME=$user hg --cws a --debug push ../b
+  >     # fails with "This variable is read only."
+  >     # Use env to work around this.
+  >     env LOGNAME=$user hg --cwd a --debug push ../b
+  >     hg --cwd b rollback
+  >     hg --cwd b --quiet tip
+  >     echo
+  > }
+
+  > init_config()
+  > {
+  >     cat > fakegroups.py <<EOF
+  > from hgext import acl
+  > def fakegetusers(ui, group):
+  >     try:
+  >         return acl._getusersorig(ui, group)
+  >     except:
+  >         return ["fred", "betty"]
+  > acl._getusersorig = acl._getusers
+  > acl._getusers = fakegetusers
+  > EOF
+  >     rm -f acl.config
+  >     cat > $config <<EOF
+  > [hooks]
+  > pretxnchangegroup.acl = python:hgext.acl.hook
+  > [acl]
+  > sources = push
+  > [extensions]
+  > f=`pwd`/fakegroups.py
+  > EOF
+  > }
+
+  $ hg init a
+  $ cd a
+  $ mkdir foo foo/Bar quux
+  $ echo 'in foo' > foo/file.txt
+  $ echo 'in foo/Bar' > foo/Bar/file.txt
+  $ echo 'in quux' > quux/file.py
+  $ hg add -q
+  $ hg ci -m 'add files' -d '1000000 0'
+  $ echo >> foo/file.txt
+  $ hg ci -m 'change foo/file' -d '1000001 0'
+  $ echo >> foo/Bar/file.txt
+  $ hg ci -m 'change foo/Bar/file' -d '1000002 0'
+  $ echo >> quux/file.py
+  $ hg ci -m 'change quux/file' -d '1000003 0'
+  $ hg tip --quiet
+  3:911600dab2ae
+
+  $ cd ..
+  $ hg clone -r 0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 3 changes to 3 files
+  updating to branch default
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+  $ echo '[extensions]' >> $HGRCPATH
+  $ echo 'acl =' >> $HGRCPATH
+
+  $ config=b/.hg/hgrc
+
+Extension disabled for lack of a hook
+
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  updating the branch cache
+  rolling back to revision 0 (undo push)
+  0:6675d58eff77
+  
+
+  $ echo '[hooks]' >> $config
+  $ echo 'pretxnchangegroup.acl = python:hgext.acl.hook' >> $config
+
+Extension disabled for lack of acl.sources
+
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  invalidating branch cache (tip differs)
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: changes have source "push" - skipping
+  updating the branch cache
+  rolling back to revision 0 (undo push)
+  0:6675d58eff77
+  
+
+No [acl.allow]/[acl.deny]
+
+  $ echo '[acl]' >> $config
+  $ echo 'sources = push' >> $config
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  invalidating branch cache (tip differs)
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow not enabled
+  acl: acl.deny not enabled
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: allowing changeset f9cafe1212c8
+  acl: branch access granted: "911600dab2ae" on branch "default"
+  acl: allowing changeset 911600dab2ae
+  updating the branch cache
+  rolling back to revision 0 (undo push)
+  0:6675d58eff77
+  
+
+Empty [acl.allow]
+
+  $ echo '[acl.allow]' >> $config
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  invalidating branch cache (tip differs)
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 0 entries for user fred
+  acl: acl.deny not enabled
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: user fred not allowed on foo/file.txt
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset ef1ea85a6374
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset ef1ea85a6374
+  no rollback information available
+  0:6675d58eff77
+  
+
+fred is allowed inside foo/
+
+  $ echo 'foo/** = fred' >> $config
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 1 entries for user fred
+  acl: acl.deny not enabled
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: allowing changeset f9cafe1212c8
+  acl: branch access granted: "911600dab2ae" on branch "default"
+  acl: user fred not allowed on quux/file.py
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset 911600dab2ae
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset 911600dab2ae
+  no rollback information available
+  0:6675d58eff77
+  
+
+Empty [acl.deny]
+
+  $ echo '[acl.deny]' >> $config
+  $ do_push barney
+  Pushing as user barney
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  [acl.deny]
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 0 entries for user barney
+  acl: acl.deny enabled, 0 entries for user barney
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: user barney not allowed on foo/file.txt
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset ef1ea85a6374
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset ef1ea85a6374
+  no rollback information available
+  0:6675d58eff77
+  
+
+fred is allowed inside foo/, but not foo/bar/ (case matters)
+
+  $ echo 'foo/bar/** = fred' >> $config
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  [acl.deny]
+  foo/bar/** = fred
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 1 entries for user fred
+  acl: acl.deny enabled, 1 entries for user fred
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: allowing changeset f9cafe1212c8
+  acl: branch access granted: "911600dab2ae" on branch "default"
+  acl: user fred not allowed on quux/file.py
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset 911600dab2ae
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset 911600dab2ae
+  no rollback information available
+  0:6675d58eff77
+  
+
+fred is allowed inside foo/, but not foo/Bar/
+
+  $ echo 'foo/Bar/** = fred' >> $config
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  [acl.deny]
+  foo/bar/** = fred
+  foo/Bar/** = fred
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 1 entries for user fred
+  acl: acl.deny enabled, 2 entries for user fred
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: user fred denied on foo/Bar/file.txt
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset f9cafe1212c8
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset f9cafe1212c8
+  no rollback information available
+  0:6675d58eff77
+  
+
+  $ echo 'barney is not mentioned => not allowed anywhere'
+  barney is not mentioned => not allowed anywhere
+  $ do_push barney
+  Pushing as user barney
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  [acl.deny]
+  foo/bar/** = fred
+  foo/Bar/** = fred
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 0 entries for user barney
+  acl: acl.deny enabled, 0 entries for user barney
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: user barney not allowed on foo/file.txt
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset ef1ea85a6374
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset ef1ea85a6374
+  no rollback information available
+  0:6675d58eff77
+  
+
+barney is allowed everywhere
+
+  $ echo '[acl.allow]' >> $config
+  $ echo '** = barney' >> $config
+  $ do_push barney
+  Pushing as user barney
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  [acl.deny]
+  foo/bar/** = fred
+  foo/Bar/** = fred
+  [acl.allow]
+  ** = barney
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 1 entries for user barney
+  acl: acl.deny enabled, 0 entries for user barney
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: allowing changeset f9cafe1212c8
+  acl: branch access granted: "911600dab2ae" on branch "default"
+  acl: allowing changeset 911600dab2ae
+  updating the branch cache
+  rolling back to revision 0 (undo push)
+  0:6675d58eff77
+  
+
+wilma can change files with a .txt extension
+
+  $ echo '**/*.txt = wilma' >> $config
+  $ do_push wilma
+  Pushing as user wilma
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  [acl.deny]
+  foo/bar/** = fred
+  foo/Bar/** = fred
+  [acl.allow]
+  ** = barney
+  **/*.txt = wilma
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  invalidating branch cache (tip differs)
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 1 entries for user wilma
+  acl: acl.deny enabled, 0 entries for user wilma
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: allowing changeset f9cafe1212c8
+  acl: branch access granted: "911600dab2ae" on branch "default"
+  acl: user wilma not allowed on quux/file.py
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset 911600dab2ae
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset 911600dab2ae
+  no rollback information available
+  0:6675d58eff77
+  
+
+file specified by acl.config does not exist
+
+  $ echo '[acl]' >> $config
+  $ echo 'config = ../acl.config' >> $config
+  $ do_push barney
+  Pushing as user barney
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  [acl.deny]
+  foo/bar/** = fred
+  foo/Bar/** = fred
+  [acl.allow]
+  ** = barney
+  **/*.txt = wilma
+  [acl]
+  config = ../acl.config
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  error: pretxnchangegroup.acl hook raised an exception: [Errno 2] No such file or directory: '../acl.config'
+  transaction abort!
+  rollback completed
+  abort: No such file or directory: ../acl.config
+  no rollback information available
+  0:6675d58eff77
+  
+
+betty is allowed inside foo/ by a acl.config file
+
+  $ echo '[acl.allow]' >> acl.config
+  $ echo 'foo/** = betty' >> acl.config
+  $ do_push betty
+  Pushing as user betty
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  [acl.deny]
+  foo/bar/** = fred
+  foo/Bar/** = fred
+  [acl.allow]
+  ** = barney
+  **/*.txt = wilma
+  [acl]
+  config = ../acl.config
+  """
+  acl.config = """
+  [acl.allow]
+  foo/** = betty
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 1 entries for user betty
+  acl: acl.deny enabled, 0 entries for user betty
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: allowing changeset f9cafe1212c8
+  acl: branch access granted: "911600dab2ae" on branch "default"
+  acl: user betty not allowed on quux/file.py
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset 911600dab2ae
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset 911600dab2ae
+  no rollback information available
+  0:6675d58eff77
+  
+
+acl.config can set only [acl.allow]/[acl.deny]
+
+  $ echo '[hooks]' >> acl.config
+  $ echo 'changegroup.acl = false' >> acl.config
+  $ do_push barney
+  Pushing as user barney
+  hgrc = """
+  [hooks]
+  pretxnchangegroup.acl = python:hgext.acl.hook
+  [acl]
+  sources = push
+  [acl.allow]
+  foo/** = fred
+  [acl.deny]
+  foo/bar/** = fred
+  foo/Bar/** = fred
+  [acl.allow]
+  ** = barney
+  **/*.txt = wilma
+  [acl]
+  config = ../acl.config
+  """
+  acl.config = """
+  [acl.allow]
+  foo/** = betty
+  [hooks]
+  changegroup.acl = false
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 1 entries for user barney
+  acl: acl.deny enabled, 0 entries for user barney
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: allowing changeset f9cafe1212c8
+  acl: branch access granted: "911600dab2ae" on branch "default"
+  acl: allowing changeset 911600dab2ae
+  updating the branch cache
+  rolling back to revision 0 (undo push)
+  0:6675d58eff77
+  
+
+asterisk
+
+  $ init_config
+
+asterisk test
+
+  $ echo '[acl.allow]' >> $config
+  $ echo "** = fred" >> $config
+
+fred is always allowed
+
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [acl]
+  sources = push
+  [extensions]
+  [acl.allow]
+  ** = fred
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  invalidating branch cache (tip differs)
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 1 entries for user fred
+  acl: acl.deny not enabled
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: allowing changeset f9cafe1212c8
+  acl: branch access granted: "911600dab2ae" on branch "default"
+  acl: allowing changeset 911600dab2ae
+  updating the branch cache
+  rolling back to revision 0 (undo push)
+  0:6675d58eff77
+  
+
+  $ echo '[acl.deny]' >> $config
+  $ echo "foo/Bar/** = *" >> $config
+
+no one is allowed inside foo/Bar/
+
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [acl]
+  sources = push
+  [extensions]
+  [acl.allow]
+  ** = fred
+  [acl.deny]
+  foo/Bar/** = *
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  invalidating branch cache (tip differs)
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: acl.allow enabled, 1 entries for user fred
+  acl: acl.deny enabled, 1 entries for user fred
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: user fred denied on foo/Bar/file.txt
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset f9cafe1212c8
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset f9cafe1212c8
+  no rollback information available
+  0:6675d58eff77
+  
+
+Groups
+
+  $ init_config
+
+OS-level groups
+
+  $ echo '[acl.allow]' >> $config
+  $ echo "** = @group1" >> $config
+
+@group1 is always allowed
+
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [acl]
+  sources = push
+  [extensions]
+  [acl.allow]
+  ** = @group1
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: "group1" not defined in [acl.groups]
+  acl: acl.allow enabled, 1 entries for user fred
+  acl: acl.deny not enabled
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: allowing changeset f9cafe1212c8
+  acl: branch access granted: "911600dab2ae" on branch "default"
+  acl: allowing changeset 911600dab2ae
+  updating the branch cache
+  rolling back to revision 0 (undo push)
+  0:6675d58eff77
+  
+
+  $ echo '[acl.deny]' >> $config
+  $ echo "foo/Bar/** = @group1" >> $config
+
+@group is allowed inside anything but foo/Bar/
+
+  $ do_push fred
+  Pushing as user fred
+  hgrc = """
+  [acl]
+  sources = push
+  [extensions]
+  [acl.allow]
+  ** = @group1
+  [acl.deny]
+  foo/Bar/** = @group1
+  """
+  pushing to ../b
+  searching for changes
+  common changesets up to 6675d58eff77
+  invalidating branch cache (tip differs)
+  3 changesets found
+  list of changesets:
+  ef1ea85a6374b77d6da9dcda9541f498f2d17df7
+  f9cafe1212c8c6fa1120d14a556e18cc44ff8bdd
+  911600dab2ae7a9baff75958b84fe606851ce955
+  adding changesets
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling changes: 7 chunks
+  bundling changes: 8 chunks
+  bundling changes: 9 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling manifests: 7 chunks
+  bundling manifests: 8 chunks
+  bundling manifests: 9 chunks
+  bundling files: foo/Bar/file.txt 0 chunks
+  bundling files: foo/Bar/file.txt 1 chunks
+  bundling files: foo/Bar/file.txt 2 chunks
+  bundling files: foo/Bar/file.txt 3 chunks
+  bundling files: foo/file.txt 4 chunks
+  bundling files: foo/file.txt 5 chunks
+  bundling files: foo/file.txt 6 chunks
+  bundling files: foo/file.txt 7 chunks
+  bundling files: quux/file.py 8 chunks
+  bundling files: quux/file.py 9 chunks
+  bundling files: quux/file.py 10 chunks
+  bundling files: quux/file.py 11 chunks
+  changesets: 1 chunks
+  add changeset ef1ea85a6374
+  changesets: 2 chunks
+  add changeset f9cafe1212c8
+  changesets: 3 chunks
+  add changeset 911600dab2ae
+  adding manifests
+  manifests: 1/3 chunks (33.33%)
+  manifests: 2/3 chunks (66.67%)
+  manifests: 3/3 chunks (100.00%)
+  adding file changes
+  adding foo/Bar/file.txt revisions
+  files: 1/3 chunks (33.33%)
+  adding foo/file.txt revisions
+  files: 2/3 chunks (66.67%)
+  adding quux/file.py revisions
+  files: 3/3 chunks (100.00%)
+  added 3 changesets with 3 changes to 3 files
+  calling hook pretxnchangegroup.acl: hgext.acl.hook
+  acl: acl.allow.branches not enabled
+  acl: acl.deny.branches not enabled
+  acl: "group1" not defined in [acl.groups]
+  acl: acl.allow enabled, 1 entries for user fred
+  acl: "group1" not defined in [acl.groups]
+  acl: acl.deny enabled, 1 entries for user fred
+  acl: branch access granted: "ef1ea85a6374" on branch "default"
+  acl: allowing changeset ef1ea85a6374
+  acl: branch access granted: "f9cafe1212c8" on branch "default"
+  acl: user fred denied on foo/Bar/file.txt
+  error: pretxnchangegroup.acl hook failed: acl: access denied for changeset f9cafe1212c8
+  transaction abort!
+  rollback completed
+  abort: acl: access denied for changeset f9cafe1212c8
+  no rollback information available
+  0:6675d58eff77
+  
+
+Invalid group
+
+Disable the fakegroups trick to get real failures
+
+  $ grep -v fakegroups $config > config.tmp
+  $ mv config.tmp $config
+  $ echo '[acl.allow]' >> $config
+  $ echo "** = @unlikelytoexist" >> $config
+  $ do_push fred 2>&1 | grep unlikelytoexist
+  ** = @unlikelytoexist
+  acl: "unlikelytoexist" not defined in [acl.groups]
+  error: pretxnchangegroup.acl hook failed: group 'unlikelytoexist' is undefined
+  abort: group 'unlikelytoexist' is undefined
+
+  $ true
--- a/tests/test-add	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,55 +0,0 @@
-#!/bin/sh
-
-hg init a
-cd a
-echo a > a
-hg add -n
-hg st
-hg add
-hg st
-hg forget a
-hg add
-hg st
-
-echo b > b
-hg add -n b
-hg st
-hg add b || echo "failed to add b"
-hg st
-echo % should fail
-hg add b
-hg st
-
-hg ci -m 0 --traceback
-echo % should fail
-hg add a
-
-echo aa > a
-hg ci -m 1
-hg up 0
-echo aaa > a
-hg ci -m 2
-
-hg merge
-hg st
-echo % should fail
-hg add a
-hg st
-hg resolve -m a
-hg ci -m merge
-
-echo % issue683
-hg forget a
-hg add a
-hg st
-hg rm a
-hg st
-echo a > a
-hg add a
-hg st
-
-hg add c && echo "unexpected addition of missing file"
-echo c > c
-hg add d c && echo "unexpected addition of missing file"
-hg st
-
--- a/tests/test-add.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,40 +0,0 @@
-adding a
-? a
-adding a
-A a
-adding a
-A a
-A a
-? b
-A a
-A b
-% should fail
-b already tracked!
-A a
-A b
-% should fail
-a already tracked!
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-merging a
-warning: conflicts during merge.
-merging a failed!
-0 files updated, 0 files merged, 0 files removed, 1 files unresolved
-use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon
-M a
-? a.orig
-% should fail
-a already tracked!
-M a
-? a.orig
-% issue683
-? a.orig
-R a
-? a.orig
-M a
-? a.orig
-c: No such file or directory
-d: No such file or directory
-M a
-A c
-? a.orig
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-add.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,96 @@
+  $ hg init a
+  $ cd a
+  $ echo a > a
+  $ hg add -n
+  adding a
+  $ hg st
+  ? a
+  $ hg add
+  adding a
+  $ hg st
+  A a
+  $ hg forget a
+  $ hg add
+  adding a
+  $ hg st
+  A a
+
+  $ echo b > b
+  $ hg add -n b
+  $ hg st
+  A a
+  ? b
+  $ hg add b || echo "failed to add b"
+  $ hg st
+  A a
+  A b
+
+should fail
+
+  $ hg add b
+  b already tracked!
+  $ hg st
+  A a
+  A b
+
+  $ hg ci -m 0 --traceback
+
+should fail
+
+  $ hg add a
+  a already tracked!
+
+  $ echo aa > a
+  $ hg ci -m 1
+  $ hg up 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo aaa > a
+  $ hg ci -m 2
+  created new head
+
+  $ hg merge
+  merging a
+  warning: conflicts during merge.
+  merging a failed!
+  0 files updated, 0 files merged, 0 files removed, 1 files unresolved
+  use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon
+  $ hg st
+  M a
+  ? a.orig
+
+should fail
+
+  $ hg add a
+  a already tracked!
+  $ hg st
+  M a
+  ? a.orig
+  $ hg resolve -m a
+  $ hg ci -m merge
+
+issue683
+
+  $ hg forget a
+  $ hg add a
+  $ hg st
+  ? a.orig
+  $ hg rm a
+  $ hg st
+  R a
+  ? a.orig
+  $ echo a > a
+  $ hg add a
+  $ hg st
+  M a
+  ? a.orig
+
+  $ hg add c && echo "unexpected addition of missing file"
+  c: No such file or directory
+  $ echo c > c
+  $ hg add d c && echo "unexpected addition of missing file"
+  d: No such file or directory
+  $ hg st
+  M a
+  A c
+  ? a.orig
+
--- a/tests/test-addremove	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,27 +0,0 @@
-#!/bin/sh
-
-hg init rep
-cd rep
-mkdir dir
-touch foo dir/bar
-hg -v addremove
-hg -v commit -m "add 1" -d "1000000 0"
-cd dir/
-touch ../foo_2 bar_2
-hg -v addremove
-hg -v commit -m "add 2" -d "1000000 0"
-
-cd ..
-hg init sim
-cd sim
-echo a > a
-echo a >> a
-echo a >> a
-echo c > c
-hg commit -Ama
-mv a b
-rm c
-echo d > d
-hg addremove -n -s 50 # issue 1696
-hg addremove -s 50
-hg commit -mb
--- a/tests/test-addremove-similar	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,67 +0,0 @@
-#!/bin/sh
-
-hg init rep; cd rep
-
-touch empty-file
-python -c 'for x in range(10000): print x' > large-file
-
-hg addremove
-
-hg commit -m A
-
-rm large-file empty-file
-python -c 'for x in range(10,10000): print x' > another-file
-
-hg addremove -s50
-
-hg commit -m B
-
-echo % comparing two empty files caused ZeroDivisionError in the past
-hg update -C 0
-rm empty-file
-touch another-empty-file
-hg addremove -s50
-
-cd ..
-
-hg init rep2; cd rep2
-
-python -c 'for x in range(10000): print x' > large-file
-python -c 'for x in range(50): print x' > tiny-file
-
-hg addremove
-
-hg commit -m A
-
-python -c 'for x in range(70): print x' > small-file
-rm tiny-file
-rm large-file
-
-hg addremove -s50
-
-hg commit -m B
-
-echo % should all fail
-hg addremove -s foo
-hg addremove -s -1
-hg addremove -s 1e6
-
-cd ..
-
-echo '% issue 1527'
-hg init rep3; cd rep3
-mkdir d
-echo a > d/a
-hg add d/a
-hg commit -m 1
-
-mv d/a d/b
-hg addremove -s80
-hg debugstate
-mv d/b c
-echo "% no copies found here (since the target isn't in d"
-hg addremove -s80 d
-echo "% copies here"
-hg addremove -s80
-
-true
--- a/tests/test-addremove-similar.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,32 +0,0 @@
-adding empty-file
-adding large-file
-adding another-file
-removing empty-file
-removing large-file
-recording removal of large-file as rename to another-file (99% similar)
-% comparing two empty files caused ZeroDivisionError in the past
-2 files updated, 0 files merged, 1 files removed, 0 files unresolved
-adding another-empty-file
-removing empty-file
-adding large-file
-adding tiny-file
-removing large-file
-adding small-file
-removing tiny-file
-recording removal of tiny-file as rename to small-file (82% similar)
-% should all fail
-abort: similarity must be a number
-abort: similarity must be between 0 and 100
-abort: similarity must be between 0 and 100
-% issue 1527
-removing d/a
-adding d/b
-recording removal of d/a as rename to d/b (100% similar)
-r   0          0 1970-01-01 00:00:00 d/a
-a   0         -1 unset               d/b
-copy: d/a -> d/b
-% no copies found here (since the target isn't in d
-removing d/b
-% copies here
-adding c
-recording removal of d/a as rename to c (100% similar)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-addremove-similar.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,99 @@
+  $ hg init rep; cd rep
+
+  $ touch empty-file
+  $ python -c 'for x in range(10000): print x' > large-file
+
+  $ hg addremove
+  adding empty-file
+  adding large-file
+
+  $ hg commit -m A
+
+  $ rm large-file empty-file
+  $ python -c 'for x in range(10,10000): print x' > another-file
+
+  $ hg addremove -s50
+  adding another-file
+  removing empty-file
+  removing large-file
+  recording removal of large-file as rename to another-file (99% similar)
+
+  $ hg commit -m B
+
+comparing two empty files caused ZeroDivisionError in the past
+
+  $ hg update -C 0
+  2 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ rm empty-file
+  $ touch another-empty-file
+  $ hg addremove -s50
+  adding another-empty-file
+  removing empty-file
+
+  $ cd ..
+
+  $ hg init rep2; cd rep2
+
+  $ python -c 'for x in range(10000): print x' > large-file
+  $ python -c 'for x in range(50): print x' > tiny-file
+
+  $ hg addremove
+  adding large-file
+  adding tiny-file
+
+  $ hg commit -m A
+
+  $ python -c 'for x in range(70): print x' > small-file
+  $ rm tiny-file
+  $ rm large-file
+
+  $ hg addremove -s50
+  removing large-file
+  adding small-file
+  removing tiny-file
+  recording removal of tiny-file as rename to small-file (82% similar)
+
+  $ hg commit -m B
+
+should all fail
+
+  $ hg addremove -s foo
+  abort: similarity must be a number
+  $ hg addremove -s -1
+  abort: similarity must be between 0 and 100
+  $ hg addremove -s 1e6
+  abort: similarity must be between 0 and 100
+
+  $ cd ..
+
+issue 1527
+
+  $ hg init rep3; cd rep3
+  $ mkdir d
+  $ echo a > d/a
+  $ hg add d/a
+  $ hg commit -m 1
+
+  $ mv d/a d/b
+  $ hg addremove -s80
+  removing d/a
+  adding d/b
+  recording removal of d/a as rename to d/b (100% similar)
+  $ hg debugstate
+  r   0          0 1970-01-01 00:00:00 d/a
+  a   0         -1 unset               d/b
+  copy: d/a -> d/b
+  $ mv d/b c
+
+no copies found here (since the target isn't in d
+
+  $ hg addremove -s80 d
+  removing d/b
+
+copies here
+
+  $ hg addremove -s80
+  adding c
+  recording removal of d/a as rename to c (100% similar)
+
+  $ true
--- a/tests/test-addremove.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,22 +0,0 @@
-adding dir/bar
-adding foo
-dir/bar
-foo
-committed changeset 0:d44511117907
-adding dir/bar_2
-adding foo_2
-dir/bar_2
-foo_2
-committed changeset 1:a85812e0561a
-adding a
-adding c
-removing a
-adding b
-removing c
-adding d
-recording removal of a as rename to b (100% similar)
-removing a
-adding b
-removing c
-adding d
-recording removal of a as rename to b (100% similar)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-addremove.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,47 @@
+  $ hg init rep
+  $ cd rep
+  $ mkdir dir
+  $ touch foo dir/bar
+  $ hg -v addremove
+  adding dir/bar
+  adding foo
+  $ hg -v commit -m "add 1" -d "1000000 0"
+  dir/bar
+  foo
+  committed changeset 0:d44511117907
+  $ cd dir/
+  $ touch ../foo_2 bar_2
+  $ hg -v addremove
+  adding dir/bar_2
+  adding foo_2
+  $ hg -v commit -m "add 2" -d "1000000 0"
+  dir/bar_2
+  foo_2
+  committed changeset 1:a85812e0561a
+
+  $ cd ..
+  $ hg init sim
+  $ cd sim
+  $ echo a > a
+  $ echo a >> a
+  $ echo a >> a
+  $ echo c > c
+  $ hg commit -Ama
+  adding a
+  adding c
+  $ mv a b
+  $ rm c
+  $ echo d > d
+  $ hg addremove -n -s 50 # issue 1696
+  removing a
+  adding b
+  removing c
+  adding d
+  recording removal of a as rename to b (100% similar)
+  $ hg addremove -s 50
+  removing a
+  adding b
+  removing c
+  adding d
+  recording removal of a as rename to b (100% similar)
+  $ hg commit -mb
--- a/tests/test-alias	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,72 +0,0 @@
-#!/bin/sh
-
-cat >> $HGRCPATH <<EOF
-[alias]
-myinit = init
-cleanstatus = status -c
-unknown = bargle
-ambiguous = s
-recursive = recursive
-nodefinition =
-mylog = log
-lognull = log -r null
-shortlog = log --template '{rev} {node|short} | {date|isodate}\n'
-dln = lognull --debug
-nousage = rollback
-put = export -r 0 -o "\$FOO/%R.diff"
-rt = root
-
-[defaults]
-mylog = -q
-lognull = -q
-log = -v
-EOF
-
-echo '% basic'
-hg myinit alias
-
-echo '% unknown'
-hg unknown
-hg help unknown
-
-echo '% ambiguous'
-hg ambiguous
-hg help ambiguous
-
-echo '% recursive'
-hg recursive
-hg help recursive
-
-echo '% no definition'
-hg nodef
-hg help nodef
-
-cd alias
-
-echo '% no usage'
-hg nousage
-
-echo foo > foo
-hg ci -Amfoo
-
-echo '% with opts'
-hg cleanst
-
-echo '% with opts and whitespace'
-hg shortlog
-
-echo '% interaction with defaults'
-hg mylog
-hg lognull
-
-echo '% properly recursive'
-hg dln
-
-echo '% path expanding'
-FOO=`pwd` hg put
-cat 0.diff
-
-echo '% invalid arguments'
-hg rt foo
-
-exit 0
--- a/tests/test-alias.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,58 +0,0 @@
-% basic
-% unknown
-alias 'unknown' resolves to unknown command 'bargle'
-alias 'unknown' resolves to unknown command 'bargle'
-% ambiguous
-alias 'ambiguous' resolves to ambiguous command 's'
-alias 'ambiguous' resolves to ambiguous command 's'
-% recursive
-alias 'recursive' resolves to unknown command 'recursive'
-alias 'recursive' resolves to unknown command 'recursive'
-% no definition
-no definition for alias 'nodefinition'
-no definition for alias 'nodefinition'
-% no usage
-no rollback information available
-adding foo
-% with opts
-C foo
-% with opts and whitespace
-0 e63c23eaa88a | 1970-01-01 00:00 +0000
-% interaction with defaults
-0:e63c23eaa88a
--1:000000000000
-% properly recursive
-changeset:   -1:0000000000000000000000000000000000000000
-parent:      -1:0000000000000000000000000000000000000000
-parent:      -1:0000000000000000000000000000000000000000
-manifest:    -1:0000000000000000000000000000000000000000
-user:        
-date:        Thu Jan 01 00:00:00 1970 +0000
-extra:       branch=default
-
-% path expanding
-# HG changeset patch
-# User test
-# Date 0 0
-# Node ID e63c23eaa88ae77967edcf4ea194d31167c478b0
-# Parent  0000000000000000000000000000000000000000
-foo
-
-diff -r 000000000000 -r e63c23eaa88a foo
---- /dev/null	Thu Jan 01 00:00:00 1970 +0000
-+++ b/foo	Thu Jan 01 00:00:00 1970 +0000
-@@ -0,0 +1,1 @@
-+foo
-% invalid arguments
-hg rt: invalid arguments
-hg rt 
-
-alias for: hg root
-
-print the root (top) of the current working directory
-
-    Print the root directory of the current repository.
-
-    Returns 0 on success.
-
-use "hg -v help rt" to show global options
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-alias.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,170 @@
+  $ cat >> $HGRCPATH <<EOF
+  > [alias]
+  > myinit = init
+  > cleanstatus = status -c
+  > unknown = bargle
+  > ambiguous = s
+  > recursive = recursive
+  > nodefinition =
+  > no--cwd = status --cwd elsewhere
+  > no-R = status -R elsewhere
+  > no--repo = status --repo elsewhere
+  > no--repository = status --repository elsewhere
+  > mylog = log
+  > lognull = log -r null
+  > shortlog = log --template '{rev} {node|short} | {date|isodate}\n'
+  > dln = lognull --debug
+  > nousage = rollback
+  > put = export -r 0 -o "\$FOO/%R.diff"
+  > echo = !echo
+  > rt = root
+  > 
+  > [defaults]
+  > mylog = -q
+  > lognull = -q
+  > log = -v
+  > EOF
+
+
+basic
+
+  $ hg myinit alias
+
+
+unknown
+
+  $ hg unknown
+  alias 'unknown' resolves to unknown command 'bargle'
+  $ hg help unknown
+  alias 'unknown' resolves to unknown command 'bargle'
+
+
+ambiguous
+
+  $ hg ambiguous
+  alias 'ambiguous' resolves to ambiguous command 's'
+  $ hg help ambiguous
+  alias 'ambiguous' resolves to ambiguous command 's'
+
+
+recursive
+
+  $ hg recursive
+  alias 'recursive' resolves to unknown command 'recursive'
+  $ hg help recursive
+  alias 'recursive' resolves to unknown command 'recursive'
+
+
+no definition
+
+  $ hg nodef
+  no definition for alias 'nodefinition'
+  $ hg help nodef
+  no definition for alias 'nodefinition'
+
+
+invalid options
+
+  $ hg no--cwd
+  error in definition for alias 'no--cwd': --cwd may only be given on the command line
+  $ hg help no--cwd
+  error in definition for alias 'no--cwd': --cwd may only be given on the command line
+  $ hg no-R
+  error in definition for alias 'no-R': -R may only be given on the command line
+  $ hg help no-R
+  error in definition for alias 'no-R': -R may only be given on the command line
+  $ hg no--repo
+  error in definition for alias 'no--repo': --repo may only be given on the command line
+  $ hg help no--repo
+  error in definition for alias 'no--repo': --repo may only be given on the command line
+  $ hg no--repository
+  error in definition for alias 'no--repository': --repository may only be given on the command line
+  $ hg help no--repository
+  error in definition for alias 'no--repository': --repository may only be given on the command line
+
+  $ cd alias
+
+
+no usage
+
+  $ hg nousage
+  no rollback information available
+
+  $ echo foo > foo
+  $ hg ci -Amfoo
+  adding foo
+
+
+with opts
+
+  $ hg cleanst
+  C foo
+
+
+with opts and whitespace
+
+  $ hg shortlog
+  0 e63c23eaa88a | 1970-01-01 00:00 +0000
+
+
+interaction with defaults
+
+  $ hg mylog
+  0:e63c23eaa88a
+  $ hg lognull
+  -1:000000000000
+
+
+properly recursive
+
+  $ hg dln
+  changeset:   -1:0000000000000000000000000000000000000000
+  parent:      -1:0000000000000000000000000000000000000000
+  parent:      -1:0000000000000000000000000000000000000000
+  manifest:    -1:0000000000000000000000000000000000000000
+  user:        
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  extra:       branch=default
+  
+
+
+path expanding
+
+  $ FOO=`pwd` hg put
+  $ cat 0.diff
+  # HG changeset patch
+  # User test
+  # Date 0 0
+  # Node ID e63c23eaa88ae77967edcf4ea194d31167c478b0
+  # Parent  0000000000000000000000000000000000000000
+  foo
+  
+  diff -r 000000000000 -r e63c23eaa88a foo
+  --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+  +++ b/foo	Thu Jan 01 00:00:00 1970 +0000
+  @@ -0,0 +1,1 @@
+  +foo
+
+
+shell aliases
+
+  $ hg echo foo
+  foo
+
+invalid arguments
+
+  $ hg rt foo
+  hg rt: invalid arguments
+  hg rt 
+  
+  alias for: hg root
+  
+  print the root (top) of the current working directory
+  
+      Print the root directory of the current repository.
+  
+      Returns 0 on success.
+  
+  use "hg -v help rt" to show global options
+
+  $ exit 0
--- a/tests/test-annotate	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,115 +0,0 @@
-#!/bin/sh
-
-HGMERGE=true; export HGMERGE
-
-echo % init
-hg init
-
-echo % commit
-echo 'a' > a
-hg ci -A -m test -u nobody -d '1 0'
-
-echo % annotate -c
-hg annotate -c a
-
-echo % annotate -cl
-hg annotate -cl a
-
-echo % annotate -d
-hg annotate -d a
-
-echo % annotate -n
-hg annotate -n a
-
-echo % annotate -nl
-hg annotate -nl a
-
-echo % annotate -u
-hg annotate -u a
-
-echo % annotate -cdnu
-hg annotate -cdnu a
-
-echo % annotate -cdnul
-hg annotate -cdnul a
-
-cat <<EOF >>a
-a
-a
-EOF
-hg ci -ma1 -d '1 0'
-hg cp a b
-hg ci -mb -d '1 0'
-cat <<EOF >> b
-b4
-b5
-b6
-EOF
-hg ci -mb2 -d '2 0'
-
-echo % annotate -n b
-hg annotate -n b
-echo % annotate --no-follow b
-hg annotate --no-follow b
-echo % annotate -nl b
-hg annotate -nl b
-echo % annotate -nf b
-hg annotate -nf b
-echo % annotate -nlf b
-hg annotate -nlf b
-
-hg up -C 2
-cat <<EOF >> b
-b4
-c
-b5
-EOF
-hg ci -mb2.1 -d '2 0'
-hg merge
-hg ci -mmergeb -d '3 0'
-echo % annotate after merge
-hg annotate -nf b
-echo % annotate after merge with -l
-hg annotate -nlf b
-
-hg up -C 1
-hg cp a b
-cat <<EOF > b
-a
-z
-a
-EOF
-hg ci -mc -d '3 0'
-hg merge
-cat <<EOF >> b
-b4
-c
-b5
-EOF
-echo d >> b
-hg ci -mmerge2 -d '4 0'
-echo % annotate after rename merge
-hg annotate -nf b
-echo % annotate after rename merge with -l
-hg annotate -nlf b
-
-echo % linkrev vs rev
-hg annotate -r tip -n a
-echo % linkrev vs rev with -l
-hg annotate -r tip -nl a
-
-# test issue 589
-# annotate was crashing when trying to --follow something
-# like A -> B -> A
-echo % generate ABA rename configuration
-echo foo > foo
-hg add foo
-hg ci -m addfoo
-hg rename foo bar
-hg ci -m renamefoo
-hg rename bar foo
-hg ci -m renamebar
-
-echo % annotate after ABA with follow
-hg annotate --follow foo
-
--- a/tests/test-annotate.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,105 +0,0 @@
-% init
-% commit
-adding a
-% annotate -c
-8435f90966e4: a
-% annotate -cl
-8435f90966e4:1: a
-% annotate -d
-Thu Jan 01 00:00:01 1970 +0000: a
-% annotate -n
-0: a
-% annotate -nl
-0:1: a
-% annotate -u
-nobody: a
-% annotate -cdnu
-nobody 0 8435f90966e4 Thu Jan 01 00:00:01 1970 +0000: a
-% annotate -cdnul
-nobody 0 8435f90966e4 Thu Jan 01 00:00:01 1970 +0000:1: a
-% annotate -n b
-0: a
-1: a
-1: a
-3: b4
-3: b5
-3: b6
-% annotate --no-follow b
-2: a
-2: a
-2: a
-3: b4
-3: b5
-3: b6
-% annotate -nl b
-0:1: a
-1:2: a
-1:3: a
-3:4: b4
-3:5: b5
-3:6: b6
-% annotate -nf b
-0 a: a
-1 a: a
-1 a: a
-3 b: b4
-3 b: b5
-3 b: b6
-% annotate -nlf b
-0 a:1: a
-1 a:2: a
-1 a:3: a
-3 b:4: b4
-3 b:5: b5
-3 b:6: b6
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-merging b
-0 files updated, 1 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-% annotate after merge
-0 a: a
-1 a: a
-1 a: a
-3 b: b4
-4 b: c
-3 b: b5
-% annotate after merge with -l
-0 a:1: a
-1 a:2: a
-1 a:3: a
-3 b:4: b4
-4 b:5: c
-3 b:5: b5
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-created new head
-merging b
-0 files updated, 1 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-% annotate after rename merge
-0 a: a
-6 b: z
-1 a: a
-3 b: b4
-4 b: c
-3 b: b5
-7 b: d
-% annotate after rename merge with -l
-0 a:1: a
-6 b:2: z
-1 a:3: a
-3 b:4: b4
-4 b:5: c
-3 b:5: b5
-7 b:7: d
-% linkrev vs rev
-0: a
-1: a
-1: a
-% linkrev vs rev with -l
-0:1: a
-1:2: a
-1:3: a
-% generate ABA rename configuration
-% annotate after ABA with follow
-foo: foo
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-annotate.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,230 @@
+  $ HGMERGE=true; export HGMERGE
+
+init
+
+  $ hg init
+
+commit
+
+  $ echo 'a' > a
+  $ hg ci -A -m test -u nobody -d '1 0'
+  adding a
+
+annotate -c
+
+  $ hg annotate -c a
+  8435f90966e4: a
+
+annotate -cl
+
+  $ hg annotate -cl a
+  8435f90966e4:1: a
+
+annotate -d
+
+  $ hg annotate -d a
+  Thu Jan 01 00:00:01 1970 +0000: a
+
+annotate -n
+
+  $ hg annotate -n a
+  0: a
+
+annotate -nl
+
+  $ hg annotate -nl a
+  0:1: a
+
+annotate -u
+
+  $ hg annotate -u a
+  nobody: a
+
+annotate -cdnu
+
+  $ hg annotate -cdnu a
+  nobody 0 8435f90966e4 Thu Jan 01 00:00:01 1970 +0000: a
+
+annotate -cdnul
+
+  $ hg annotate -cdnul a
+  nobody 0 8435f90966e4 Thu Jan 01 00:00:01 1970 +0000:1: a
+
+  $ cat <<EOF >>a
+  > a
+  > a
+  > EOF
+  $ hg ci -ma1 -d '1 0'
+  $ hg cp a b
+  $ hg ci -mb -d '1 0'
+  $ cat <<EOF >> b
+  > b4
+  > b5
+  > b6
+  > EOF
+  $ hg ci -mb2 -d '2 0'
+
+annotate -n b
+
+  $ hg annotate -n b
+  0: a
+  1: a
+  1: a
+  3: b4
+  3: b5
+  3: b6
+
+annotate --no-follow b
+
+  $ hg annotate --no-follow b
+  2: a
+  2: a
+  2: a
+  3: b4
+  3: b5
+  3: b6
+
+annotate -nl b
+
+  $ hg annotate -nl b
+  0:1: a
+  1:2: a
+  1:3: a
+  3:4: b4
+  3:5: b5
+  3:6: b6
+
+annotate -nf b
+
+  $ hg annotate -nf b
+  0 a: a
+  1 a: a
+  1 a: a
+  3 b: b4
+  3 b: b5
+  3 b: b6
+
+annotate -nlf b
+
+  $ hg annotate -nlf b
+  0 a:1: a
+  1 a:2: a
+  1 a:3: a
+  3 b:4: b4
+  3 b:5: b5
+  3 b:6: b6
+
+  $ hg up -C 2
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cat <<EOF >> b
+  > b4
+  > c
+  > b5
+  > EOF
+  $ hg ci -mb2.1 -d '2 0'
+  created new head
+  $ hg merge
+  merging b
+  0 files updated, 1 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg ci -mmergeb -d '3 0'
+
+annotate after merge
+
+  $ hg annotate -nf b
+  0 a: a
+  1 a: a
+  1 a: a
+  3 b: b4
+  4 b: c
+  3 b: b5
+
+annotate after merge with -l
+
+  $ hg annotate -nlf b
+  0 a:1: a
+  1 a:2: a
+  1 a:3: a
+  3 b:4: b4
+  4 b:5: c
+  3 b:5: b5
+
+  $ hg up -C 1
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg cp a b
+  $ cat <<EOF > b
+  > a
+  > z
+  > a
+  > EOF
+  $ hg ci -mc -d '3 0'
+  created new head
+  $ hg merge
+  merging b
+  0 files updated, 1 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ cat <<EOF >> b
+  > b4
+  > c
+  > b5
+  > EOF
+  $ echo d >> b
+  $ hg ci -mmerge2 -d '4 0'
+
+annotate after rename merge
+
+  $ hg annotate -nf b
+  0 a: a
+  6 b: z
+  1 a: a
+  3 b: b4
+  4 b: c
+  3 b: b5
+  7 b: d
+
+annotate after rename merge with -l
+
+  $ hg annotate -nlf b
+  0 a:1: a
+  6 b:2: z
+  1 a:3: a
+  3 b:4: b4
+  4 b:5: c
+  3 b:5: b5
+  7 b:7: d
+
+linkrev vs rev
+
+  $ hg annotate -r tip -n a
+  0: a
+  1: a
+  1: a
+
+linkrev vs rev with -l
+
+  $ hg annotate -r tip -nl a
+  0:1: a
+  1:2: a
+  1:3: a
+
+test issue 589
+
+annotate was crashing when trying to --follow something
+
+like A -> B -> A
+
+generate ABA rename configuration
+
+  $ echo foo > foo
+  $ hg add foo
+  $ hg ci -m addfoo
+  $ hg rename foo bar
+  $ hg ci -m renamefoo
+  $ hg rename bar foo
+  $ hg ci -m renamebar
+
+annotate after ABA with follow
+
+  $ hg annotate --follow foo
+  foo: foo
+
--- a/tests/test-archive	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,143 +0,0 @@
-#!/bin/sh
-
-mkdir test
-cd test
-hg init
-echo foo>foo
-hg commit -Am 1 -d '1 0'
-echo bar>bar
-hg commit -Am 2 -d '2 0'
-mkdir baz
-echo bletch>baz/bletch
-hg commit -Am 3 -d '1000000000 0'
-echo "[web]" >> .hg/hgrc
-echo "name = test-archive" >> .hg/hgrc
-cp .hg/hgrc .hg/hgrc-base
-
-# check http return codes
-test_archtype() {
-    echo "allow_archive = $1" >> .hg/hgrc
-    hg serve -p $HGPORT -d --pid-file=hg.pid -E errors.log
-    cat hg.pid >> $DAEMON_PIDS
-    echo % $1 allowed should give 200
-    "$TESTDIR/get-with-headers.py" localhost:$HGPORT "/archive/tip.$2" | head -n 1
-    echo % $3 and $4 disallowed should both give 403
-    "$TESTDIR/get-with-headers.py" localhost:$HGPORT "/archive/tip.$3" | head -n 1
-    "$TESTDIR/get-with-headers.py" localhost:$HGPORT "/archive/tip.$4" | head -n 1
-    "$TESTDIR/killdaemons.py"
-    cat errors.log
-    cp .hg/hgrc-base .hg/hgrc
-}
-
-echo
-test_archtype gz tar.gz tar.bz2 zip
-test_archtype bz2 tar.bz2 zip tar.gz
-test_archtype zip zip tar.gz tar.bz2
-
-echo "allow_archive = gz bz2 zip" >> .hg/hgrc
-hg serve -p $HGPORT -d --pid-file=hg.pid -E errors.log
-cat hg.pid >> $DAEMON_PIDS
-
-echo % invalid arch type should give 404
-"$TESTDIR/get-with-headers.py" localhost:$HGPORT "/archive/tip.invalid" | head -n 1
-echo
-
-TIP=`hg id -v | cut -f1 -d' '`
-QTIP=`hg id -q`
-cat > getarchive.py <<EOF
-import os, sys, urllib2
-try:
-    # Set stdout to binary mode for win32 platforms
-    import msvcrt
-    msvcrt.setmode(sys.stdout.fileno(), os.O_BINARY)
-except ImportError:
-    pass
-    
-node, archive = sys.argv[1:]
-f = urllib2.urlopen('http://127.0.0.1:%s/?cmd=archive;node=%s;type=%s'
-                    % (os.environ['HGPORT'], node, archive))
-sys.stdout.write(f.read())
-EOF
-python getarchive.py "$TIP" gz | gunzip | tar tf - 2>/dev/null | sed "s/$QTIP/TIP/"
-python getarchive.py "$TIP" bz2 | bunzip2 | tar tf - 2>/dev/null | sed "s/$QTIP/TIP/"
-python getarchive.py "$TIP" zip > archive.zip
-unzip -t archive.zip | sed "s/$QTIP/TIP/"
-
-"$TESTDIR/killdaemons.py"
-
-hg archive -t tar test.tar
-tar tf test.tar
-
-hg archive -t tbz2 -X baz test.tar.bz2
-bunzip2 -dc test.tar.bz2 | tar tf - 2>/dev/null
-
-hg archive -t tgz -p %b-%h test-%h.tar.gz
-gzip -dc test-$QTIP.tar.gz | tar tf - 2>/dev/null | sed "s/$QTIP/TIP/"
-
-hg archive autodetected_test.tar
-tar tf autodetected_test.tar
-
-# The '-t' should override autodetection
-hg archive -t tar autodetect_override_test.zip
-tar tf autodetect_override_test.zip
-
-for ext in tar tar.gz tgz tar.bz2 tbz2 zip; do
-    hg archive auto_test.$ext
-    if [ -d auto_test.$ext ]; then
-        echo "extension $ext was not autodetected."
-    fi
-done
-
-cat > md5comp.py <<EOF
-try:
-    from hashlib import md5
-except ImportError:
-    from md5 import md5
-import sys
-f1, f2 = sys.argv[1:3]
-h1 = md5(file(f1, 'rb').read()).hexdigest()
-h2 = md5(file(f2, 'rb').read()).hexdigest()
-print h1 == h2 or "md5 differ: " + repr((h1, h2))
-EOF
-
-# archive name is stored in the archive, so create similar
-# archives and rename them afterwards.
-hg archive -t tgz tip.tar.gz
-mv tip.tar.gz tip1.tar.gz
-sleep 1
-hg archive -t tgz tip.tar.gz
-mv tip.tar.gz tip2.tar.gz
-python md5comp.py tip1.tar.gz tip2.tar.gz
-
-hg archive -t zip -p /illegal test.zip
-hg archive -t zip -p very/../bad test.zip
-
-hg archive --config ui.archivemeta=false -t zip -r 2 test.zip
-unzip -t test.zip
-
-hg archive -t tar - | tar tf - 2>/dev/null | sed "s/$QTIP/TIP/"
-
-hg archive -r 0 -t tar rev-%r.tar
-if [ -f rev-0.tar ]; then
-    echo 'rev-0.tar created'
-fi
-
-echo '% test .hg_archival.txt'
-hg archive ../test-tags
-cat ../test-tags/.hg_archival.txt
-hg tag -r 2 mytag
-hg tag -r 2 anothertag
-hg archive -r 2 ../test-lasttag
-cat ../test-lasttag/.hg_archival.txt
-
-hg archive -t bogus test.bogus
-
-echo % server errors
-cat errors.log
-
-echo '% empty repo'
-hg init ../empty
-cd ../empty
-hg archive ../test-empty
-
-exit 0
--- a/tests/test-archive-symlinks	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,32 +0,0 @@
-#!/bin/sh
-
-"$TESTDIR/hghave" symlink || exit 80
-
-origdir=`pwd`
-
-hg init repo
-cd repo
-ln -s nothing dangling
-# avoid tar warnings about old timestamp
-hg ci -d '2000-01-01 00:00:00 +0000' -qAm 'add symlink'
-
-hg archive -t files ../archive
-hg archive -t tar -p tar ../archive.tar
-hg archive -t zip -p zip ../archive.zip
-
-echo '% files'
-cd "$origdir"
-cd archive
-$TESTDIR/readlink.py dangling
-
-echo '% tar'
-cd "$origdir"
-tar xf archive.tar
-cd tar
-$TESTDIR/readlink.py dangling
-
-echo '% zip'
-cd "$origdir"
-unzip archive.zip > /dev/null
-cd zip
-$TESTDIR/readlink.py dangling
--- a/tests/test-archive-symlinks.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,6 +0,0 @@
-% files
-dangling -> nothing
-% tar
-dangling -> nothing
-% zip
-dangling -> nothing
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-archive-symlinks.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,38 @@
+  $ "$TESTDIR/hghave" symlink || exit 80
+
+  $ origdir=`pwd`
+
+  $ hg init repo
+  $ cd repo
+  $ ln -s nothing dangling
+
+avoid tar warnings about old timestamp
+
+  $ hg ci -d '2000-01-01 00:00:00 +0000' -qAm 'add symlink'
+
+  $ hg archive -t files ../archive
+  $ hg archive -t tar -p tar ../archive.tar
+  $ hg archive -t zip -p zip ../archive.zip
+
+files
+
+  $ cd "$origdir"
+  $ cd archive
+  $ $TESTDIR/readlink.py dangling
+  dangling -> nothing
+
+tar
+
+  $ cd "$origdir"
+  $ tar xf archive.tar
+  $ cd tar
+  $ $TESTDIR/readlink.py dangling
+  dangling -> nothing
+
+zip
+
+  $ cd "$origdir"
+  $ unzip archive.zip > /dev/null
+  $ cd zip
+  $ $TESTDIR/readlink.py dangling
+  dangling -> nothing
--- a/tests/test-archive.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,82 +0,0 @@
-adding foo
-adding bar
-adding baz/bletch
-
-% gz allowed should give 200
-200 Script output follows
-% tar.bz2 and zip disallowed should both give 403
-403 Archive type not allowed: bz2
-403 Archive type not allowed: zip
-% bz2 allowed should give 200
-200 Script output follows
-% zip and tar.gz disallowed should both give 403
-403 Archive type not allowed: zip
-403 Archive type not allowed: gz
-% zip allowed should give 200
-200 Script output follows
-% tar.gz and tar.bz2 disallowed should both give 403
-403 Archive type not allowed: gz
-403 Archive type not allowed: bz2
-% invalid arch type should give 404
-404 Unsupported archive type: None
-
-test-archive-TIP/.hg_archival.txt
-test-archive-TIP/bar
-test-archive-TIP/baz/bletch
-test-archive-TIP/foo
-test-archive-TIP/.hg_archival.txt
-test-archive-TIP/bar
-test-archive-TIP/baz/bletch
-test-archive-TIP/foo
-Archive:  archive.zip
-    testing: test-archive-TIP/.hg_archival.txt   OK
-    testing: test-archive-TIP/bar   OK
-    testing: test-archive-TIP/baz/bletch   OK
-    testing: test-archive-TIP/foo   OK
-No errors detected in compressed data of archive.zip.
-test/.hg_archival.txt
-test/bar
-test/baz/bletch
-test/foo
-test/.hg_archival.txt
-test/bar
-test/foo
-test-TIP/.hg_archival.txt
-test-TIP/bar
-test-TIP/baz/bletch
-test-TIP/foo
-autodetected_test/.hg_archival.txt
-autodetected_test/bar
-autodetected_test/baz/bletch
-autodetected_test/foo
-autodetect_override_test.zip/.hg_archival.txt
-autodetect_override_test.zip/bar
-autodetect_override_test.zip/baz/bletch
-autodetect_override_test.zip/foo
-True
-abort: archive prefix contains illegal components
-Archive:  test.zip
-    testing: test/bar                 OK
-    testing: test/baz/bletch          OK
-    testing: test/foo                 OK
-No errors detected in compressed data of test.zip.
-test-TIP/.hg_archival.txt
-test-TIP/bar
-test-TIP/baz/bletch
-test-TIP/foo
-rev-0.tar created
-% test .hg_archival.txt
-repo: daa7f7c60e0a224faa4ff77ca41b2760562af264
-node: 2c0277f05ed49d1c8328fb9ba92fba7a5ebcb33e
-branch: default
-latesttag: null
-latesttagdistance: 3
-repo: daa7f7c60e0a224faa4ff77ca41b2760562af264
-node: 2c0277f05ed49d1c8328fb9ba92fba7a5ebcb33e
-branch: default
-tag: anothertag
-tag: mytag
-abort: unknown archive type 'bogus'
-% server errors
-% empty repo
-abort: no working directory: please specify a revision
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-archive.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,220 @@
+  $ mkdir test
+  $ cd test
+  $ hg init
+  $ echo foo>foo
+  $ hg commit -Am 1 -d '1 0'
+  adding foo
+  $ echo bar>bar
+  $ hg commit -Am 2 -d '2 0'
+  adding bar
+  $ mkdir baz
+  $ echo bletch>baz/bletch
+  $ hg commit -Am 3 -d '1000000000 0'
+  adding baz/bletch
+  $ echo "[web]" >> .hg/hgrc
+  $ echo "name = test-archive" >> .hg/hgrc
+  $ cp .hg/hgrc .hg/hgrc-base
+  > test_archtype() {
+  >     echo "allow_archive = $1" >> .hg/hgrc
+  >     hg serve -p $HGPORT -d --pid-file=hg.pid -E errors.log
+  >     cat hg.pid >> $DAEMON_PIDS
+  >     echo % $1 allowed should give 200
+  >     "$TESTDIR/get-with-headers.py" localhost:$HGPORT "/archive/tip.$2" | head -n 1
+  >     echo % $3 and $4 disallowed should both give 403
+  >     "$TESTDIR/get-with-headers.py" localhost:$HGPORT "/archive/tip.$3" | head -n 1
+  >     "$TESTDIR/get-with-headers.py" localhost:$HGPORT "/archive/tip.$4" | head -n 1
+  >     "$TESTDIR/killdaemons.py"
+  >     cat errors.log
+  >     cp .hg/hgrc-base .hg/hgrc
+  > }
+
+check http return codes
+
+
+  $ test_archtype gz tar.gz tar.bz2 zip
+  % gz allowed should give 200
+  200 Script output follows
+  % tar.bz2 and zip disallowed should both give 403
+  403 Archive type not allowed: bz2
+  403 Archive type not allowed: zip
+  $ test_archtype bz2 tar.bz2 zip tar.gz
+  % bz2 allowed should give 200
+  200 Script output follows
+  % zip and tar.gz disallowed should both give 403
+  403 Archive type not allowed: zip
+  403 Archive type not allowed: gz
+  $ test_archtype zip zip tar.gz tar.bz2
+  % zip allowed should give 200
+  200 Script output follows
+  % tar.gz and tar.bz2 disallowed should both give 403
+  403 Archive type not allowed: gz
+  403 Archive type not allowed: bz2
+
+  $ echo "allow_archive = gz bz2 zip" >> .hg/hgrc
+  $ hg serve -p $HGPORT -d --pid-file=hg.pid -E errors.log
+  $ cat hg.pid >> $DAEMON_PIDS
+
+invalid arch type should give 404
+
+  $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT "/archive/tip.invalid" | head -n 1
+  404 Unsupported archive type: None
+
+  $ TIP=`hg id -v | cut -f1 -d' '`
+  $ QTIP=`hg id -q`
+  $ cat > getarchive.py <<EOF
+  > import os, sys, urllib2
+  > try:
+  >     # Set stdout to binary mode for win32 platforms
+  >     import msvcrt
+  >     msvcrt.setmode(sys.stdout.fileno(), os.O_BINARY)
+  > except ImportError:
+  >     pass
+  > node, archive = sys.argv[1:]
+  > f = urllib2.urlopen('http://127.0.0.1:%s/?cmd=archive;node=%s;type=%s'
+  >                     % (os.environ['HGPORT'], node, archive))
+  > sys.stdout.write(f.read())
+  > EOF
+  $ python getarchive.py "$TIP" gz | gunzip | tar tf - 2>/dev/null | sed "s/$QTIP/TIP/"
+  test-archive-TIP/.hg_archival.txt
+  test-archive-TIP/bar
+  test-archive-TIP/baz/bletch
+  test-archive-TIP/foo
+  $ python getarchive.py "$TIP" bz2 | bunzip2 | tar tf - 2>/dev/null | sed "s/$QTIP/TIP/"
+  test-archive-TIP/.hg_archival.txt
+  test-archive-TIP/bar
+  test-archive-TIP/baz/bletch
+  test-archive-TIP/foo
+  $ python getarchive.py "$TIP" zip > archive.zip
+  $ unzip -t archive.zip | sed "s/$QTIP/TIP/"
+  Archive:  archive.zip
+      testing: test-archive-TIP/.hg_archival.txt   OK
+      testing: test-archive-TIP/bar   OK
+      testing: test-archive-TIP/baz/bletch   OK
+      testing: test-archive-TIP/foo   OK
+  No errors detected in compressed data of archive.zip.
+
+  $ "$TESTDIR/killdaemons.py"
+
+  $ hg archive -t tar test.tar
+  $ tar tf test.tar
+  test/.hg_archival.txt
+  test/bar
+  test/baz/bletch
+  test/foo
+
+  $ hg archive -t tbz2 -X baz test.tar.bz2
+  $ bunzip2 -dc test.tar.bz2 | tar tf - 2>/dev/null
+  test/.hg_archival.txt
+  test/bar
+  test/foo
+
+  $ hg archive -t tgz -p %b-%h test-%h.tar.gz
+  $ gzip -dc test-$QTIP.tar.gz | tar tf - 2>/dev/null | sed "s/$QTIP/TIP/"
+  test-TIP/.hg_archival.txt
+  test-TIP/bar
+  test-TIP/baz/bletch
+  test-TIP/foo
+
+  $ hg archive autodetected_test.tar
+  $ tar tf autodetected_test.tar
+  autodetected_test/.hg_archival.txt
+  autodetected_test/bar
+  autodetected_test/baz/bletch
+  autodetected_test/foo
+
+The '-t' should override autodetection
+
+  $ hg archive -t tar autodetect_override_test.zip
+  $ tar tf autodetect_override_test.zip
+  autodetect_override_test.zip/.hg_archival.txt
+  autodetect_override_test.zip/bar
+  autodetect_override_test.zip/baz/bletch
+  autodetect_override_test.zip/foo
+
+  $ for ext in tar tar.gz tgz tar.bz2 tbz2 zip; do
+  >     hg archive auto_test.$ext
+  >     if [ -d auto_test.$ext ]; then
+  >         echo "extension $ext was not autodetected."
+  >     fi
+  > done
+
+  $ cat > md5comp.py <<EOF
+  > try:
+  >     from hashlib import md5
+  > except ImportError:
+  >     from md5 import md5
+  > import sys
+  > f1, f2 = sys.argv[1:3]
+  > h1 = md5(file(f1, 'rb').read()).hexdigest()
+  > h2 = md5(file(f2, 'rb').read()).hexdigest()
+  > print h1 == h2 or "md5 differ: " + repr((h1, h2))
+  > EOF
+
+archive name is stored in the archive, so create similar
+
+archives and rename them afterwards.
+
+  $ hg archive -t tgz tip.tar.gz
+  $ mv tip.tar.gz tip1.tar.gz
+  $ sleep 1
+  $ hg archive -t tgz tip.tar.gz
+  $ mv tip.tar.gz tip2.tar.gz
+  $ python md5comp.py tip1.tar.gz tip2.tar.gz
+  True
+
+  $ hg archive -t zip -p /illegal test.zip
+  abort: archive prefix contains illegal components
+  $ hg archive -t zip -p very/../bad test.zip
+
+  $ hg archive --config ui.archivemeta=false -t zip -r 2 test.zip
+  $ unzip -t test.zip
+  Archive:  test.zip
+      testing: test/bar                 OK
+      testing: test/baz/bletch          OK
+      testing: test/foo                 OK
+  No errors detected in compressed data of test.zip.
+
+  $ hg archive -t tar - | tar tf - 2>/dev/null | sed "s/$QTIP/TIP/"
+  test-TIP/.hg_archival.txt
+  test-TIP/bar
+  test-TIP/baz/bletch
+  test-TIP/foo
+
+  $ hg archive -r 0 -t tar rev-%r.tar
+  $ if [ -f rev-0.tar ]; then
+  $ fi
+
+test .hg_archival.txt
+
+  $ hg archive ../test-tags
+  $ cat ../test-tags/.hg_archival.txt
+  repo: daa7f7c60e0a224faa4ff77ca41b2760562af264
+  node: 2c0277f05ed49d1c8328fb9ba92fba7a5ebcb33e
+  branch: default
+  latesttag: null
+  latesttagdistance: 3
+  $ hg tag -r 2 mytag
+  $ hg tag -r 2 anothertag
+  $ hg archive -r 2 ../test-lasttag
+  $ cat ../test-lasttag/.hg_archival.txt
+  repo: daa7f7c60e0a224faa4ff77ca41b2760562af264
+  node: 2c0277f05ed49d1c8328fb9ba92fba7a5ebcb33e
+  branch: default
+  tag: anothertag
+  tag: mytag
+
+  $ hg archive -t bogus test.bogus
+  abort: unknown archive type 'bogus'
+
+server errors
+
+  $ cat errors.log
+
+empty repo
+
+  $ hg init ../empty
+  $ cd ../empty
+  $ hg archive ../test-empty
+  abort: no working directory: please specify a revision
+
+  $ exit 0
--- a/tests/test-audit-path	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-#!/bin/sh
-
-hg init
-
-echo % should fail
-hg add .hg/00changelog.i
-
-mkdir a
-echo a > a/a
-hg ci -Ama
-ln -s a b
-echo b > a/b
-
-echo % should fail
-hg add b/b
-
-echo % should succeed
-hg add b
-
-echo % should still fail - maybe
-hg add b/b
-
-echo % unbundle tampered bundle
-hg init target
-cd target
-hg unbundle $TESTDIR/tampered.hg
-
-echo % attack .hg/test
-hg manifest -r0
-hg update -Cr0
-
-echo % attack foo/.hg/test
-hg manifest -r1
-hg update -Cr1
-
-echo % attack back/test where back symlinks to ..
-hg manifest -r2
-hg update -Cr2
-
-echo % attack ../test
-hg manifest -r3
-hg update -Cr3
-
-echo % attack /tmp/test
-hg manifest -r4
-hg update -Cr4 2>&1 | sed -e "s|/.*/test-audit-path|[HGTMP]/test-audit-path|"
-
-exit 0
--- a/tests/test-audit-path.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,30 +0,0 @@
-% should fail
-abort: path contains illegal component: .hg/00changelog.i
-adding a/a
-% should fail
-abort: path 'b/b' traverses symbolic link 'b'
-% should succeed
-% should still fail - maybe
-abort: path 'b/b' traverses symbolic link 'b'
-% unbundle tampered bundle
-adding changesets
-adding manifests
-adding file changes
-added 5 changesets with 6 changes to 6 files (+4 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-% attack .hg/test
-.hg/test
-abort: path contains illegal component: .hg/test
-% attack foo/.hg/test
-foo/.hg/test
-abort: path 'foo/.hg/test' is inside repo 'foo'
-% attack back/test where back symlinks to ..
-back
-back/test
-abort: path 'back/test' traverses symbolic link 'back'
-% attack ../test
-../test
-abort: path contains illegal component: ../test
-% attack /tmp/test
-/tmp/test
-abort: No such file or directory: [HGTMP]/test-audit-path/target//tmp/test
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-audit-path.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,76 @@
+  $ hg init
+
+should fail
+
+  $ hg add .hg/00changelog.i
+  abort: path contains illegal component: .hg/00changelog.i
+
+  $ mkdir a
+  $ echo a > a/a
+  $ hg ci -Ama
+  adding a/a
+  $ ln -s a b
+  $ echo b > a/b
+
+should fail
+
+  $ hg add b/b
+  abort: path 'b/b' traverses symbolic link 'b'
+
+should succeed
+
+  $ hg add b
+
+should still fail - maybe
+
+  $ hg add b/b
+  abort: path 'b/b' traverses symbolic link 'b'
+
+unbundle tampered bundle
+
+  $ hg init target
+  $ cd target
+  $ hg unbundle $TESTDIR/tampered.hg
+  adding changesets
+  adding manifests
+  adding file changes
+  added 5 changesets with 6 changes to 6 files (+4 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+
+attack .hg/test
+
+  $ hg manifest -r0
+  .hg/test
+  $ hg update -Cr0
+  abort: path contains illegal component: .hg/test
+
+attack foo/.hg/test
+
+  $ hg manifest -r1
+  foo/.hg/test
+  $ hg update -Cr1
+  abort: path 'foo/.hg/test' is inside repo 'foo'
+
+attack back/test where back symlinks to ..
+
+  $ hg manifest -r2
+  back
+  back/test
+  $ hg update -Cr2
+  abort: path 'back/test' traverses symbolic link 'back'
+
+attack ../test
+
+  $ hg manifest -r3
+  ../test
+  $ hg update -Cr3
+  abort: path contains illegal component: ../test
+
+attack /tmp/test
+
+  $ hg manifest -r4
+  /tmp/test
+  $ hg update -Cr4
+  abort: No such file or directory: .*/test-audit-path.t/target//tmp/test
+
+  $ exit 0
--- a/tests/test-backout	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,159 +0,0 @@
-#!/bin/sh
-
-HGMERGE=true; export HGMERGE
-
-hg init basic
-cd basic
-
-echo '# should complain'
-hg backout
-hg backout -r 0 0
-
-echo '# basic operation'
-echo a > a
-hg commit -d '0 0' -A -m a
-echo b >> a
-hg commit -d '1 0' -m b
-
-hg backout -d '2 0' tip
-cat a
-
-echo '# file that was removed is recreated'
-cd ..
-hg init remove
-cd remove
-
-echo content > a
-hg commit -d '0 0' -A -m a
-
-hg rm a
-hg commit -d '1 0' -m b
-
-hg backout -d '2 0' --merge tip
-cat a
-
-echo '# backout of backout is as if nothing happened'
-
-hg backout -d '3 0' --merge tip
-cat a 2>/dev/null || echo cat: a: No such file or directory
-
-echo '# across branch'
-cd ..
-hg init branch
-cd branch
-echo a > a
-hg ci -Am0
-echo b > b
-hg ci -Am1
-hg co -C 0
-# should fail
-hg backout 1
-echo c > c
-hg ci -Am2
-# should fail
-hg backout 1
-
-echo '# backout with merge'
-cd ..
-hg init merge
-cd merge
-
-echo line 1 > a
-echo line 2 >> a
-hg commit -d '0 0' -A -m a
-# remove line 1
-echo line 2 > a
-hg commit -d '1 0' -m b
-
-echo line 3 >> a
-hg commit -d '2 0' -m c
-
-hg backout --merge -d '3 0' 1
-hg commit -d '4 0' -m d
-# check line 1 is back
-cat a
-
-echo '# backout should not back out subsequent changesets'
-hg init onecs
-cd onecs
-echo 1 > a
-hg commit -d '0 0' -A -m a
-echo 2 >> a
-hg commit -d '1 0' -m b
-echo 1 > b
-hg commit -d '2 0' -A -m c
-hg backout -d '3 0' 1
-hg locate b
-hg update -C tip
-hg locate b
-
-cd ..
-hg init m
-cd m
-echo a > a
-hg commit -d '0 0' -A -m a
-echo b > b
-hg commit -d '1 0' -A -m b
-echo c > c
-hg commit -d '2 0' -A -m b
-hg update 1
-echo d > d
-hg commit -d '3 0' -A -m c
-hg merge 2
-hg commit -d '4 0' -A -m d
-
-echo '# backout of merge should fail'
-
-hg backout 4
-
-echo '# backout of merge with bad parent should fail'
-
-hg backout --parent 0 4
-
-echo '# backout of non-merge with parent should fail'
-
-hg backout --parent 0 3
-
-echo '# backout with valid parent should be ok'
-
-hg backout -d '5 0' --parent 2 4
-
-hg rollback
-hg update -C
-
-hg backout -d '6 0' --parent 3 4
-
-cd ..
-
-echo '# named branches'
-
-hg init named_branches
-cd named_branches
-
-echo default > default
-hg ci -d '0 0' -Am default
-hg branch branch1
-echo branch1 > file1
-hg ci -d '1 0' -Am file1
-hg branch branch2
-echo branch2 > file2
-hg ci -d '2 0' -Am file2
-hg backout -d '3 0' -r 1 -m 'backout on branch1'
-# XXX maybe backout shouldn't suggest a merge here as it is a different branch?
-
-echo '% on branch2 with branch1 not merged, so file1 should still exist:'
-hg id
-hg st -A
-
-echo '% on branch2 with branch1 merged, so file1 should be gone:'
-hg merge
-hg ci -d '4 0' -m 'merge backout of branch1'
-hg id
-hg st -A
-
-echo '% on branch1, so no file1 and file2:'
-hg co -C branch1
-hg id
-hg st -A
-
-exit 0
--- a/tests/test-backout.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,95 +0,0 @@
-# should complain
-abort: please specify a revision to backout
-abort: please specify just one revision
-# basic operation
-adding a
-reverting a
-changeset 2:2929462c3dff backs out changeset 1:a820f4f40a57
-a
-# file that was removed is recreated
-adding a
-adding a
-changeset 2:de31bdc76c0d backs out changeset 1:76862dcce372
-content
-# backout of backout is as if nothing happened
-removing a
-changeset 3:7f6d0f120113 backs out changeset 2:de31bdc76c0d
-cat: a: No such file or directory
-# across branch
-adding a
-adding b
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-abort: cannot backout change on a different branch
-adding c
-created new head
-abort: cannot backout change on a different branch
-# backout with merge
-adding a
-reverting a
-created new head
-changeset 3:26b8ccb9ad91 backs out changeset 1:5a50a024c182
-merging with changeset 3:26b8ccb9ad91
-merging a
-0 files updated, 1 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-line 1
-line 2
-line 3
-# backout should not back out subsequent changesets
-adding a
-adding b
-reverting a
-created new head
-changeset 3:3202beb76721 backs out changeset 1:22bca4c721e5
-the backout changeset is a new head - do not forget to merge
-(use "backout --merge" if you want to auto-merge)
-b
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-adding a
-adding b
-adding c
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-adding d
-created new head
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-# backout of merge should fail
-abort: cannot backout a merge changeset without --parent
-# backout of merge with bad parent should fail
-abort: cb9a9f314b8b is not a parent of b2f3bb92043e
-# backout of non-merge with parent should fail
-abort: cannot use --parent on non-merge changeset
-# backout with valid parent should be ok
-removing d
-changeset 5:10e5328c8435 backs out changeset 4:b2f3bb92043e
-rolling back to revision 4 (undo commit)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-removing c
-changeset 5:033590168430 backs out changeset 4:b2f3bb92043e
-# named branches
-adding default
-marked working directory as branch branch1
-adding file1
-marked working directory as branch branch2
-adding file2
-removing file1
-created new head
-changeset 3:d4e8f6db59fb backs out changeset 1:bf1602f437f3
-the backout changeset is a new head - do not forget to merge
-(use "backout --merge" if you want to auto-merge)
-% on branch2 with branch1 not merged, so file1 should still exist:
-45bbcd363bf0 (branch2)
-C default
-C file1
-C file2
-% on branch2 with branch1 merged, so file1 should be gone:
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-22149cdde76d (branch2) tip
-C default
-C file2
-% on branch1, so no file1 and file2:
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-bf1602f437f3 (branch1)
-C default
-C file1
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-backout.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,255 @@
+  $ HGMERGE=true; export HGMERGE
+
+  $ hg init basic
+  $ cd basic
+
+# should complain
+
+  $ hg backout
+  abort: please specify a revision to backout
+  $ hg backout -r 0 0
+  abort: please specify just one revision
+
+# basic operation
+
+  $ echo a > a
+  $ hg commit -d '0 0' -A -m a
+  adding a
+  $ echo b >> a
+  $ hg commit -d '1 0' -m b
+
+  $ hg backout -d '2 0' tip
+  reverting a
+  changeset 2:2929462c3dff backs out changeset 1:a820f4f40a57
+  $ cat a
+  a
+
+# file that was removed is recreated
+
+  $ cd ..
+  $ hg init remove
+  $ cd remove
+
+  $ echo content > a
+  $ hg commit -d '0 0' -A -m a
+  adding a
+
+  $ hg rm a
+  $ hg commit -d '1 0' -m b
+
+  $ hg backout -d '2 0' --merge tip
+  adding a
+  changeset 2:de31bdc76c0d backs out changeset 1:76862dcce372
+  $ cat a
+  content
+
+# backout of backout is as if nothing happened
+
+  $ hg backout -d '3 0' --merge tip
+  removing a
+  changeset 3:7f6d0f120113 backs out changeset 2:de31bdc76c0d
+  $ cat a 2>/dev/null || echo cat: a: No such file or directory
+  cat: a: No such file or directory
+
+# across branch
+
+  $ cd ..
+  $ hg init branch
+  $ cd branch
+  $ echo a > a
+  $ hg ci -Am0
+  adding a
+  $ echo b > b
+  $ hg ci -Am1
+  adding b
+  $ hg co -C 0
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+
+should fail
+
+  $ hg backout 1
+  abort: cannot backout change on a different branch
+  $ echo c > c
+  $ hg ci -Am2
+  adding c
+  created new head
+
+should fail
+
+  $ hg backout 1
+  abort: cannot backout change on a different branch
+
+# backout with merge
+
+  $ cd ..
+  $ hg init merge
+  $ cd merge
+
+  $ echo line 1 > a
+  $ echo line 2 >> a
+  $ hg commit -d '0 0' -A -m a
+  adding a
+
+remove line 1
+
+  $ echo line 2 > a
+  $ hg commit -d '1 0' -m b
+
+  $ echo line 3 >> a
+  $ hg commit -d '2 0' -m c
+
+  $ hg backout --merge -d '3 0' 1
+  reverting a
+  created new head
+  changeset 3:26b8ccb9ad91 backs out changeset 1:5a50a024c182
+  merging with changeset 3:26b8ccb9ad91
+  merging a
+  0 files updated, 1 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg commit -d '4 0' -m d
+
+check line 1 is back
+
+  $ cat a
+  line 1
+  line 2
+  line 3
+
+# backout should not back out subsequent changesets
+
+  $ hg init onecs
+  $ cd onecs
+  $ echo 1 > a
+  $ hg commit -d '0 0' -A -m a
+  adding a
+  $ echo 2 >> a
+  $ hg commit -d '1 0' -m b
+  $ echo 1 > b
+  $ hg commit -d '2 0' -A -m c
+  adding b
+  $ hg backout -d '3 0' 1
+  reverting a
+  created new head
+  changeset 3:3202beb76721 backs out changeset 1:22bca4c721e5
+  the backout changeset is a new head - do not forget to merge
+  (use "backout --merge" if you want to auto-merge)
+  $ hg locate b
+  b
+  $ hg update -C tip
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg locate b
+
+  $ cd ..
+  $ hg init m
+  $ cd m
+  $ echo a > a
+  $ hg commit -d '0 0' -A -m a
+  adding a
+  $ echo b > b
+  $ hg commit -d '1 0' -A -m b
+  adding b
+  $ echo c > c
+  $ hg commit -d '2 0' -A -m b
+  adding c
+  $ hg update 1
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ echo d > d
+  $ hg commit -d '3 0' -A -m c
+  adding d
+  created new head
+  $ hg merge 2
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg commit -d '4 0' -A -m d
+
+# backout of merge should fail
+
+  $ hg backout 4
+  abort: cannot backout a merge changeset without --parent
+
+# backout of merge with bad parent should fail
+
+  $ hg backout --parent 0 4
+  abort: cb9a9f314b8b is not a parent of b2f3bb92043e
+
+# backout of non-merge with parent should fail
+
+  $ hg backout --parent 0 3
+  abort: cannot use --parent on non-merge changeset
+
+# backout with valid parent should be ok
+
+  $ hg backout -d '5 0' --parent 2 4
+  removing d
+  changeset 5:10e5328c8435 backs out changeset 4:b2f3bb92043e
+
+  $ hg rollback
+  rolling back to revision 4 (undo commit)
+  $ hg update -C
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+  $ hg backout -d '6 0' --parent 3 4
+  removing c
+  changeset 5:033590168430 backs out changeset 4:b2f3bb92043e
+
+  $ cd ..
+
+# named branches
+
+  $ hg init named_branches
+  $ cd named_branches
+
+  $ echo default > default
+  $ hg ci -d '0 0' -Am default
+  adding default
+  $ hg branch branch1
+  marked working directory as branch branch1
+  $ echo branch1 > file1
+  $ hg ci -d '1 0' -Am file1
+  adding file1
+  $ hg branch branch2
+  marked working directory as branch branch2
+  $ echo branch2 > file2
+  $ hg ci -d '2 0' -Am file2
+  adding file2
+  $ hg backout -d '3 0' -r 1 -m 'backout on branch1'
+  removing file1
+  created new head
+  changeset 3:d4e8f6db59fb backs out changeset 1:bf1602f437f3
+  the backout changeset is a new head - do not forget to merge
+  (use "backout --merge" if you want to auto-merge)
+
+XXX maybe backout shouldn't suggest a merge here as it is a different branch?
+
+on branch2 with branch1 not merged, so file1 should still exist:
+
+  $ hg id
+  45bbcd363bf0 (branch2)
+  $ hg st -A
+  C default
+  C file1
+  C file2
+
+on branch2 with branch1 merged, so file1 should be gone:
+
+  $ hg merge
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg ci -d '4 0' -m 'merge backout of branch1'
+  $ hg id
+  22149cdde76d (branch2) tip
+  $ hg st -A
+  C default
+  C file2
+
+on branch1, so no file1 and file2:
+
+  $ hg co -C branch1
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg id
+  bf1602f437f3 (branch1)
+  $ hg st -A
+  C default
+  C file1
+
+  $ exit 0
--- a/tests/test-backwards-remove	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,12 +0,0 @@
-#!/bin/sh
-hg init
-echo This is file a1 > a
-hg add a
-hg commit -m "commit #0" -d "1000000 0"
-ls
-echo This is file b1 > b
-hg add b
-hg commit -m "commit #1" -d "1000000 0"
-hg co 0
-# B should disappear
-ls
--- a/tests/test-backwards-remove.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,3 +0,0 @@
-a
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-a
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-backwards-remove.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,16 @@
+  $ hg init
+  $ echo This is file a1 > a
+  $ hg add a
+  $ hg commit -m "commit #0" -d "1000000 0"
+  $ ls
+  a
+  $ echo This is file b1 > b
+  $ hg add b
+  $ hg commit -m "commit #1" -d "1000000 0"
+  $ hg co 0
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+
+B should disappear
+
+  $ ls
+  a
--- a/tests/test-bad-extension	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,13 +0,0 @@
-#!/bin/sh
-
-echo 'raise Exception("bit bucket overflow")' > badext.py
-abspath=`pwd`/badext.py
-
-echo '[extensions]' >> $HGRCPATH
-echo "gpg =" >> $HGRCPATH
-echo "hgext.gpg =" >> $HGRCPATH
-echo "badext = $abspath" >> $HGRCPATH
-echo "badext2 =" >> $HGRCPATH
-
-hg -q help help 2>&1 | python -c \
-  "import sys; sys.stdout.write(sys.stdin.read().replace('$abspath', '.../badext.py'))"
--- a/tests/test-bad-extension.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
-*** failed to import extension badext from .../badext.py: bit bucket overflow
-*** failed to import extension badext2: No module named badext2
-hg help [TOPIC]
-
-show help for a given topic or a help overview
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bad-extension.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,15 @@
+  $ echo 'raise Exception("bit bucket overflow")' > badext.py
+  $ abspath=`pwd`/badext.py
+
+  $ echo '[extensions]' >> $HGRCPATH
+  $ echo "gpg =" >> $HGRCPATH
+  $ echo "hgext.gpg =" >> $HGRCPATH
+  $ echo "badext = $abspath" >> $HGRCPATH
+  $ echo "badext2 =" >> $HGRCPATH
+
+  $ hg -q help help
+  \*\*\* failed to import extension badext from .*/badext.py: bit bucket overflow
+  \*\*\* failed to import extension badext2: No module named badext2
+  hg help [TOPIC]
+  
+  show help for a given topic or a help overview
--- a/tests/test-bad-pull	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,30 +0,0 @@
-#!/bin/sh
-
-hg clone http://localhost:$HGPORT/ copy
-echo $?
-test -d copy || echo copy: No such file or directory
-
-cat > dumb.py <<EOF
-import BaseHTTPServer, SimpleHTTPServer, os, signal
-
-def run(server_class=BaseHTTPServer.HTTPServer,
-        handler_class=SimpleHTTPServer.SimpleHTTPRequestHandler):
-    server_address = ('localhost', int(os.environ['HGPORT']))
-    httpd = server_class(server_address, handler_class)
-    httpd.serve_forever()
-
-signal.signal(signal.SIGTERM, lambda x: sys.exit(0))
-run()
-EOF
-
-python dumb.py 2>/dev/null &
-echo $! >> $DAEMON_PIDS
-
-# give the server some time to start running
-sleep 1
-
-hg clone http://localhost:$HGPORT/foo copy2 2>&1 | \
-    sed -e 's/404.*/404/' -e 's/Date:.*/Date:/'
-echo $?
-
-kill $!
--- a/tests/test-bad-pull.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
-abort: error: Connection refused
-255
-copy: No such file or directory
-abort: HTTP Error 404
-0
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bad-pull.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,34 @@
+  $ hg clone http://localhost:$HGPORT/ copy
+  abort: error: Connection refused
+
+  $ echo $?
+  0
+
+  $ test -d copy || echo copy: No such file or directory
+  copy: No such file or directory
+
+  $ cat > dumb.py <<EOF
+  > import BaseHTTPServer, SimpleHTTPServer, os, signal
+  > def run(server_class=BaseHTTPServer.HTTPServer,
+  >         handler_class=SimpleHTTPServer.SimpleHTTPRequestHandler):
+  >     server_address = ('localhost', int(os.environ['HGPORT']))
+  >     httpd = server_class(server_address, handler_class)
+  >     httpd.serve_forever()
+  > signal.signal(signal.SIGTERM, lambda x: sys.exit(0))
+  > run()
+  > EOF
+
+  $ python dumb.py 2>/dev/null &
+  $ echo $! >> $DAEMON_PIDS
+
+give the server some time to start running
+
+  $ sleep 1
+
+  $ hg clone http://localhost:$HGPORT/foo copy2 2>&1
+  abort: HTTP Error 404: .*
+
+  $ echo $?
+  0
+
+  $ kill $!
--- a/tests/test-basic	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,12 +0,0 @@
-#!/bin/sh
-
-mkdir t
-cd t
-hg init
-echo a > a
-hg add a
-hg commit -m test -d "1000000 0"
-hg history
-hg manifest --debug
-hg cat a
-hg verify
--- a/tests/test-basic.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,13 +0,0 @@
-changeset:   0:0acdaf898367
-tag:         tip
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     test
-
-b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3 644   a
-a
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-1 files, 1 changesets, 1 total revisions
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-basic.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,40 @@
+Create a repository:
+
+  $ mkdir t
+  $ cd t
+  $ hg init
+
+Make a changeset:
+
+  $ echo a > a
+  $ hg add a
+  $ hg commit -m test -d "1000000 0"
+
+This command is ancient:
+
+  $ hg history
+  changeset:   0:0acdaf898367
+  tag:         tip
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     test
+  
+
+Poke around at hashes:
+
+  $ hg manifest --debug
+  b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3 644   a
+
+  $ hg cat a
+  a
+
+Verify should succeed:
+
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  1 files, 1 changesets, 1 total revisions
+
+At the end...
--- a/tests/test-bisect2	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,153 +0,0 @@
-#!/bin/sh
-
-# The tests in test-bisect are done on a linear history.
-# Here the following repository history is used for testing:
-#
-#                     17
-#                      |
-#               18    16 
-#                 \  /
-#                  15
-#                 /  \
-#                /    \
-#              10     13
-#              / \     |
-#             /   \    |  14
-#        7   6     9  12 /
-#         \ / \    |   |/
-#          4   \   |  11
-#           \   \  |  /
-#            3   5 | /
-#             \ /  |/ 
-#              2   8
-#               \ /
-#                1
-#                |
-#                0
-
-set -e
-
-echo % init
-hg init
-
-echo % committing changes
-echo > a
-echo '0' >> a
-hg add a
-hg ci -m "0" -d "0 0"
-echo '1' >> a
-hg ci -m "1" -d "1 0"
-echo '2' >> a
-hg ci -m "2" -d "2 0"
-echo '3' >> a
-hg ci -m "3" -d "3 0"
-echo '4' >> a
-hg ci -m "4" -d "4 0"
-# create branch
-hg up -r 2
-echo '5' >> b
-hg add b
-hg ci -m "5" -d "5 0"
-
-# merge
-hg merge
-hg ci -m "merge 4,5" -d "6 0"
-
-# create branch
-hg up -r 4
-echo '7' > c
-hg add c
-hg ci -m "7" -d "7 0"
-
-# create branch
-hg up -r 1
-echo '8' > d
-hg add d
-hg ci -m "8" -d "8 0"
-echo '9' >> d
-hg ci -m "9" -d "9 0"
-
-# merge
-hg merge -r 6
-hg ci -m "merge 6,9" -d "10 0"
-
-# create branch
-hg up -r 8
-echo '11' > e
-hg add e
-hg ci -m "11" -d "11 0"
-echo '12' >> e
-hg ci -m "12" -d "12 0"
-echo '13' >> e
-hg ci -m "13" -d "13 0"
-
-# create branch
-hg up -r 11
-echo '14' > f
-hg add f
-hg ci -m "14" -d "14 0"
-
-# merge
-hg up -r 13 -C
-hg merge -r 10
-hg ci -m "merge 10,13" -d "15 0"
-echo '16' >> e
-hg ci -m "16" -d "16 0"
-echo '17' >> e
-hg ci -m "17" -d "17 0"
-
-# create branch
-hg up -r 15
-echo '18' >> e
-hg ci -m "18" -d "18 0"
-
-
-echo % log
-hg log
-
-echo % hg up -C
-hg up -C
-
-echo % complex bisect test 1  # first bad rev is 9
-hg bisect -r
-hg bisect -g 0
-hg bisect -b 17   # -> update to rev 6
-hg bisect -g      # -> update to rev 13
-hg bisect -s      # -> update to rev 10
-hg bisect -b      # -> update to rev 8
-hg bisect -g      # -> update to rev 9
-hg bisect -b
-
-echo % complex bisect test 2  # first good rev is 13
-hg bisect -r
-hg bisect -g 18
-hg bisect -b 1    # -> update to rev 6
-hg bisect -s      # -> update to rev 10
-hg bisect -b      # -> update to rev 12
-hg bisect -b      # -> update to rev 13
-hg bisect -g
-
-echo % complex bisect test 3  
-# first bad rev is 15 
-# 10,9,13 are skipped an might be the first bad revisions as well
-hg bisect -r
-hg bisect -g 1
-hg bisect -b 16   # -> update to rev 6
-hg bisect -g      # -> update to rev 13
-hg bisect -s      # -> update to rev 10
-hg bisect -s      # -> update to rev 12
-hg bisect -g      # -> update to rev 9
-hg bisect -s      # -> update to rev 15
-hg bisect -b
-
-echo % complex bisect test 4
-# first good revision is 17
-# 15,16 are skipped an might be the first good revisions as well
-hg bisect -r
-hg bisect -g 17
-hg bisect -b 8    # -> update to rev 10
-hg bisect -b      # -> update to rev 13
-hg bisect -b      # -> update to rev 15
-hg bisect -s      # -> update to rev 16
-hg bisect -s
-
--- a/tests/test-bisect2.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,229 +0,0 @@
-% init
-% committing changes
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-created new head
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-created new head
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-2 files updated, 0 files merged, 1 files removed, 0 files unresolved
-created new head
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-% log
-changeset:   18:d42e18c7bc9b
-tag:         tip
-parent:      15:857b178a7cf3
-user:        test
-date:        Thu Jan 01 00:00:18 1970 +0000
-summary:     18
-
-changeset:   17:228c06deef46
-user:        test
-date:        Thu Jan 01 00:00:17 1970 +0000
-summary:     17
-
-changeset:   16:609d82a7ebae
-user:        test
-date:        Thu Jan 01 00:00:16 1970 +0000
-summary:     16
-
-changeset:   15:857b178a7cf3
-parent:      13:b0a32c86eb31
-parent:      10:429fcd26f52d
-user:        test
-date:        Thu Jan 01 00:00:15 1970 +0000
-summary:     merge 10,13
-
-changeset:   14:faa450606157
-parent:      11:82ca6f06eccd
-user:        test
-date:        Thu Jan 01 00:00:14 1970 +0000
-summary:     14
-
-changeset:   13:b0a32c86eb31
-user:        test
-date:        Thu Jan 01 00:00:13 1970 +0000
-summary:     13
-
-changeset:   12:9f259202bbe7
-user:        test
-date:        Thu Jan 01 00:00:12 1970 +0000
-summary:     12
-
-changeset:   11:82ca6f06eccd
-parent:      8:dab8161ac8fc
-user:        test
-date:        Thu Jan 01 00:00:11 1970 +0000
-summary:     11
-
-changeset:   10:429fcd26f52d
-parent:      9:3c77083deb4a
-parent:      6:a214d5d3811a
-user:        test
-date:        Thu Jan 01 00:00:10 1970 +0000
-summary:     merge 6,9
-
-changeset:   9:3c77083deb4a
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     9
-
-changeset:   8:dab8161ac8fc
-parent:      1:4ca5088da217
-user:        test
-date:        Thu Jan 01 00:00:08 1970 +0000
-summary:     8
-
-changeset:   7:50c76098bbf2
-parent:      4:5c668c22234f
-user:        test
-date:        Thu Jan 01 00:00:07 1970 +0000
-summary:     7
-
-changeset:   6:a214d5d3811a
-parent:      5:385a529b6670
-parent:      4:5c668c22234f
-user:        test
-date:        Thu Jan 01 00:00:06 1970 +0000
-summary:     merge 4,5
-
-changeset:   5:385a529b6670
-parent:      2:051e12f87bf1
-user:        test
-date:        Thu Jan 01 00:00:05 1970 +0000
-summary:     5
-
-changeset:   4:5c668c22234f
-user:        test
-date:        Thu Jan 01 00:00:04 1970 +0000
-summary:     4
-
-changeset:   3:0950834f0a9c
-user:        test
-date:        Thu Jan 01 00:00:03 1970 +0000
-summary:     3
-
-changeset:   2:051e12f87bf1
-user:        test
-date:        Thu Jan 01 00:00:02 1970 +0000
-summary:     2
-
-changeset:   1:4ca5088da217
-user:        test
-date:        Thu Jan 01 00:00:01 1970 +0000
-summary:     1
-
-changeset:   0:33b1f9bc8bc5
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     0
-
-% hg up -C
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-% complex bisect test 1
-Testing changeset 6:a214d5d3811a (15 changesets remaining, ~3 tests)
-0 files updated, 0 files merged, 2 files removed, 0 files unresolved
-Testing changeset 13:b0a32c86eb31 (9 changesets remaining, ~3 tests)
-3 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 10:429fcd26f52d (9 changesets remaining, ~3 tests)
-3 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 8:dab8161ac8fc (3 changesets remaining, ~1 tests)
-2 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 9:3c77083deb4a (2 changesets remaining, ~1 tests)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-The first bad revision is:
-changeset:   9:3c77083deb4a
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     9
-
-% complex bisect test 2
-Testing changeset 6:a214d5d3811a (13 changesets remaining, ~3 tests)
-2 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 10:429fcd26f52d (13 changesets remaining, ~3 tests)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-Testing changeset 12:9f259202bbe7 (5 changesets remaining, ~2 tests)
-3 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 13:b0a32c86eb31 (3 changesets remaining, ~1 tests)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-The first good revision is:
-changeset:   13:b0a32c86eb31
-user:        test
-date:        Thu Jan 01 00:00:13 1970 +0000
-summary:     13
-
-% complex bisect test 3
-Testing changeset 6:a214d5d3811a (13 changesets remaining, ~3 tests)
-2 files updated, 0 files merged, 2 files removed, 0 files unresolved
-Testing changeset 13:b0a32c86eb31 (8 changesets remaining, ~3 tests)
-3 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 10:429fcd26f52d (8 changesets remaining, ~3 tests)
-3 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 12:9f259202bbe7 (8 changesets remaining, ~3 tests)
-3 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 9:3c77083deb4a (5 changesets remaining, ~2 tests)
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 15:857b178a7cf3 (5 changesets remaining, ~2 tests)
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
-Due to skipped revisions, the first bad revision could be any of:
-changeset:   9:3c77083deb4a
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     9
-
-changeset:   10:429fcd26f52d
-parent:      9:3c77083deb4a
-parent:      6:a214d5d3811a
-user:        test
-date:        Thu Jan 01 00:00:10 1970 +0000
-summary:     merge 6,9
-
-changeset:   13:b0a32c86eb31
-user:        test
-date:        Thu Jan 01 00:00:13 1970 +0000
-summary:     13
-
-changeset:   15:857b178a7cf3
-parent:      13:b0a32c86eb31
-parent:      10:429fcd26f52d
-user:        test
-date:        Thu Jan 01 00:00:15 1970 +0000
-summary:     merge 10,13
-
-% complex bisect test 4
-Testing changeset 13:b0a32c86eb31 (8 changesets remaining, ~3 tests)
-2 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 10:429fcd26f52d (5 changesets remaining, ~2 tests)
-3 files updated, 0 files merged, 1 files removed, 0 files unresolved
-Testing changeset 15:857b178a7cf3 (3 changesets remaining, ~1 tests)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-Testing changeset 16:609d82a7ebae (3 changesets remaining, ~1 tests)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-Due to skipped revisions, the first good revision could be any of:
-changeset:   15:857b178a7cf3
-parent:      13:b0a32c86eb31
-parent:      10:429fcd26f52d
-user:        test
-date:        Thu Jan 01 00:00:15 1970 +0000
-summary:     merge 10,13
-
-changeset:   16:609d82a7ebae
-user:        test
-date:        Thu Jan 01 00:00:16 1970 +0000
-summary:     16
-
-changeset:   17:228c06deef46
-user:        test
-date:        Thu Jan 01 00:00:17 1970 +0000
-summary:     17
-
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bisect2.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,391 @@
+# The tests in test-bisect are done on a linear history. Here the
+# following repository history is used for testing:
+#
+#                      17
+#                       |
+#                18    16
+#                  \  /
+#                   15
+#                  /  \
+#                 /    \
+#               10     13
+#               / \     |
+#              /   \    |  14
+#         7   6     9  12 /
+#          \ / \    |   |/
+#           4   \   |  11
+#            \   \  |  /
+#             3   5 | /
+#              \ /  |/
+#               2   8
+#                \ /
+#                 1
+#                 |
+#                 0
+
+
+  $ set -e
+
+init
+
+  $ hg init
+
+committing changes
+
+  $ echo > a
+  $ echo '0' >> a
+  $ hg add a
+  $ hg ci -m "0" -d "0 0"
+  $ echo '1' >> a
+  $ hg ci -m "1" -d "1 0"
+  $ echo '2' >> a
+  $ hg ci -m "2" -d "2 0"
+  $ echo '3' >> a
+  $ hg ci -m "3" -d "3 0"
+  $ echo '4' >> a
+  $ hg ci -m "4" -d "4 0"
+
+create branch
+
+  $ hg up -r 2
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo '5' >> b
+  $ hg add b
+  $ hg ci -m "5" -d "5 0"
+  created new head
+
+merge
+
+  $ hg merge
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg ci -m "merge 4,5" -d "6 0"
+
+create branch
+
+  $ hg up -r 4
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ echo '7' > c
+  $ hg add c
+  $ hg ci -m "7" -d "7 0"
+  created new head
+
+create branch
+
+  $ hg up -r 1
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ echo '8' > d
+  $ hg add d
+  $ hg ci -m "8" -d "8 0"
+  created new head
+  $ echo '9' >> d
+  $ hg ci -m "9" -d "9 0"
+
+merge
+
+  $ hg merge -r 6
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg ci -m "merge 6,9" -d "10 0"
+
+create branch
+
+  $ hg up -r 8
+  2 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ echo '11' > e
+  $ hg add e
+  $ hg ci -m "11" -d "11 0"
+  created new head
+  $ echo '12' >> e
+  $ hg ci -m "12" -d "12 0"
+  $ echo '13' >> e
+  $ hg ci -m "13" -d "13 0"
+
+create branch
+
+  $ hg up -r 11
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo '14' > f
+  $ hg add f
+  $ hg ci -m "14" -d "14 0"
+  created new head
+
+merge
+
+  $ hg up -r 13 -C
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg merge -r 10
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg ci -m "merge 10,13" -d "15 0"
+  $ echo '16' >> e
+  $ hg ci -m "16" -d "16 0"
+  $ echo '17' >> e
+  $ hg ci -m "17" -d "17 0"
+
+create branch
+
+  $ hg up -r 15
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo '18' >> e
+  $ hg ci -m "18" -d "18 0"
+  created new head
+
+log
+
+  $ hg log
+  changeset:   18:d42e18c7bc9b
+  tag:         tip
+  parent:      15:857b178a7cf3
+  user:        test
+  date:        Thu Jan 01 00:00:18 1970 +0000
+  summary:     18
+  
+  changeset:   17:228c06deef46
+  user:        test
+  date:        Thu Jan 01 00:00:17 1970 +0000
+  summary:     17
+  
+  changeset:   16:609d82a7ebae
+  user:        test
+  date:        Thu Jan 01 00:00:16 1970 +0000
+  summary:     16
+  
+  changeset:   15:857b178a7cf3
+  parent:      13:b0a32c86eb31
+  parent:      10:429fcd26f52d
+  user:        test
+  date:        Thu Jan 01 00:00:15 1970 +0000
+  summary:     merge 10,13
+  
+  changeset:   14:faa450606157
+  parent:      11:82ca6f06eccd
+  user:        test
+  date:        Thu Jan 01 00:00:14 1970 +0000
+  summary:     14
+  
+  changeset:   13:b0a32c86eb31
+  user:        test
+  date:        Thu Jan 01 00:00:13 1970 +0000
+  summary:     13
+  
+  changeset:   12:9f259202bbe7
+  user:        test
+  date:        Thu Jan 01 00:00:12 1970 +0000
+  summary:     12
+  
+  changeset:   11:82ca6f06eccd
+  parent:      8:dab8161ac8fc
+  user:        test
+  date:        Thu Jan 01 00:00:11 1970 +0000
+  summary:     11
+  
+  changeset:   10:429fcd26f52d
+  parent:      9:3c77083deb4a
+  parent:      6:a214d5d3811a
+  user:        test
+  date:        Thu Jan 01 00:00:10 1970 +0000
+  summary:     merge 6,9
+  
+  changeset:   9:3c77083deb4a
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     9
+  
+  changeset:   8:dab8161ac8fc
+  parent:      1:4ca5088da217
+  user:        test
+  date:        Thu Jan 01 00:00:08 1970 +0000
+  summary:     8
+  
+  changeset:   7:50c76098bbf2
+  parent:      4:5c668c22234f
+  user:        test
+  date:        Thu Jan 01 00:00:07 1970 +0000
+  summary:     7
+  
+  changeset:   6:a214d5d3811a
+  parent:      5:385a529b6670
+  parent:      4:5c668c22234f
+  user:        test
+  date:        Thu Jan 01 00:00:06 1970 +0000
+  summary:     merge 4,5
+  
+  changeset:   5:385a529b6670
+  parent:      2:051e12f87bf1
+  user:        test
+  date:        Thu Jan 01 00:00:05 1970 +0000
+  summary:     5
+  
+  changeset:   4:5c668c22234f
+  user:        test
+  date:        Thu Jan 01 00:00:04 1970 +0000
+  summary:     4
+  
+  changeset:   3:0950834f0a9c
+  user:        test
+  date:        Thu Jan 01 00:00:03 1970 +0000
+  summary:     3
+  
+  changeset:   2:051e12f87bf1
+  user:        test
+  date:        Thu Jan 01 00:00:02 1970 +0000
+  summary:     2
+  
+  changeset:   1:4ca5088da217
+  user:        test
+  date:        Thu Jan 01 00:00:01 1970 +0000
+  summary:     1
+  
+  changeset:   0:33b1f9bc8bc5
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     0
+  
+
+hg up -C
+
+  $ hg up -C
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+complex bisect test 1  # first bad rev is 9
+
+  $ hg bisect -r
+  $ hg bisect -g 0
+  $ hg bisect -b 17   # -> update to rev 6
+  Testing changeset 6:a214d5d3811a (15 changesets remaining, ~3 tests)
+  0 files updated, 0 files merged, 2 files removed, 0 files unresolved
+  $ hg bisect -g      # -> update to rev 13
+  Testing changeset 13:b0a32c86eb31 (9 changesets remaining, ~3 tests)
+  3 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -s      # -> update to rev 10
+  Testing changeset 10:429fcd26f52d (9 changesets remaining, ~3 tests)
+  3 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -b      # -> update to rev 8
+  Testing changeset 8:dab8161ac8fc (3 changesets remaining, ~1 tests)
+  2 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -g      # -> update to rev 9
+  Testing changeset 9:3c77083deb4a (2 changesets remaining, ~1 tests)
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg bisect -b
+  The first bad revision is:
+  changeset:   9:3c77083deb4a
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     9
+  
+
+complex bisect test 2  # first good rev is 13
+
+  $ hg bisect -r
+  $ hg bisect -g 18
+  $ hg bisect -b 1    # -> update to rev 6
+  Testing changeset 6:a214d5d3811a (13 changesets remaining, ~3 tests)
+  2 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -s      # -> update to rev 10
+  Testing changeset 10:429fcd26f52d (13 changesets remaining, ~3 tests)
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg bisect -b      # -> update to rev 12
+  Testing changeset 12:9f259202bbe7 (5 changesets remaining, ~2 tests)
+  3 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -b      # -> update to rev 13
+  Testing changeset 13:b0a32c86eb31 (3 changesets remaining, ~1 tests)
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg bisect -g
+  The first good revision is:
+  changeset:   13:b0a32c86eb31
+  user:        test
+  date:        Thu Jan 01 00:00:13 1970 +0000
+  summary:     13
+  
+
+complex bisect test 3
+
+first bad rev is 15
+10,9,13 are skipped an might be the first bad revisions as well
+
+  $ hg bisect -r
+  $ hg bisect -g 1
+  $ hg bisect -b 16   # -> update to rev 6
+  Testing changeset 6:a214d5d3811a (13 changesets remaining, ~3 tests)
+  2 files updated, 0 files merged, 2 files removed, 0 files unresolved
+  $ hg bisect -g      # -> update to rev 13
+  Testing changeset 13:b0a32c86eb31 (8 changesets remaining, ~3 tests)
+  3 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -s      # -> update to rev 10
+  Testing changeset 10:429fcd26f52d (8 changesets remaining, ~3 tests)
+  3 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -s      # -> update to rev 12
+  Testing changeset 12:9f259202bbe7 (8 changesets remaining, ~3 tests)
+  3 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -g      # -> update to rev 9
+  Testing changeset 9:3c77083deb4a (5 changesets remaining, ~2 tests)
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -s      # -> update to rev 15
+  Testing changeset 15:857b178a7cf3 (5 changesets remaining, ~2 tests)
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg bisect -b
+  Due to skipped revisions, the first bad revision could be any of:
+  changeset:   9:3c77083deb4a
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     9
+  
+  changeset:   10:429fcd26f52d
+  parent:      9:3c77083deb4a
+  parent:      6:a214d5d3811a
+  user:        test
+  date:        Thu Jan 01 00:00:10 1970 +0000
+  summary:     merge 6,9
+  
+  changeset:   13:b0a32c86eb31
+  user:        test
+  date:        Thu Jan 01 00:00:13 1970 +0000
+  summary:     13
+  
+  changeset:   15:857b178a7cf3
+  parent:      13:b0a32c86eb31
+  parent:      10:429fcd26f52d
+  user:        test
+  date:        Thu Jan 01 00:00:15 1970 +0000
+  summary:     merge 10,13
+  
+
+complex bisect test 4
+
+first good revision is 17
+15,16 are skipped an might be the first good revisions as well
+
+  $ hg bisect -r
+  $ hg bisect -g 17
+  $ hg bisect -b 8    # -> update to rev 10
+  Testing changeset 13:b0a32c86eb31 (8 changesets remaining, ~3 tests)
+  2 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -b      # -> update to rev 13
+  Testing changeset 10:429fcd26f52d (5 changesets remaining, ~2 tests)
+  3 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg bisect -b      # -> update to rev 15
+  Testing changeset 15:857b178a7cf3 (3 changesets remaining, ~1 tests)
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg bisect -s      # -> update to rev 16
+  Testing changeset 16:609d82a7ebae (3 changesets remaining, ~1 tests)
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg bisect -s
+  Due to skipped revisions, the first good revision could be any of:
+  changeset:   15:857b178a7cf3
+  parent:      13:b0a32c86eb31
+  parent:      10:429fcd26f52d
+  user:        test
+  date:        Thu Jan 01 00:00:15 1970 +0000
+  summary:     merge 10,13
+  
+  changeset:   16:609d82a7ebae
+  user:        test
+  date:        Thu Jan 01 00:00:16 1970 +0000
+  summary:     16
+  
+  changeset:   17:228c06deef46
+  user:        test
+  date:        Thu Jan 01 00:00:17 1970 +0000
+  summary:     17
+  
--- a/tests/test-bookmarks	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,106 +0,0 @@
-#!/bin/sh
-
-echo "[extensions]" >> $HGRCPATH
-echo "bookmarks=" >> $HGRCPATH
-
-hg init
-
-echo % no bookmarks
-hg bookmarks
-
-echo % bookmark rev -1
-hg bookmark X
-
-echo % list bookmarks
-hg bookmarks
-
-echo % list bookmarks with color
-hg --config extensions.color= --config color.mode=ansi \
-    bookmarks --color=always
-
-echo a > a
-hg add a
-hg commit -m 0
-
-echo % bookmark X moved to rev 0
-hg bookmarks
-
-echo % look up bookmark
-hg log -r X
-
-echo % second bookmark for rev 0
-hg bookmark X2
-
-echo % bookmark rev -1 again
-hg bookmark -r null Y
-
-echo % list bookmarks
-hg bookmarks
-
-echo b > b
-hg add b
-hg commit -m 1
-
-echo % bookmarks X and X2 moved to rev 1, Y at rev -1
-hg bookmarks
-
-echo % bookmark rev 0 again
-hg bookmark -r 0 Z
-
-echo c > c
-hg add c
-hg commit -m 2
-
-echo % bookmarks X and X2 moved to rev 2, Y at rev -1, Z at rev 0
-hg bookmarks
-
-echo % rename nonexistent bookmark
-hg bookmark -m A B
-
-echo % rename to existent bookmark
-hg bookmark -m X Y
-
-echo % force rename to existent bookmark
-hg bookmark -f -m X Y
-
-echo % list bookmarks
-hg bookmark
-
-echo % rename without new name
-hg bookmark -m Y
-
-echo % delete without name
-hg bookmark -d
-
-echo % delete nonexistent bookmark
-hg bookmark -d A
-
-echo % bookmark name with spaces should be stripped
-hg bookmark ' x  y '
-
-echo % list bookmarks
-hg bookmarks
-
-echo % look up stripped bookmark name
-hg log -r '"x  y"'
-
-echo % reject bookmark name with newline
-hg bookmark '
-'
-
-echo % bookmark with existing name
-hg bookmark Z
-
-echo % force bookmark with existing name
-hg bookmark -f Z
-
-echo % list bookmarks
-hg bookmark
-
-echo % revision but no bookmark name
-hg bookmark -r .
-
-echo % bookmark name with whitespace only
-hg bookmark ' '
-
-true
--- a/tests/test-bookmarks-current	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,64 +0,0 @@
-#!/bin/sh
-
-echo "[extensions]" >> $HGRCPATH
-echo "bookmarks=" >> $HGRCPATH
-
-echo "[bookmarks]" >> $HGRCPATH
-echo "track.current = True" >> $HGRCPATH
-
-hg init
-
-echo % no bookmarks
-hg bookmarks
-
-echo % set bookmark X
-hg bookmark X
-
-echo % list bookmarks
-hg bookmark
-
-echo % list bookmarks with color
-hg --config extensions.color= --config color.mode=ansi \
-    bookmark --color=always
-
-echo % update to bookmark X
-hg update X
-
-echo % list bookmarks
-hg bookmarks
-
-echo % rename
-hg bookmark -m X Z
-
-echo % list bookmarks
-hg bookmarks
-
-echo % new bookmark Y
-hg bookmark Y
-
-echo % list bookmarks
-hg bookmark
-
-echo % commit
-echo 'b' > b
-hg add b
-hg commit -m'test'
-
-echo % list bookmarks
-hg bookmark
-
-echo % delete bookmarks
-hg bookmark -d Y
-hg bookmark -d Z
-
-echo % list bookmarks
-hg bookmark
-
-echo % update to tip
-hg update tip
-
-echo % set bookmark Y using -r .
-hg bookmark -r . Y
-
-echo % list bookmarks
-hg bookmark
--- a/tests/test-bookmarks-current.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,30 +0,0 @@
-% no bookmarks
-no bookmarks set
-% set bookmark X
-% list bookmarks
- * X                         -1:000000000000
-% list bookmarks with color
- * X                         -1:000000000000
-% update to bookmark X
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-% list bookmarks
- * X                         -1:000000000000
-% rename
-% list bookmarks
- * Z                         -1:000000000000
-% new bookmark Y
-% list bookmarks
- * Y                         -1:000000000000
-   Z                         -1:000000000000
-% commit
-% list bookmarks
- * Y                         0:719295282060
-   Z                         -1:000000000000
-% delete bookmarks
-% list bookmarks
-no bookmarks set
-% update to tip
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-% set bookmark Y using -r .
-% list bookmarks
- * Y                         0:719295282060
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bookmarks-current.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,92 @@
+  $ echo "[extensions]" >> $HGRCPATH
+  $ echo "bookmarks=" >> $HGRCPATH
+
+  $ echo "[bookmarks]" >> $HGRCPATH
+  $ echo "track.current = True" >> $HGRCPATH
+
+  $ hg init
+
+no bookmarks
+
+  $ hg bookmarks
+  no bookmarks set
+
+set bookmark X
+
+  $ hg bookmark X
+
+list bookmarks
+
+  $ hg bookmark
+   * X                         -1:000000000000
+
+list bookmarks with color
+
+  $ hg --config extensions.color= --config color.mode=ansi \
+  >     bookmark --color=always
+   * X                         -1:000000000000
+
+update to bookmark X
+
+  $ hg update X
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+list bookmarks
+
+  $ hg bookmarks
+   * X                         -1:000000000000
+
+rename
+
+  $ hg bookmark -m X Z
+
+list bookmarks
+
+  $ hg bookmarks
+   * Z                         -1:000000000000
+
+new bookmark Y
+
+  $ hg bookmark Y
+
+list bookmarks
+
+  $ hg bookmark
+   * Y                         -1:000000000000
+     Z                         -1:000000000000
+
+commit
+
+  $ echo 'b' > b
+  $ hg add b
+  $ hg commit -m'test'
+
+list bookmarks
+
+  $ hg bookmark
+   * Y                         0:719295282060
+     Z                         -1:000000000000
+
+delete bookmarks
+
+  $ hg bookmark -d Y
+  $ hg bookmark -d Z
+
+list bookmarks
+
+  $ hg bookmark
+  no bookmarks set
+
+update to tip
+
+  $ hg update tip
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+set bookmark Y using -r .
+
+  $ hg bookmark -r . Y
+
+list bookmarks
+
+  $ hg bookmark
+   * Y                         0:719295282060
--- a/tests/test-bookmarks-rebase	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,34 +0,0 @@
-#!/bin/sh
-
-. $TESTDIR/helpers.sh
-
-echo "[extensions]" >> $HGRCPATH
-echo "rebase=" >> $HGRCPATH
-echo "bookmarks=" >> $HGRCPATH
-
-echo % initialize repository
-hg init
-
-echo 'a' > a
-hg ci -A -m "0"
-
-echo 'b' > b
-hg ci -A -m "1"
-
-hg up 0
-echo 'c' > c
-hg ci -A -m "2"
-
-echo 'd' > d
-hg ci -A -m "3"
-
-hg bookmark -r 1 one
-hg bookmark -r 3 two
-
-echo % bookmark list
-hg bookmark
-
-echo % rebase
-hg rebase -s two -d one 2>&1 | cleanrebase
-
-hg log
--- a/tests/test-bookmarks-rebase.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,38 +0,0 @@
-% initialize repository
-adding a
-adding b
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-adding c
-created new head
-adding d
-% bookmark list
- * two                       3:2ae46b1d99a7
-   one                       1:925d80f479bb
-% rebase
-saved backup bundle to 
-changeset:   3:9163974d1cb5
-tag:         one
-tag:         tip
-tag:         two
-parent:      1:925d80f479bb
-parent:      2:db815d6d32e6
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     3
-
-changeset:   2:db815d6d32e6
-parent:      0:f7b1eb17ad24
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     2
-
-changeset:   1:925d80f479bb
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     1
-
-changeset:   0:f7b1eb17ad24
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     0
-
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bookmarks-rebase.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,70 @@
+  $ . $TESTDIR/helpers.sh
+
+  $ echo "[extensions]" >> $HGRCPATH
+  $ echo "rebase=" >> $HGRCPATH
+  $ echo "bookmarks=" >> $HGRCPATH
+
+initialize repository
+
+  $ hg init
+
+  $ echo 'a' > a
+  $ hg ci -A -m "0"
+  adding a
+
+  $ echo 'b' > b
+  $ hg ci -A -m "1"
+  adding b
+
+  $ hg up 0
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ echo 'c' > c
+  $ hg ci -A -m "2"
+  adding c
+  created new head
+
+  $ echo 'd' > d
+  $ hg ci -A -m "3"
+  adding d
+
+  $ hg bookmark -r 1 one
+  $ hg bookmark -r 3 two
+
+bookmark list
+
+  $ hg bookmark
+   * two                       3:2ae46b1d99a7
+     one                       1:925d80f479bb
+
+rebase
+
+  $ hg rebase -s two -d one 2>&1 | cleanrebase
+  saved backup bundle to 
+
+  $ hg log
+  changeset:   3:9163974d1cb5
+  tag:         one
+  tag:         tip
+  tag:         two
+  parent:      1:925d80f479bb
+  parent:      2:db815d6d32e6
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     3
+  
+  changeset:   2:db815d6d32e6
+  parent:      0:f7b1eb17ad24
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     2
+  
+  changeset:   1:925d80f479bb
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     1
+  
+  changeset:   0:f7b1eb17ad24
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     0
+  
--- a/tests/test-bookmarks-strip	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,45 +0,0 @@
-#!/bin/sh
-
-. $TESTDIR/helpers.sh
-echo "[extensions]" >> $HGRCPATH
-echo "bookmarks=" >> $HGRCPATH
-echo "mq=" >> $HGRCPATH
-
-hg init
-
-echo qqq>qqq.txt
-
-echo % add file
-hg add
-
-echo % commit first revision
-hg ci -m 1 -u user -d "1 0"
-
-echo % set bookmark
-hg book test
-
-echo www>>qqq.txt
-
-echo % commit second revision
-hg ci -m 2 -u usr -d "1 0"
-
-echo % set bookmark
-hg book test2
-
-echo % update to -2
-hg update -r -2
-
-echo eee>>qqq.txt
-
-echo % commit new head
-hg ci -m 3 -u user -d "1 0"
-
-echo % bookmarks updated?
-hg book
-
-echo % strip to revision 1
-hg strip 1 | hidebackup
-
-echo % list bookmarks
-hg book
-
--- a/tests/test-bookmarks-strip.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,18 +0,0 @@
-% add file
-adding qqq.txt
-% commit first revision
-% set bookmark
-% commit second revision
-% set bookmark
-% update to -2
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-% commit new head
-created new head
-% bookmarks updated?
-   test                      1:16b24da7e457
-   test2                     1:16b24da7e457
-% strip to revision 1
-saved backup bundle to 
-% list bookmarks
- * test                      1:9f1b7e78eff8
- * test2                     1:9f1b7e78eff8
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bookmarks-strip.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,61 @@
+  $ . $TESTDIR/helpers.sh
+  $ echo "[extensions]" >> $HGRCPATH
+  $ echo "bookmarks=" >> $HGRCPATH
+  $ echo "mq=" >> $HGRCPATH
+
+  $ hg init
+
+  $ echo qqq>qqq.txt
+
+add file
+
+  $ hg add
+  adding qqq.txt
+
+commit first revision
+
+  $ hg ci -m 1 -u user -d "1 0"
+
+set bookmark
+
+  $ hg book test
+
+  $ echo www>>qqq.txt
+
+commit second revision
+
+  $ hg ci -m 2 -u usr -d "1 0"
+
+set bookmark
+
+  $ hg book test2
+
+update to -2
+
+  $ hg update -r -2
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+  $ echo eee>>qqq.txt
+
+commit new head
+
+  $ hg ci -m 3 -u user -d "1 0"
+  created new head
+
+bookmarks updated?
+
+  $ hg book
+     test                      1:16b24da7e457
+     test2                     1:16b24da7e457
+
+strip to revision 1
+
+  $ hg strip 1 | hidebackup
+  saved backup bundle to 
+
+list bookmarks
+
+  $ hg book
+   * test                      1:9f1b7e78eff8
+   * test2                     1:9f1b7e78eff8
+
--- a/tests/test-bookmarks.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,78 +0,0 @@
-% no bookmarks
-no bookmarks set
-% bookmark rev -1
-% list bookmarks
- * X                         -1:000000000000
-% list bookmarks with color
- * X                         -1:000000000000
-% bookmark X moved to rev 0
- * X                         0:f7b1eb17ad24
-% look up bookmark
-changeset:   0:f7b1eb17ad24
-tag:         X
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     0
-
-% second bookmark for rev 0
-% bookmark rev -1 again
-% list bookmarks
- * X2                        0:f7b1eb17ad24
- * X                         0:f7b1eb17ad24
-   Y                         -1:000000000000
-% bookmarks X and X2 moved to rev 1, Y at rev -1
- * X2                        1:925d80f479bb
- * X                         1:925d80f479bb
-   Y                         -1:000000000000
-% bookmark rev 0 again
-% bookmarks X and X2 moved to rev 2, Y at rev -1, Z at rev 0
- * X2                        2:0316ce92851d
- * X                         2:0316ce92851d
-   Z                         0:f7b1eb17ad24
-   Y                         -1:000000000000
-% rename nonexistent bookmark
-abort: a bookmark of this name does not exist
-% rename to existent bookmark
-abort: a bookmark of the same name already exists
-% force rename to existent bookmark
-% list bookmarks
- * X2                        2:0316ce92851d
- * Y                         2:0316ce92851d
-   Z                         0:f7b1eb17ad24
-% rename without new name
-abort: new bookmark name required
-% delete without name
-abort: bookmark name required
-% delete nonexistent bookmark
-abort: a bookmark of this name does not exist
-% bookmark name with spaces should be stripped
-% list bookmarks
- * X2                        2:0316ce92851d
- * Y                         2:0316ce92851d
-   Z                         0:f7b1eb17ad24
- * x  y                      2:0316ce92851d
-% look up stripped bookmark name
-changeset:   2:0316ce92851d
-tag:         X2
-tag:         Y
-tag:         tip
-tag:         x  y
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     2
-
-% reject bookmark name with newline
-abort: bookmark name cannot contain newlines
-% bookmark with existing name
-abort: a bookmark of the same name already exists
-% force bookmark with existing name
-% list bookmarks
- * X2                        2:0316ce92851d
- * Y                         2:0316ce92851d
- * Z                         2:0316ce92851d
- * x  y                      2:0316ce92851d
-% revision but no bookmark name
-abort: bookmark name required
-% bookmark name with whitespace only
-abort: bookmark names cannot consist entirely of whitespace
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bookmarks.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,182 @@
+  $ echo "[extensions]" >> $HGRCPATH
+  $ echo "bookmarks=" >> $HGRCPATH
+
+  $ hg init
+
+no bookmarks
+
+  $ hg bookmarks
+  no bookmarks set
+
+bookmark rev -1
+
+  $ hg bookmark X
+
+list bookmarks
+
+  $ hg bookmarks
+   * X                         -1:000000000000
+
+list bookmarks with color
+
+  $ hg --config extensions.color= --config color.mode=ansi \
+  >    bookmarks --color=always
+   * X                         -1:000000000000
+
+  $ echo a > a
+  $ hg add a
+  $ hg commit -m 0
+
+bookmark X moved to rev 0
+
+  $ hg bookmarks
+   * X                         0:f7b1eb17ad24
+
+look up bookmark
+
+  $ hg log -r X
+  changeset:   0:f7b1eb17ad24
+  tag:         X
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     0
+  
+
+second bookmark for rev 0
+
+  $ hg bookmark X2
+
+bookmark rev -1 again
+
+  $ hg bookmark -r null Y
+
+list bookmarks
+
+  $ hg bookmarks
+   * X2                        0:f7b1eb17ad24
+   * X                         0:f7b1eb17ad24
+     Y                         -1:000000000000
+
+  $ echo b > b
+  $ hg add b
+  $ hg commit -m 1
+
+bookmarks X and X2 moved to rev 1, Y at rev -1
+
+  $ hg bookmarks
+   * X2                        1:925d80f479bb
+   * X                         1:925d80f479bb
+     Y                         -1:000000000000
+
+bookmark rev 0 again
+
+  $ hg bookmark -r 0 Z
+
+  $ echo c > c
+  $ hg add c
+  $ hg commit -m 2
+
+bookmarks X and X2 moved to rev 2, Y at rev -1, Z at rev 0
+
+  $ hg bookmarks
+   * X2                        2:0316ce92851d
+   * X                         2:0316ce92851d
+     Z                         0:f7b1eb17ad24
+     Y                         -1:000000000000
+
+rename nonexistent bookmark
+
+  $ hg bookmark -m A B
+  abort: a bookmark of this name does not exist
+
+rename to existent bookmark
+
+  $ hg bookmark -m X Y
+  abort: a bookmark of the same name already exists
+
+force rename to existent bookmark
+
+  $ hg bookmark -f -m X Y
+
+list bookmarks
+
+  $ hg bookmark
+   * X2                        2:0316ce92851d
+   * Y                         2:0316ce92851d
+     Z                         0:f7b1eb17ad24
+
+rename without new name
+
+  $ hg bookmark -m Y
+  abort: new bookmark name required
+
+delete without name
+
+  $ hg bookmark -d
+  abort: bookmark name required
+
+delete nonexistent bookmark
+
+  $ hg bookmark -d A
+  abort: a bookmark of this name does not exist
+
+bookmark name with spaces should be stripped
+
+  $ hg bookmark ' x  y '
+
+list bookmarks
+
+  $ hg bookmarks
+   * X2                        2:0316ce92851d
+   * Y                         2:0316ce92851d
+     Z                         0:f7b1eb17ad24
+   * x  y                      2:0316ce92851d
+
+look up stripped bookmark name
+
+  $ hg log -r '"x  y"'
+  changeset:   2:0316ce92851d
+  tag:         X2
+  tag:         Y
+  tag:         tip
+  tag:         x  y
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     2
+  
+
+reject bookmark name with newline
+
+  $ hg bookmark '
+  > '
+  abort: bookmark name cannot contain newlines
+
+bookmark with existing name
+
+  $ hg bookmark Z
+  abort: a bookmark of the same name already exists
+
+force bookmark with existing name
+
+  $ hg bookmark -f Z
+
+list bookmarks
+
+  $ hg bookmark
+   * X2                        2:0316ce92851d
+   * Y                         2:0316ce92851d
+   * Z                         2:0316ce92851d
+   * x  y                      2:0316ce92851d
+
+revision but no bookmark name
+
+  $ hg bookmark -r .
+  abort: bookmark name required
+
+bookmark name with whitespace only
+
+  $ hg bookmark ' '
+  abort: bookmark names cannot consist entirely of whitespace
+
+  $ true
--- a/tests/test-branch-option	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,60 +0,0 @@
-#!/bin/sh
-
-# test branch selection options
-hg init branch
-cd branch
-hg branch a
-echo a > foo
-hg ci -d '0 0' -Ama
-echo a2 > foo
-hg ci -d '0 0' -ma2
-hg up 0
-hg branch c
-echo c > foo
-hg ci -d '0 0' -mc
-hg tag -l z
-cd ..
-hg clone -r 0 branch branch2
-cd branch2
-hg up 0
-hg branch b
-echo b > foo
-hg ci -d '0 0' -mb
-hg up 0
-hg --encoding utf-8 branch æ
-echo ae1 > foo
-hg ci -d '0 0' -mae1
-hg up 0
-hg --encoding utf-8 branch -f æ
-echo ae2 > foo
-hg ci -d '0 0' -mae2
-hg up 0
-hg branch -f b
-echo b2 > foo
-hg ci -d '0 0' -mb2
-
-echo unknown branch and fallback
-hg in -qbz
-hg in -q ../branch#z
-hg out -qbz
-echo in rev c branch a
-hg in -qr c ../branch#a
-hg in -qr c -b a
-echo out branch .
-hg out -q ../branch#.
-hg out -q -b .
-echo out branch . non-ascii
-hg --encoding utf-8 up æ
-hg --encoding latin1 out -q ../branch#.
-hg --encoding latin1 out -q -b .
-echo clone branch b
-cd ..
-hg clone branch2#b branch3
-hg -q -R branch3 heads b
-hg -q -R branch3 parents
-rm -rf branch3
-echo clone rev a branch b
-hg clone -r a branch2#b branch3
-hg -q -R branch3 heads b
-hg -q -R branch3 parents
-rm -rf branch3
--- a/tests/test-branch-option.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,63 +0,0 @@
-marked working directory as branch a
-adding foo
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-marked working directory as branch c
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-updating to branch a
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-marked working directory as branch b
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-marked working directory as branch æ
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-marked working directory as branch æ
-created new head
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-marked working directory as branch b
-created new head
-unknown branch and fallback
-abort: unknown branch 'z'!
-2:f25d57ab0566
-abort: unknown branch 'z'!
-in rev c branch a
-1:dd6e60a716c6
-2:f25d57ab0566
-1:dd6e60a716c6
-2:f25d57ab0566
-out branch .
-1:b84708d77ab7
-4:65511d0e2b55
-1:b84708d77ab7
-4:65511d0e2b55
-out branch . non-ascii
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-2:df5a44224d4e
-3:4f4a5125ca10
-2:df5a44224d4e
-3:4f4a5125ca10
-clone branch b
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 3 changesets with 3 changes to 1 files (+1 heads)
-updating to branch b
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-2:65511d0e2b55
-1:b84708d77ab7
-2:65511d0e2b55
-clone rev a branch b
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 3 changesets with 3 changes to 1 files (+1 heads)
-updating to branch a
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-2:65511d0e2b55
-1:b84708d77ab7
-0:5b65ba7c951d
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-branch-option.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,127 @@
+test branch selection options
+
+  $ hg init branch
+  $ cd branch
+  $ hg branch a
+  marked working directory as branch a
+  $ echo a > foo
+  $ hg ci -d '0 0' -Ama
+  adding foo
+  $ echo a2 > foo
+  $ hg ci -d '0 0' -ma2
+  $ hg up 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg branch c
+  marked working directory as branch c
+  $ echo c > foo
+  $ hg ci -d '0 0' -mc
+  $ hg tag -l z
+  $ cd ..
+  $ hg clone -r 0 branch branch2
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  updating to branch a
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd branch2
+  $ hg up 0
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg branch b
+  marked working directory as branch b
+  $ echo b > foo
+  $ hg ci -d '0 0' -mb
+  $ hg up 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --encoding utf-8 branch æ
+  marked working directory as branch æ
+  $ echo ae1 > foo
+  $ hg ci -d '0 0' -mae1
+  $ hg up 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --encoding utf-8 branch -f æ
+  marked working directory as branch æ
+  $ echo ae2 > foo
+  $ hg ci -d '0 0' -mae2
+  created new head
+  $ hg up 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg branch -f b
+  marked working directory as branch b
+  $ echo b2 > foo
+  $ hg ci -d '0 0' -mb2
+  created new head
+
+unknown branch and fallback
+
+  $ hg in -qbz
+  abort: unknown branch 'z'!
+  $ hg in -q ../branch#z
+  2:f25d57ab0566
+  $ hg out -qbz
+  abort: unknown branch 'z'!
+
+in rev c branch a
+
+  $ hg in -qr c ../branch#a
+  1:dd6e60a716c6
+  2:f25d57ab0566
+  $ hg in -qr c -b a
+  1:dd6e60a716c6
+  2:f25d57ab0566
+
+out branch .
+
+  $ hg out -q ../branch#.
+  1:b84708d77ab7
+  4:65511d0e2b55
+  $ hg out -q -b .
+  1:b84708d77ab7
+  4:65511d0e2b55
+
+out branch . non-ascii
+
+  $ hg --encoding utf-8 up æ
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --encoding latin1 out -q ../branch#.
+  2:df5a44224d4e
+  3:4f4a5125ca10
+  $ hg --encoding latin1 out -q -b .
+  2:df5a44224d4e
+  3:4f4a5125ca10
+
+clone branch b
+
+  $ cd ..
+  $ hg clone branch2#b branch3
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 3 changesets with 3 changes to 1 files (+1 heads)
+  updating to branch b
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg -q -R branch3 heads b
+  2:65511d0e2b55
+  1:b84708d77ab7
+  $ hg -q -R branch3 parents
+  2:65511d0e2b55
+  $ rm -rf branch3
+
+clone rev a branch b
+
+  $ hg clone -r a branch2#b branch3
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 3 changesets with 3 changes to 1 files (+1 heads)
+  updating to branch a
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg -q -R branch3 heads b
+  2:65511d0e2b55
+  1:b84708d77ab7
+  $ hg -q -R branch3 parents
+  0:5b65ba7c951d
+  $ rm -rf branch3
--- a/tests/test-branches	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,94 +0,0 @@
-#!/bin/sh
-
-hg init a
-cd a
-echo 'root' >root
-hg add root
-hg commit -d '0 0' -m "Adding root node"
-
-echo 'a' >a
-hg add a
-hg branch a
-hg commit -d '1 0' -m "Adding a branch"
-
-hg branch q
-echo 'aa' >a
-hg branch -C
-hg commit -d '2 0' -m "Adding to a branch"
-
-hg update -C 0
-echo 'b' >b
-hg add b
-hg branch b
-hg commit -d '2 0' -m "Adding b branch"
-
-echo 'bh1' >bh1
-hg add bh1
-hg commit -d '3 0' -m "Adding b branch head 1"
-
-hg update -C 2
-echo 'bh2' >bh2
-hg add bh2
-hg commit -d '4 0' -m "Adding b branch head 2"
-
-echo 'c' >c
-hg add c
-hg branch c
-hg commit -d '5 0' -m "Adding c branch"
-
-hg branch tip
-hg branch null
-hg branch .
-
-echo 'd' >d
-hg add d
-hg branch 'a branch name much longer than the default justification used by branches'
-hg commit -d '6 0' -m "Adding d branch"
-
-hg branches
-echo '-------'
-hg branches -a
-
-echo "--- Branch a"
-hg log -b a
-
-echo "---- Branch b"
-hg log -b b
-
-echo "---- going to test branch closing"
-hg branches
-hg up -C b
-echo 'xxx1' >> b
-hg commit -d '7 0' -m 'adding cset to branch b'
-hg up -C aee39cd168d0
-echo 'xxx2' >> b
-hg commit -d '8 0' -m 'adding head to branch b'
-echo 'xxx3' >> b
-hg commit -d '9 0' -m 'adding another cset to branch b'
-hg branches
-hg heads --closed
-hg heads
-hg commit -d '9 0' --close-branch -m 'prune bad branch'
-hg branches -a
-hg up -C b
-hg commit -d '9 0' --close-branch -m 'close this part branch too'
-echo '--- b branch should be inactive'
-hg branches
-hg branches -c
-hg branches -a
-hg heads b
-hg heads --closed b
-echo 'xxx4' >> b
-hg commit -d '9 0' -m 'reopen branch with a change'
-echo '--- branch b is back in action'
-hg branches -a
-echo '---- test heads listings'
-hg heads
-echo '% branch default'
-hg heads default
-echo '% branch a'
-hg heads a
-hg heads --active a
-echo '% branch b'
-hg heads b
-hg heads --closed b
--- a/tests/test-branches.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,244 +0,0 @@
-marked working directory as branch a
-marked working directory as branch q
-reset working directory to branch a
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-marked working directory as branch b
-1 files updated, 0 files merged, 2 files removed, 0 files unresolved
-marked working directory as branch c
-abort: the name 'tip' is reserved
-abort: the name 'null' is reserved
-abort: the name '.' is reserved
-marked working directory as branch a branch name much longer than the default justification used by branches
-a branch name much longer than the default justification used by branches 7:10ff5895aa57
-b                              4:aee39cd168d0
-c                              6:589736a22561 (inactive)
-a                              5:d8cbc61dbaa6 (inactive)
-default                        0:19709c5a4e75 (inactive)
--------
-a branch name much longer than the default justification used by branches 7:10ff5895aa57
-b                              4:aee39cd168d0
---- Branch a
-changeset:   5:d8cbc61dbaa6
-branch:      a
-parent:      2:881fe2b92ad0
-user:        test
-date:        Thu Jan 01 00:00:04 1970 +0000
-summary:     Adding b branch head 2
-
-changeset:   2:881fe2b92ad0
-branch:      a
-user:        test
-date:        Thu Jan 01 00:00:02 1970 +0000
-summary:     Adding to a branch
-
-changeset:   1:dd6b440dd85a
-branch:      a
-user:        test
-date:        Thu Jan 01 00:00:01 1970 +0000
-summary:     Adding a branch
-
----- Branch b
-changeset:   4:aee39cd168d0
-branch:      b
-user:        test
-date:        Thu Jan 01 00:00:03 1970 +0000
-summary:     Adding b branch head 1
-
-changeset:   3:ac22033332d1
-branch:      b
-parent:      0:19709c5a4e75
-user:        test
-date:        Thu Jan 01 00:00:02 1970 +0000
-summary:     Adding b branch
-
----- going to test branch closing
-a branch name much longer than the default justification used by branches 7:10ff5895aa57
-b                              4:aee39cd168d0
-c                              6:589736a22561 (inactive)
-a                              5:d8cbc61dbaa6 (inactive)
-default                        0:19709c5a4e75 (inactive)
-2 files updated, 0 files merged, 4 files removed, 0 files unresolved
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-b                             10:bfbe841b666e
-a branch name much longer than the default justification used by branches 7:10ff5895aa57
-c                              6:589736a22561 (inactive)
-a                              5:d8cbc61dbaa6 (inactive)
-default                        0:19709c5a4e75 (inactive)
-changeset:   10:bfbe841b666e
-branch:      b
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     adding another cset to branch b
-
-changeset:   8:eebb944467c9
-branch:      b
-parent:      4:aee39cd168d0
-user:        test
-date:        Thu Jan 01 00:00:07 1970 +0000
-summary:     adding cset to branch b
-
-changeset:   7:10ff5895aa57
-branch:      a branch name much longer than the default justification used by branches
-user:        test
-date:        Thu Jan 01 00:00:06 1970 +0000
-summary:     Adding d branch
-
-changeset:   6:589736a22561
-branch:      c
-user:        test
-date:        Thu Jan 01 00:00:05 1970 +0000
-summary:     Adding c branch
-
-changeset:   5:d8cbc61dbaa6
-branch:      a
-parent:      2:881fe2b92ad0
-user:        test
-date:        Thu Jan 01 00:00:04 1970 +0000
-summary:     Adding b branch head 2
-
-changeset:   0:19709c5a4e75
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     Adding root node
-
-changeset:   10:bfbe841b666e
-branch:      b
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     adding another cset to branch b
-
-changeset:   8:eebb944467c9
-branch:      b
-parent:      4:aee39cd168d0
-user:        test
-date:        Thu Jan 01 00:00:07 1970 +0000
-summary:     adding cset to branch b
-
-changeset:   7:10ff5895aa57
-branch:      a branch name much longer than the default justification used by branches
-user:        test
-date:        Thu Jan 01 00:00:06 1970 +0000
-summary:     Adding d branch
-
-changeset:   6:589736a22561
-branch:      c
-user:        test
-date:        Thu Jan 01 00:00:05 1970 +0000
-summary:     Adding c branch
-
-changeset:   5:d8cbc61dbaa6
-branch:      a
-parent:      2:881fe2b92ad0
-user:        test
-date:        Thu Jan 01 00:00:04 1970 +0000
-summary:     Adding b branch head 2
-
-changeset:   0:19709c5a4e75
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     Adding root node
-
-b                              8:eebb944467c9
-a branch name much longer than the default justification used by branches 7:10ff5895aa57
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
---- b branch should be inactive
-a branch name much longer than the default justification used by branches 7:10ff5895aa57
-c                              6:589736a22561 (inactive)
-a                              5:d8cbc61dbaa6 (inactive)
-default                        0:19709c5a4e75 (inactive)
-a branch name much longer than the default justification used by branches 7:10ff5895aa57
-b                             12:2da6583810df (closed)
-c                              6:589736a22561 (inactive)
-a                              5:d8cbc61dbaa6 (inactive)
-default                        0:19709c5a4e75 (inactive)
-a branch name much longer than the default justification used by branches 7:10ff5895aa57
-no open branch heads found on branches b
-changeset:   12:2da6583810df
-branch:      b
-tag:         tip
-parent:      8:eebb944467c9
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     close this part branch too
-
-changeset:   11:c84627f3c15d
-branch:      b
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     prune bad branch
-
-reopening closed branch head 12
---- branch b is back in action
-b                             13:6ac12926b8c3
-a branch name much longer than the default justification used by branches 7:10ff5895aa57
----- test heads listings
-changeset:   13:6ac12926b8c3
-branch:      b
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     reopen branch with a change
-
-changeset:   7:10ff5895aa57
-branch:      a branch name much longer than the default justification used by branches
-user:        test
-date:        Thu Jan 01 00:00:06 1970 +0000
-summary:     Adding d branch
-
-changeset:   6:589736a22561
-branch:      c
-user:        test
-date:        Thu Jan 01 00:00:05 1970 +0000
-summary:     Adding c branch
-
-changeset:   5:d8cbc61dbaa6
-branch:      a
-parent:      2:881fe2b92ad0
-user:        test
-date:        Thu Jan 01 00:00:04 1970 +0000
-summary:     Adding b branch head 2
-
-changeset:   0:19709c5a4e75
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     Adding root node
-
-% branch default
-changeset:   0:19709c5a4e75
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     Adding root node
-
-% branch a
-changeset:   5:d8cbc61dbaa6
-branch:      a
-parent:      2:881fe2b92ad0
-user:        test
-date:        Thu Jan 01 00:00:04 1970 +0000
-summary:     Adding b branch head 2
-
-no open branch heads found on branches a
-% branch b
-changeset:   13:6ac12926b8c3
-branch:      b
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     reopen branch with a change
-
-changeset:   13:6ac12926b8c3
-branch:      b
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     reopen branch with a change
-
-changeset:   11:c84627f3c15d
-branch:      b
-user:        test
-date:        Thu Jan 01 00:00:09 1970 +0000
-summary:     prune bad branch
-
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-branches.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,343 @@
+  $ hg init a
+  $ cd a
+  $ echo 'root' >root
+  $ hg add root
+  $ hg commit -d '0 0' -m "Adding root node"
+
+  $ echo 'a' >a
+  $ hg add a
+  $ hg branch a
+  marked working directory as branch a
+  $ hg commit -d '1 0' -m "Adding a branch"
+
+  $ hg branch q
+  marked working directory as branch q
+  $ echo 'aa' >a
+  $ hg branch -C
+  reset working directory to branch a
+  $ hg commit -d '2 0' -m "Adding to a branch"
+
+  $ hg update -C 0
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ echo 'b' >b
+  $ hg add b
+  $ hg branch b
+  marked working directory as branch b
+  $ hg commit -d '2 0' -m "Adding b branch"
+
+  $ echo 'bh1' >bh1
+  $ hg add bh1
+  $ hg commit -d '3 0' -m "Adding b branch head 1"
+
+  $ hg update -C 2
+  1 files updated, 0 files merged, 2 files removed, 0 files unresolved
+  $ echo 'bh2' >bh2
+  $ hg add bh2
+  $ hg commit -d '4 0' -m "Adding b branch head 2"
+
+  $ echo 'c' >c
+  $ hg add c
+  $ hg branch c
+  marked working directory as branch c
+  $ hg commit -d '5 0' -m "Adding c branch"
+
+  $ hg branch tip
+  abort: the name 'tip' is reserved
+  $ hg branch null
+  abort: the name 'null' is reserved
+  $ hg branch .
+  abort: the name '.' is reserved
+
+  $ echo 'd' >d
+  $ hg add d
+  $ hg branch 'a branch name much longer than the default justification used by branches'
+  marked working directory as branch a branch name much longer than the default justification used by branches
+  $ hg commit -d '6 0' -m "Adding d branch"
+
+  $ hg branches
+  a branch name much longer than the default justification used by branches 7:10ff5895aa57
+  b                              4:aee39cd168d0
+  c                              6:589736a22561 (inactive)
+  a                              5:d8cbc61dbaa6 (inactive)
+  default                        0:19709c5a4e75 (inactive)
+
+-------
+
+  $ hg branches -a
+  a branch name much longer than the default justification used by branches 7:10ff5895aa57
+  b                              4:aee39cd168d0
+
+--- Branch a
+
+  $ hg log -b a
+  changeset:   5:d8cbc61dbaa6
+  branch:      a
+  parent:      2:881fe2b92ad0
+  user:        test
+  date:        Thu Jan 01 00:00:04 1970 +0000
+  summary:     Adding b branch head 2
+  
+  changeset:   2:881fe2b92ad0
+  branch:      a
+  user:        test
+  date:        Thu Jan 01 00:00:02 1970 +0000
+  summary:     Adding to a branch
+  
+  changeset:   1:dd6b440dd85a
+  branch:      a
+  user:        test
+  date:        Thu Jan 01 00:00:01 1970 +0000
+  summary:     Adding a branch
+  
+
+---- Branch b
+
+  $ hg log -b b
+  changeset:   4:aee39cd168d0
+  branch:      b
+  user:        test
+  date:        Thu Jan 01 00:00:03 1970 +0000
+  summary:     Adding b branch head 1
+  
+  changeset:   3:ac22033332d1
+  branch:      b
+  parent:      0:19709c5a4e75
+  user:        test
+  date:        Thu Jan 01 00:00:02 1970 +0000
+  summary:     Adding b branch
+  
+
+---- going to test branch closing
+
+  $ hg branches
+  a branch name much longer than the default justification used by branches 7:10ff5895aa57
+  b                              4:aee39cd168d0
+  c                              6:589736a22561 (inactive)
+  a                              5:d8cbc61dbaa6 (inactive)
+  default                        0:19709c5a4e75 (inactive)
+  $ hg up -C b
+  2 files updated, 0 files merged, 4 files removed, 0 files unresolved
+  $ echo 'xxx1' >> b
+  $ hg commit -d '7 0' -m 'adding cset to branch b'
+  $ hg up -C aee39cd168d0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo 'xxx2' >> b
+  $ hg commit -d '8 0' -m 'adding head to branch b'
+  created new head
+  $ echo 'xxx3' >> b
+  $ hg commit -d '9 0' -m 'adding another cset to branch b'
+  $ hg branches
+  b                             10:bfbe841b666e
+  a branch name much longer than the default justification used by branches 7:10ff5895aa57
+  c                              6:589736a22561 (inactive)
+  a                              5:d8cbc61dbaa6 (inactive)
+  default                        0:19709c5a4e75 (inactive)
+  $ hg heads --closed
+  changeset:   10:bfbe841b666e
+  branch:      b
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     adding another cset to branch b
+  
+  changeset:   8:eebb944467c9
+  branch:      b
+  parent:      4:aee39cd168d0
+  user:        test
+  date:        Thu Jan 01 00:00:07 1970 +0000
+  summary:     adding cset to branch b
+  
+  changeset:   7:10ff5895aa57
+  branch:      a branch name much longer than the default justification used by branches
+  user:        test
+  date:        Thu Jan 01 00:00:06 1970 +0000
+  summary:     Adding d branch
+  
+  changeset:   6:589736a22561
+  branch:      c
+  user:        test
+  date:        Thu Jan 01 00:00:05 1970 +0000
+  summary:     Adding c branch
+  
+  changeset:   5:d8cbc61dbaa6
+  branch:      a
+  parent:      2:881fe2b92ad0
+  user:        test
+  date:        Thu Jan 01 00:00:04 1970 +0000
+  summary:     Adding b branch head 2
+  
+  changeset:   0:19709c5a4e75
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     Adding root node
+  
+  $ hg heads
+  changeset:   10:bfbe841b666e
+  branch:      b
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     adding another cset to branch b
+  
+  changeset:   8:eebb944467c9
+  branch:      b
+  parent:      4:aee39cd168d0
+  user:        test
+  date:        Thu Jan 01 00:00:07 1970 +0000
+  summary:     adding cset to branch b
+  
+  changeset:   7:10ff5895aa57
+  branch:      a branch name much longer than the default justification used by branches
+  user:        test
+  date:        Thu Jan 01 00:00:06 1970 +0000
+  summary:     Adding d branch
+  
+  changeset:   6:589736a22561
+  branch:      c
+  user:        test
+  date:        Thu Jan 01 00:00:05 1970 +0000
+  summary:     Adding c branch
+  
+  changeset:   5:d8cbc61dbaa6
+  branch:      a
+  parent:      2:881fe2b92ad0
+  user:        test
+  date:        Thu Jan 01 00:00:04 1970 +0000
+  summary:     Adding b branch head 2
+  
+  changeset:   0:19709c5a4e75
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     Adding root node
+  
+  $ hg commit -d '9 0' --close-branch -m 'prune bad branch'
+  $ hg branches -a
+  b                              8:eebb944467c9
+  a branch name much longer than the default justification used by branches 7:10ff5895aa57
+  $ hg up -C b
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg commit -d '9 0' --close-branch -m 'close this part branch too'
+
+--- b branch should be inactive
+
+  $ hg branches
+  a branch name much longer than the default justification used by branches 7:10ff5895aa57
+  c                              6:589736a22561 (inactive)
+  a                              5:d8cbc61dbaa6 (inactive)
+  default                        0:19709c5a4e75 (inactive)
+  $ hg branches -c
+  a branch name much longer than the default justification used by branches 7:10ff5895aa57
+  b                             12:2da6583810df (closed)
+  c                              6:589736a22561 (inactive)
+  a                              5:d8cbc61dbaa6 (inactive)
+  default                        0:19709c5a4e75 (inactive)
+  $ hg branches -a
+  a branch name much longer than the default justification used by branches 7:10ff5895aa57
+  $ hg heads b
+  no open branch heads found on branches b
+  $ hg heads --closed b
+  changeset:   12:2da6583810df
+  branch:      b
+  tag:         tip
+  parent:      8:eebb944467c9
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     close this part branch too
+  
+  changeset:   11:c84627f3c15d
+  branch:      b
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     prune bad branch
+  
+  $ echo 'xxx4' >> b
+  $ hg commit -d '9 0' -m 'reopen branch with a change'
+  reopening closed branch head 12
+
+--- branch b is back in action
+
+  $ hg branches -a
+  b                             13:6ac12926b8c3
+  a branch name much longer than the default justification used by branches 7:10ff5895aa57
+
+---- test heads listings
+
+  $ hg heads
+  changeset:   13:6ac12926b8c3
+  branch:      b
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     reopen branch with a change
+  
+  changeset:   7:10ff5895aa57
+  branch:      a branch name much longer than the default justification used by branches
+  user:        test
+  date:        Thu Jan 01 00:00:06 1970 +0000
+  summary:     Adding d branch
+  
+  changeset:   6:589736a22561
+  branch:      c
+  user:        test
+  date:        Thu Jan 01 00:00:05 1970 +0000
+  summary:     Adding c branch
+  
+  changeset:   5:d8cbc61dbaa6
+  branch:      a
+  parent:      2:881fe2b92ad0
+  user:        test
+  date:        Thu Jan 01 00:00:04 1970 +0000
+  summary:     Adding b branch head 2
+  
+  changeset:   0:19709c5a4e75
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     Adding root node
+  
+
+branch default
+
+  $ hg heads default
+  changeset:   0:19709c5a4e75
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     Adding root node
+  
+
+branch a
+
+  $ hg heads a
+  changeset:   5:d8cbc61dbaa6
+  branch:      a
+  parent:      2:881fe2b92ad0
+  user:        test
+  date:        Thu Jan 01 00:00:04 1970 +0000
+  summary:     Adding b branch head 2
+  
+  $ hg heads --active a
+  no open branch heads found on branches a
+
+branch b
+
+  $ hg heads b
+  changeset:   13:6ac12926b8c3
+  branch:      b
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     reopen branch with a change
+  
+  $ hg heads --closed b
+  changeset:   13:6ac12926b8c3
+  branch:      b
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     reopen branch with a change
+  
+  changeset:   11:c84627f3c15d
+  branch:      b
+  user:        test
+  date:        Thu Jan 01 00:00:09 1970 +0000
+  summary:     prune bad branch
+  
--- a/tests/test-branchmap	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,58 +0,0 @@
-#!/bin/sh
-
-hgserve()
-{
-    hg serve -a localhost -p $HGPORT1 -d --pid-file=hg.pid -E errors.log -v $@ \
-        | sed -e 's/:[0-9][0-9]*//g' -e 's/http:\/\/[^/]*\//http:\/\/localhost\//'
-    cat hg.pid >> "$DAEMON_PIDS"
-}
-
-hg init a
-hg --encoding utf-8 -R a branch æ
-echo foo > a/foo
-hg -R a ci -Am foo
-
-hgserve -R a --config web.push_ssl=False --config web.allow_push=* --encoding latin1
-hg --encoding utf-8 clone http://localhost:$HGPORT1 b
-hg --encoding utf-8 -R b log
-echo bar >> b/foo
-hg -R b ci -m bar
-hg --encoding utf-8 -R b push | sed "s/$HGPORT1/PORT/"
-hg -R a --encoding utf-8 log
-
-kill `cat hg.pid`
-
-
-# verify 7e7d56fe4833 (encoding fallback in branchmap to maintain compatibility with 1.3.x)
-
-cat <<EOF > oldhg
-import sys
-from mercurial import ui, hg, commands
-
-class StdoutWrapper(object):
-    def __init__(self, stdout):
-        self._file = stdout
-
-    def write(self, data):
-        if data == '47\n':
-            # latin1 encoding is one %xx (3 bytes) shorter
-            data = '44\n'
-        elif data.startswith('%C3%A6 '):
-            # translate to latin1 encoding
-            data = '%%E6 %s' % data[7:]
-        self._file.write(data)
-
-    def __getattr__(self, name):
-        return getattr(self._file, name)
-
-sys.stdout = StdoutWrapper(sys.stdout)
-sys.stderr = StdoutWrapper(sys.stderr)
-
-myui = ui.ui()
-repo = hg.repository(myui, 'a')
-commands.serve(myui, repo, stdio=True)
-EOF
-
-echo baz >> b/foo
-hg -R b ci -m baz
-hg push -R b -e 'python oldhg' ssh://dummy/ --encoding latin1
--- a/tests/test-branchmap.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,42 +0,0 @@
-marked working directory as branch æ
-adding foo
-listening at http://localhost/ (bound to 127.0.0.1)
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-updating to branch æ
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-changeset:   0:867c11ce77b8
-branch:      æ
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     foo
-
-pushing to http://localhost:PORT
-searching for changes
-remote: adding changesets
-remote: adding manifests
-remote: adding file changes
-remote: added 1 changesets with 1 changes to 1 files
-changeset:   1:58e7c90d67cb
-branch:      æ
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     bar
-
-changeset:   0:867c11ce77b8
-branch:      æ
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     foo
-
-pushing to ssh://dummy/
-searching for changes
-remote: adding changesets
-remote: adding manifests
-remote: adding file changes
-remote: added 1 changesets with 1 changes to 1 files
--- a/tests/test-bundle	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,168 +0,0 @@
-#!/bin/sh
-
-cp "$TESTDIR"/printenv.py .
-
-echo "====== Setting up test"
-hg init test
-cd test
-echo 0 > afile
-hg add afile
-hg commit -m "0.0" -d "1000000 0"
-echo 1 >> afile
-hg commit -m "0.1" -d "1000000 0"
-echo 2 >> afile
-hg commit -m "0.2" -d "1000000 0"
-echo 3 >> afile
-hg commit -m "0.3" -d "1000000 0"
-hg update -C 0
-echo 1 >> afile
-hg commit -m "1.1" -d "1000000 0"
-echo 2 >> afile
-hg commit -m "1.2" -d "1000000 0"
-echo "a line" > fred
-echo 3 >> afile
-hg add fred
-hg commit -m "1.3" -d "1000000 0"
-hg mv afile adifferentfile
-hg commit -m "1.3m" -d "1000000 0"
-hg update -C 3
-hg mv afile anotherfile
-hg commit -m "0.3m" -d "1000000 0"
-hg verify
-cd ..
-hg init empty
-
-echo "====== Bundle --all"
-hg -R test bundle --all all.hg
-
-echo "====== Bundle test to full.hg"
-hg -R test bundle full.hg empty
-echo "====== Unbundle full.hg in test"
-hg -R test unbundle full.hg
-echo "====== Verify empty"
-hg -R empty heads
-hg -R empty verify
-
-echo "====== Pull full.hg into test (using --cwd)"
-hg --cwd test pull ../full.hg
-echo "====== Pull full.hg into empty (using --cwd)"
-hg --cwd empty pull ../full.hg
-echo "====== Rollback empty"
-hg -R empty rollback
-echo "====== Pull full.hg into empty again (using --cwd)"
-hg --cwd empty pull ../full.hg
-
-echo "====== Pull full.hg into test (using -R)"
-hg -R test pull full.hg
-echo "====== Pull full.hg into empty (using -R)"
-hg -R empty pull full.hg
-echo "====== Rollback empty"
-hg -R empty rollback
-echo "====== Pull full.hg into empty again (using -R)"
-hg -R empty pull full.hg
-
-echo "====== Log -R full.hg in fresh empty"
-rm -r empty
-hg init empty
-cd empty
-hg -R bundle://../full.hg log
-
-echo "====== Pull ../full.hg into empty (with hook)"
-echo '[hooks]' >> .hg/hgrc
-echo 'changegroup = python ../printenv.py changegroup' >> .hg/hgrc
-#doesn't work (yet ?)
-#hg -R bundle://../full.hg verify
-hg pull bundle://../full.hg
-echo "====== Rollback empty"
-hg rollback
-cd ..
-echo "====== Log -R bundle:empty+full.hg"
-hg -R bundle:empty+full.hg log --template="{rev} "
-echo ""
-echo "====== Pull full.hg into empty again (using -R; with hook)"
-hg -R empty pull full.hg
-
-echo "====== Create partial clones"
-rm -r empty
-hg init empty
-hg clone -r 3 test partial
-hg clone partial partial2
-cd partial
-echo "====== Log -R full.hg in partial"
-hg -R bundle://../full.hg log
-echo "====== Incoming full.hg in partial"
-hg incoming bundle://../full.hg
-echo "====== Outgoing -R full.hg vs partial2 in partial"
-hg -R bundle://../full.hg outgoing ../partial2
-echo "====== Outgoing -R does-not-exist.hg vs partial2 in partial"
-hg -R bundle://../does-not-exist.hg outgoing ../partial2
-cd ..
-
-echo "====== Direct clone from bundle (all-history)"
-hg clone full.hg full-clone
-hg -R full-clone heads
-rm -r full-clone
-
-# test for http://mercurial.selenic.com/bts/issue216
-echo "====== Unbundle incremental bundles into fresh empty in one go"
-rm -r empty
-hg init empty
-hg -R test bundle --base null -r 0 ../0.hg
-hg -R test bundle --base 0    -r 1 ../1.hg
-hg -R empty unbundle -u ../0.hg ../1.hg
-
-# test for 540d1059c802
-echo "====== test for 540d1059c802"
-hg init orig
-cd orig
-echo foo > foo
-hg add foo
-hg ci -m 'add foo'
-
-hg clone . ../copy
-hg tag foo
-
-cd ../copy
-echo >> foo
-hg ci -m 'change foo'
-hg bundle ../bundle.hg ../orig
-
-cd ../orig
-hg incoming ../bundle.hg
-cd ..
-
-# test for http://mercurial.selenic.com/bts/issue1144
-echo "===== test that verify bundle does not traceback"
-# partial history bundle, fails w/ unkown parent
-hg -R bundle.hg verify
-# full history bundle, refuses to verify non-local repo
-hg -R all.hg verify
-# but, regular verify must continue to work
-hg -R orig verify
-
-echo "====== diff against bundle"
-hg init b
-cd b
-hg -R ../all.hg diff -r tip
-cd ..
-
-echo "====== bundle single branch"
-hg init branchy
-cd branchy
-echo a >a
-hg ci -Ama
-echo b >b
-hg ci -Amb
-echo b1 >b1
-hg ci -Amb1
-hg up 0
-echo c >c
-hg ci -Amc
-echo c1 >c1
-hg ci -Amc1
-hg clone -q .#tip part
-echo "== bundling via incoming"
-hg in -R part --bundle incoming.hg --template "{node}\n" .
-echo "== bundling"
-hg bundle bundle.hg part --debug
-
--- a/tests/test-bundle-r	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,122 +0,0 @@
-#!/bin/sh
-
-hg init test
-cd test
-cat >>afile <<EOF
-0
-EOF
-hg add afile
-hg commit -m "0.0" -d "1000000 0"
-cat >>afile <<EOF
-1
-EOF
-hg commit -m "0.1" -d "1000000 0"
-cat >>afile <<EOF
-2
-EOF
-hg commit -m "0.2" -d "1000000 0"
-cat >>afile <<EOF
-3
-EOF
-hg commit -m "0.3" -d "1000000 0"
-hg update -C 0
-cat >>afile <<EOF
-1
-EOF
-hg commit -m "1.1" -d "1000000 0"
-cat >>afile <<EOF
-2
-EOF
-hg commit -m "1.2" -d "1000000 0"
-cat >fred <<EOF
-a line
-EOF
-cat >>afile <<EOF
-3
-EOF
-hg add fred
-hg commit -m "1.3" -d "1000000 0"
-hg mv afile adifferentfile
-hg commit -m "1.3m" -d "1000000 0"
-hg update -C 3
-hg mv afile anotherfile
-hg commit -m "0.3m" -d "1000000 0"
-hg debugindex .hg/store/data/afile.i
-hg debugindex .hg/store/data/adifferentfile.i
-hg debugindex .hg/store/data/anotherfile.i
-hg debugindex .hg/store/data/fred.i
-hg debugindex .hg/store/00manifest.i
-hg verify
-cd ..
-for i in 0 1 2 3 4 5 6 7 8; do
-   mkdir test-"$i"
-   hg --cwd test-"$i" init
-   hg -R test bundle -r "$i" test-"$i".hg test-"$i"
-   cd test-"$i"
-   hg unbundle ../test-"$i".hg
-   hg verify
-   hg tip -q
-   cd ..
-done
-cd test-8
-hg pull ../test-7
-hg verify
-hg rollback
-cd ..
-
-echo % should fail
-hg -R test bundle --base 2 -r tip test-bundle-branch1.hg test-3
-hg -R test bundle -r tip test-bundle-branch1.hg
-
-hg -R test bundle --base 2 -r tip test-bundle-branch1.hg
-hg -R test bundle --base 2 -r 7 test-bundle-branch2.hg
-hg -R test bundle --base 2 test-bundle-all.hg
-hg -R test bundle --base 3 -r tip test-bundle-should-fail.hg
-# empty bundle
-hg -R test bundle --base 7 --base 8 test-bundle-empty.hg
-
-# issue76 msg2163
-hg -R test bundle --base 3 -r 3 -r 3 test-bundle-cset-3.hg
-# issue1910
-hg -R test bundle --base 7 test-bundle-cset-7.hg
-
-hg clone test-2 test-9
-cd test-9
-echo % 2
-hg tip -q
-hg unbundle ../test-bundle-should-fail.hg
-echo % 2
-hg tip -q
-hg unbundle ../test-bundle-all.hg
-echo % 8
-hg tip -q
-hg verify
-hg rollback
-echo % 2
-hg tip -q
-hg unbundle ../test-bundle-branch1.hg
-echo % 4
-hg tip -q
-hg verify
-hg rollback
-hg unbundle ../test-bundle-branch2.hg
-echo % 6
-hg tip -q
-hg verify
-hg rollback
-hg unbundle ../test-bundle-cset-7.hg
-echo % 4
-hg tip -q
-hg verify
-
-cd ../test
-hg merge 7
-hg ci -m merge -d "1000000 0"
-cd ..
-hg -R test bundle --base 2 test-bundle-head.hg
-hg clone test-2 test-10
-cd test-10
-hg unbundle ../test-bundle-head.hg
-echo % 9
-hg tip -q
-hg verify
--- a/tests/test-bundle-r.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,250 +0,0 @@
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-1 files updated, 0 files merged, 2 files removed, 0 files unresolved
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0       3      0       0 362fef284ce2 000000000000 000000000000
-     1         3       5      1       1 125144f7e028 362fef284ce2 000000000000
-     2         8       7      2       2 4c982badb186 125144f7e028 000000000000
-     3        15       9      3       3 19b1fc555737 4c982badb186 000000000000
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0      75      0       7 2565f3199a74 000000000000 000000000000
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0      75      0       8 2565f3199a74 000000000000 000000000000
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0       8      0       6 12ab3bcc5ea4 000000000000 000000000000
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0      48      0       0 43eadb1d2d06 000000000000 000000000000
-     1        48      48      1       1 8b89697eba2c 43eadb1d2d06 000000000000
-     2        96      48      2       2 626a32663c2f 8b89697eba2c 000000000000
-     3       144      48      3       3 f54c32f13478 626a32663c2f 000000000000
-     4       192      58      3       6 de68e904d169 626a32663c2f 000000000000
-     5       250      68      3       7 09bb521d218d de68e904d169 000000000000
-     6       318      54      6       8 1fde233dfb0f f54c32f13478 000000000000
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-4 files, 9 changesets, 7 total revisions
-searching for changes
-1 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-(run 'hg update' to get a working copy)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-1 files, 1 changesets, 1 total revisions
-0:5649c9d34dd8
-searching for changes
-2 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 2 changesets with 2 changes to 1 files
-(run 'hg update' to get a working copy)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-1 files, 2 changesets, 2 total revisions
-1:10b2180f755b
-searching for changes
-3 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 3 changesets with 3 changes to 1 files
-(run 'hg update' to get a working copy)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-1 files, 3 changesets, 3 total revisions
-2:d62976ca1e50
-searching for changes
-4 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 4 changesets with 4 changes to 1 files
-(run 'hg update' to get a working copy)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-1 files, 4 changesets, 4 total revisions
-3:ac69c658229d
-searching for changes
-2 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 2 changesets with 2 changes to 1 files
-(run 'hg update' to get a working copy)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-1 files, 2 changesets, 2 total revisions
-1:5f4f3ceb285e
-searching for changes
-3 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 3 changesets with 3 changes to 1 files
-(run 'hg update' to get a working copy)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-1 files, 3 changesets, 3 total revisions
-2:024e4e7df376
-searching for changes
-4 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 4 changesets with 5 changes to 2 files
-(run 'hg update' to get a working copy)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-2 files, 4 changesets, 5 total revisions
-3:1e3f6b843bd6
-searching for changes
-5 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 5 changesets with 6 changes to 3 files
-(run 'hg update' to get a working copy)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-3 files, 5 changesets, 6 total revisions
-4:27f57c869697
-searching for changes
-5 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 5 changesets with 5 changes to 2 files
-(run 'hg update' to get a working copy)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-2 files, 5 changesets, 5 total revisions
-4:088ff9d6e1e1
-pulling from ../test-7
-searching for changes
-adding changesets
-adding manifests
-adding file changes
-added 4 changesets with 2 changes to 3 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-4 files, 9 changesets, 7 total revisions
-rolling back to revision 4 (undo pull)
-% should fail
-abort: --base is incompatible with specifying a destination
-abort: repository default-push not found!
-2 changesets found
-4 changesets found
-6 changesets found
-1 changesets found
-no changes found
-1 changesets found
-4 changesets found
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-% 2
-2:d62976ca1e50
-adding changesets
-transaction abort!
-rollback completed
-abort: 00changelog.i@ac69c658229d: unknown parent!
-% 2
-2:d62976ca1e50
-adding changesets
-adding manifests
-adding file changes
-added 6 changesets with 4 changes to 4 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-% 8
-8:088ff9d6e1e1
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-4 files, 9 changesets, 7 total revisions
-rolling back to revision 2 (undo unbundle)
-% 2
-2:d62976ca1e50
-adding changesets
-adding manifests
-adding file changes
-added 2 changesets with 2 changes to 2 files
-(run 'hg update' to get a working copy)
-% 4
-4:088ff9d6e1e1
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-2 files, 5 changesets, 5 total revisions
-rolling back to revision 2 (undo unbundle)
-adding changesets
-adding manifests
-adding file changes
-added 4 changesets with 3 changes to 3 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-% 6
-6:27f57c869697
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-3 files, 7 changesets, 6 total revisions
-rolling back to revision 2 (undo unbundle)
-adding changesets
-adding manifests
-adding file changes
-added 2 changesets with 2 changes to 2 files
-(run 'hg update' to get a working copy)
-% 4
-4:088ff9d6e1e1
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-2 files, 5 changesets, 5 total revisions
-warning: detected divergent renames of afile to:
- anotherfile
- adifferentfile
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-7 changesets found
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-adding changesets
-adding manifests
-adding file changes
-added 7 changesets with 4 changes to 4 files
-(run 'hg update' to get a working copy)
-% 9
-9:e3061ea42e4c
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-4 files, 10 changesets, 7 total revisions
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bundle-r.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,367 @@
+  $ hg init test
+  $ cd test
+  $ echo "0" >> afile
+  $ hg add afile
+  $ hg commit -m "0.0" -d "1000000 0"
+  $ echo "1" >> afile
+  $ hg commit -m "0.1" -d "1000000 0"
+  $ echo "2" >> afile
+  $ hg commit -m "0.2" -d "1000000 0"
+  $ echo "3" >> afile
+  $ hg commit -m "0.3" -d "1000000 0"
+  $ hg update -C 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo "1" >> afile
+  $ hg commit -m "1.1" -d "1000000 0"
+  created new head
+  $ echo "2" >> afile
+  $ hg commit -m "1.2" -d "1000000 0"
+  $ echo "a line" > fred
+  $ echo "3" >> afile
+  $ hg add fred
+  $ hg commit -m "1.3" -d "1000000 0"
+  $ hg mv afile adifferentfile
+  $ hg commit -m "1.3m" -d "1000000 0"
+  $ hg update -C 3
+  1 files updated, 0 files merged, 2 files removed, 0 files unresolved
+  $ hg mv afile anotherfile
+  $ hg commit -m "0.3m" -d "1000000 0"
+  $ hg debugindex .hg/store/data/afile.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0       3      0       0 362fef284ce2 000000000000 000000000000
+       1         3       5      1       1 125144f7e028 362fef284ce2 000000000000
+       2         8       7      2       2 4c982badb186 125144f7e028 000000000000
+       3        15       9      3       3 19b1fc555737 4c982badb186 000000000000
+  $ hg debugindex .hg/store/data/adifferentfile.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0      75      0       7 2565f3199a74 000000000000 000000000000
+  $ hg debugindex .hg/store/data/anotherfile.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0      75      0       8 2565f3199a74 000000000000 000000000000
+  $ hg debugindex .hg/store/data/fred.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0       8      0       6 12ab3bcc5ea4 000000000000 000000000000
+  $ hg debugindex .hg/store/00manifest.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0      48      0       0 43eadb1d2d06 000000000000 000000000000
+       1        48      48      1       1 8b89697eba2c 43eadb1d2d06 000000000000
+       2        96      48      2       2 626a32663c2f 8b89697eba2c 000000000000
+       3       144      48      3       3 f54c32f13478 626a32663c2f 000000000000
+       4       192      58      3       6 de68e904d169 626a32663c2f 000000000000
+       5       250      68      3       7 09bb521d218d de68e904d169 000000000000
+       6       318      54      6       8 1fde233dfb0f f54c32f13478 000000000000
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  4 files, 9 changesets, 7 total revisions
+  $ cd ..
+  $ for i in 0 1 2 3 4 5 6 7 8; do
+  >    mkdir test-"$i"
+  >    hg --cwd test-"$i" init
+  >    hg -R test bundle -r "$i" test-"$i".hg test-"$i"
+  >    cd test-"$i"
+  >    hg unbundle ../test-"$i".hg
+  >    hg verify
+  >    hg tip -q
+  >    cd ..
+  > done
+  searching for changes
+  1 changesets found
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  (run 'hg update' to get a working copy)
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  1 files, 1 changesets, 1 total revisions
+  0:5649c9d34dd8
+  searching for changes
+  2 changesets found
+  adding changesets
+  adding manifests
+  adding file changes
+  added 2 changesets with 2 changes to 1 files
+  (run 'hg update' to get a working copy)
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  1 files, 2 changesets, 2 total revisions
+  1:10b2180f755b
+  searching for changes
+  3 changesets found
+  adding changesets
+  adding manifests
+  adding file changes
+  added 3 changesets with 3 changes to 1 files
+  (run 'hg update' to get a working copy)
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  1 files, 3 changesets, 3 total revisions
+  2:d62976ca1e50
+  searching for changes
+  4 changesets found
+  adding changesets
+  adding manifests
+  adding file changes
+  added 4 changesets with 4 changes to 1 files
+  (run 'hg update' to get a working copy)
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  1 files, 4 changesets, 4 total revisions
+  3:ac69c658229d
+  searching for changes
+  2 changesets found
+  adding changesets
+  adding manifests
+  adding file changes
+  added 2 changesets with 2 changes to 1 files
+  (run 'hg update' to get a working copy)
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  1 files, 2 changesets, 2 total revisions
+  1:5f4f3ceb285e
+  searching for changes
+  3 changesets found
+  adding changesets
+  adding manifests
+  adding file changes
+  added 3 changesets with 3 changes to 1 files
+  (run 'hg update' to get a working copy)
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  1 files, 3 changesets, 3 total revisions
+  2:024e4e7df376
+  searching for changes
+  4 changesets found
+  adding changesets
+  adding manifests
+  adding file changes
+  added 4 changesets with 5 changes to 2 files
+  (run 'hg update' to get a working copy)
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  2 files, 4 changesets, 5 total revisions
+  3:1e3f6b843bd6
+  searching for changes
+  5 changesets found
+  adding changesets
+  adding manifests
+  adding file changes
+  added 5 changesets with 6 changes to 3 files
+  (run 'hg update' to get a working copy)
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  3 files, 5 changesets, 6 total revisions
+  4:27f57c869697
+  searching for changes
+  5 changesets found
+  adding changesets
+  adding manifests
+  adding file changes
+  added 5 changesets with 5 changes to 2 files
+  (run 'hg update' to get a working copy)
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  2 files, 5 changesets, 5 total revisions
+  4:088ff9d6e1e1
+  $ cd test-8
+  $ hg pull ../test-7
+  pulling from ../test-7
+  searching for changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 4 changesets with 2 changes to 3 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  4 files, 9 changesets, 7 total revisions
+  $ hg rollback
+  rolling back to revision 4 (undo pull)
+  $ cd ..
+
+should fail
+
+  $ hg -R test bundle --base 2 -r tip test-bundle-branch1.hg test-3
+  abort: --base is incompatible with specifying a destination
+  $ hg -R test bundle -r tip test-bundle-branch1.hg
+  abort: repository default-push not found!
+
+  $ hg -R test bundle --base 2 -r tip test-bundle-branch1.hg
+  2 changesets found
+  $ hg -R test bundle --base 2 -r 7 test-bundle-branch2.hg
+  4 changesets found
+  $ hg -R test bundle --base 2 test-bundle-all.hg
+  6 changesets found
+  $ hg -R test bundle --base 3 -r tip test-bundle-should-fail.hg
+  1 changesets found
+
+empty bundle
+
+  $ hg -R test bundle --base 7 --base 8 test-bundle-empty.hg
+  no changes found
+
+issue76 msg2163
+
+  $ hg -R test bundle --base 3 -r 3 -r 3 test-bundle-cset-3.hg
+  1 changesets found
+
+issue1910
+
+  $ hg -R test bundle --base 7 test-bundle-cset-7.hg
+  4 changesets found
+
+  $ hg clone test-2 test-9
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd test-9
+
+revision 2
+
+  $ hg tip -q
+  2:d62976ca1e50
+  $ hg unbundle ../test-bundle-should-fail.hg
+  adding changesets
+  transaction abort!
+  rollback completed
+  abort: 00changelog.i@ac69c658229d: unknown parent!
+
+revision 2
+
+  $ hg tip -q
+  2:d62976ca1e50
+  $ hg unbundle ../test-bundle-all.hg
+  adding changesets
+  adding manifests
+  adding file changes
+  added 6 changesets with 4 changes to 4 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+
+revision 8
+
+  $ hg tip -q
+  8:088ff9d6e1e1
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  4 files, 9 changesets, 7 total revisions
+  $ hg rollback
+  rolling back to revision 2 (undo unbundle)
+
+revision 2
+
+  $ hg tip -q
+  2:d62976ca1e50
+  $ hg unbundle ../test-bundle-branch1.hg
+  adding changesets
+  adding manifests
+  adding file changes
+  added 2 changesets with 2 changes to 2 files
+  (run 'hg update' to get a working copy)
+
+revision 4
+
+  $ hg tip -q
+  4:088ff9d6e1e1
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  2 files, 5 changesets, 5 total revisions
+  $ hg rollback
+  rolling back to revision 2 (undo unbundle)
+  $ hg unbundle ../test-bundle-branch2.hg
+  adding changesets
+  adding manifests
+  adding file changes
+  added 4 changesets with 3 changes to 3 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+
+revision 6
+
+  $ hg tip -q
+  6:27f57c869697
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  3 files, 7 changesets, 6 total revisions
+  $ hg rollback
+  rolling back to revision 2 (undo unbundle)
+  $ hg unbundle ../test-bundle-cset-7.hg
+  adding changesets
+  adding manifests
+  adding file changes
+  added 2 changesets with 2 changes to 2 files
+  (run 'hg update' to get a working copy)
+
+revision 4
+
+  $ hg tip -q
+  4:088ff9d6e1e1
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  2 files, 5 changesets, 5 total revisions
+
+  $ cd ../test
+  $ hg merge 7
+  warning: detected divergent renames of afile to:
+   anotherfile
+   adifferentfile
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg ci -m merge -d "1000000 0"
+  $ cd ..
+  $ hg -R test bundle --base 2 test-bundle-head.hg
+  7 changesets found
+  $ hg clone test-2 test-10
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd test-10
+  $ hg unbundle ../test-bundle-head.hg
+  adding changesets
+  adding manifests
+  adding file changes
+  added 7 changesets with 4 changes to 4 files
+  (run 'hg update' to get a working copy)
+
+revision 9
+
+  $ hg tip -q
+  9:e3061ea42e4c
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  4 files, 10 changesets, 7 total revisions
--- a/tests/test-bundle-type	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,41 +0,0 @@
-#!/bin/sh
-
-echo % bundle w/o type option
-hg init t1
-hg init t2
-cd t1
-echo blablablablabla > file.txt
-hg ci -Ama
-hg log | grep summary
-hg bundle ../b1 ../t2
-
-cd ../t2
-hg pull ../b1
-hg up
-hg log | grep summary
-cd ..
-
-for t in "None" "bzip2" "gzip"; do
-  echo % test bundle type $t
-  hg init t$t
-  cd t1
-  hg bundle -t $t ../b$t ../t$t
-  cut -b 1-6 ../b$t | head -n 1
-  cd ../t$t
-  hg pull ../b$t
-  hg up
-  hg log | grep summary
-  cd ..
-done
-
-echo % test garbage file
-echo garbage > bgarbage
-hg init tgarbage
-cd tgarbage
-hg pull ../bgarbage
-cd ..
-
-echo % test invalid bundle type
-cd t1
-hg bundle -a -t garbage ../bgarbage
-cd ..
--- a/tests/test-bundle-type.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,58 +0,0 @@
-% bundle w/o type option
-adding file.txt
-summary:     a
-searching for changes
-1 changesets found
-pulling from ../b1
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-(run 'hg update' to get a working copy)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-summary:     a
-% test bundle type None
-searching for changes
-1 changesets found
-HG10UN
-pulling from ../bNone
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-(run 'hg update' to get a working copy)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-summary:     a
-% test bundle type bzip2
-searching for changes
-1 changesets found
-HG10BZ
-pulling from ../bbzip2
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-(run 'hg update' to get a working copy)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-summary:     a
-% test bundle type gzip
-searching for changes
-1 changesets found
-HG10GZ
-pulling from ../bgzip
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-(run 'hg update' to get a working copy)
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-summary:     a
-% test garbage file
-abort: ../bgarbage: not a Mercurial bundle file
-% test invalid bundle type
-1 changesets found
-abort: unknown bundle type specified with --type
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bundle-type.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,99 @@
+bundle w/o type option
+
+  $ hg init t1
+  $ hg init t2
+  $ cd t1
+  $ echo blablablablabla > file.txt
+  $ hg ci -Ama
+  adding file.txt
+  $ hg log | grep summary
+  summary:     a
+  $ hg bundle ../b1 ../t2
+  searching for changes
+  1 changesets found
+
+  $ cd ../t2
+  $ hg pull ../b1
+  pulling from ../b1
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  (run 'hg update' to get a working copy)
+  $ hg up
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg log | grep summary
+  summary:     a
+  $ cd ..
+
+test bundle types
+
+  $ for t in "None" "bzip2" "gzip"; do
+  >   echo % test bundle type $t
+  >   hg init t$t
+  >   cd t1
+  >   hg bundle -t $t ../b$t ../t$t
+  >   cut -b 1-6 ../b$t | head -n 1
+  >   cd ../t$t
+  >   hg pull ../b$t
+  >   hg up
+  >   hg log | grep summary
+  >   cd ..
+  > done
+  % test bundle type None
+  searching for changes
+  1 changesets found
+  HG10UN
+  pulling from ../bNone
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  (run 'hg update' to get a working copy)
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  summary:     a
+  % test bundle type bzip2
+  searching for changes
+  1 changesets found
+  HG10BZ
+  pulling from ../bbzip2
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  (run 'hg update' to get a working copy)
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  summary:     a
+  % test bundle type gzip
+  searching for changes
+  1 changesets found
+  HG10GZ
+  pulling from ../bgzip
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  (run 'hg update' to get a working copy)
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  summary:     a
+
+test garbage file
+
+  $ echo garbage > bgarbage
+  $ hg init tgarbage
+  $ cd tgarbage
+  $ hg pull ../bgarbage
+  abort: ../bgarbage: not a Mercurial bundle file
+  $ cd ..
+
+test invalid bundle type
+
+  $ cd t1
+  $ hg bundle -a -t garbage ../bgarbage
+  1 changesets found
+  abort: unknown bundle type specified with --type
+  $ cd ..
--- a/tests/test-bundle-vs-outgoing	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,84 +0,0 @@
-#!/bin/sh
-
-# this structure seems to tickle a bug in bundle's search for
-# changesets, so first we have to recreate it
-#
-# o  8
-# |
-# | o  7
-# | |
-# | o  6
-# |/|
-# o |  5
-# | |
-# o |  4
-# | |
-# | o  3
-# | |
-# | o  2
-# |/
-# o  1
-# |
-# o  0
-
-mkrev()
-{
-    revno=$1
-    echo "rev $revno"
-    echo "rev $revno" > foo.txt
-    hg -q ci -m"rev $revno"
-}
-
-set -e
-echo "% setup test repo1"
-hg init repo1
-cd repo1
-echo "rev 0" > foo.txt
-hg ci -Am"rev 0"
-mkrev 1
-
-# first branch
-mkrev 2
-mkrev 3
-
-# back to rev 1 to create second branch
-hg up -r1
-mkrev 4
-mkrev 5
-
-# merge first branch to second branch
-hg up -C -r5
-HGMERGE=internal:local hg merge
-echo "merge rev 5, rev 3" > foo.txt
-hg ci -m"merge first branch to second branch"
-
-# one more commit following the merge
-mkrev 7
-
-# back to "second branch" to make another head
-hg up -r5
-mkrev 8
-
-echo "[extensions]" >> $HGRCPATH
-echo "graphlog=" >> $HGRCPATH
-
-echo "% the story so far"
-hg glog --template "{rev}\n"
-
-# check that "hg outgoing" really does the right thing
-echo "% sanity check of outgoing: expect revs 4 5 6 7 8"
-hg clone -r3 . ../repo2
-# this should (and does) report 5 outgoing revisions: 4 5 6 7 8
-hg outgoing --template "{rev}\n" ../repo2
-
-echo "% test bundle (destination repo): expect 5 revisions"
-# this should bundle the same 5 revisions that outgoing reported, but it
-# actually bundles 7
-hg bundle foo.bundle ../repo2
-
-echo "% test bundle (base revision): expect 5 revisions"
-# this should (and does) give exactly the same result as bundle
-# with a destination repo... i.e. it's wrong too
-hg bundle --base 3 foo.bundle
-
-
--- a/tests/test-bundle-vs-outgoing.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,53 +0,0 @@
-% setup test repo1
-adding foo.txt
-rev 1
-rev 2
-rev 3
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-rev 4
-rev 5
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-0 files updated, 1 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-rev 7
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-rev 8
-% the story so far
-@  8
-|
-| o  7
-| |
-| o  6
-|/|
-o |  5
-| |
-o |  4
-| |
-| o  3
-| |
-| o  2
-|/
-o  1
-|
-o  0
-
-% sanity check of outgoing: expect revs 4 5 6 7 8
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 4 changesets with 4 changes to 1 files
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-comparing with ../repo2
-searching for changes
-4
-5
-6
-7
-8
-% test bundle (destination repo): expect 5 revisions
-searching for changes
-5 changesets found
-% test bundle (base revision): expect 5 revisions
-5 changesets found
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bundle-vs-outgoing.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,147 @@
+this structure seems to tickle a bug in bundle's search for
+changesets, so first we have to recreate it
+
+o  8
+|
+| o  7
+| |
+| o  6
+|/|
+o |  5
+| |
+o |  4
+| |
+| o  3
+| |
+| o  2
+|/
+o  1
+|
+o  0
+
+  $ mkrev()
+  > {
+  >     revno=$1
+  >     echo "rev $revno"
+  >     echo "rev $revno" > foo.txt
+  >     hg -q ci -m"rev $revno"
+  > }
+
+  $ set -e
+
+setup test repo1
+
+  $ hg init repo1
+  $ cd repo1
+  $ echo "rev 0" > foo.txt
+  $ hg ci -Am"rev 0"
+  adding foo.txt
+  $ mkrev 1
+  rev 1
+
+first branch
+
+  $ mkrev 2
+  rev 2
+  $ mkrev 3
+  rev 3
+
+back to rev 1 to create second branch
+
+  $ hg up -r1
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ mkrev 4
+  rev 4
+  $ mkrev 5
+  rev 5
+
+merge first branch to second branch
+
+  $ hg up -C -r5
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ HGMERGE=internal:local hg merge
+  0 files updated, 1 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ echo "merge rev 5, rev 3" > foo.txt
+  $ hg ci -m"merge first branch to second branch"
+
+one more commit following the merge
+
+  $ mkrev 7
+  rev 7
+
+back to "second branch" to make another head
+
+  $ hg up -r5
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ mkrev 8
+  rev 8
+
+  $ echo "[extensions]" >> $HGRCPATH
+  $ echo "graphlog=" >> $HGRCPATH
+
+the story so far
+
+  $ hg glog --template "{rev}\n"
+  @  8
+  |
+  | o  7
+  | |
+  | o  6
+  |/|
+  o |  5
+  | |
+  o |  4
+  | |
+  | o  3
+  | |
+  | o  2
+  |/
+  o  1
+  |
+  o  0
+  
+
+check that "hg outgoing" really does the right thing
+
+sanity check of outgoing: expect revs 4 5 6 7 8
+
+  $ hg clone -r3 . ../repo2
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 4 changesets with 4 changes to 1 files
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+this should (and does) report 5 outgoing revisions: 4 5 6 7 8
+
+  $ hg outgoing --template "{rev}\n" ../repo2
+  comparing with ../repo2
+  searching for changes
+  4
+  5
+  6
+  7
+  8
+
+test bundle (destination repo): expect 5 revisions
+
+this should bundle the same 5 revisions that outgoing reported, but it
+
+actually bundles 7
+
+  $ hg bundle foo.bundle ../repo2
+  searching for changes
+  5 changesets found
+
+test bundle (base revision): expect 5 revisions
+
+this should (and does) give exactly the same result as bundle
+
+with a destination repo... i.e. it's wrong too
+
+  $ hg bundle --base 3 foo.bundle
+  5 changesets found
+
--- a/tests/test-bundle.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,365 +0,0 @@
-====== Setting up test
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-1 files updated, 0 files merged, 2 files removed, 0 files unresolved
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-4 files, 9 changesets, 7 total revisions
-====== Bundle --all
-9 changesets found
-====== Bundle test to full.hg
-searching for changes
-9 changesets found
-====== Unbundle full.hg in test
-adding changesets
-adding manifests
-adding file changes
-added 0 changesets with 0 changes to 4 files
-(run 'hg update' to get a working copy)
-====== Verify empty
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-0 files, 0 changesets, 0 total revisions
-====== Pull full.hg into test (using --cwd)
-pulling from ../full.hg
-searching for changes
-no changes found
-====== Pull full.hg into empty (using --cwd)
-pulling from ../full.hg
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 9 changesets with 7 changes to 4 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-====== Rollback empty
-rolling back to revision -1 (undo pull)
-====== Pull full.hg into empty again (using --cwd)
-pulling from ../full.hg
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 9 changesets with 7 changes to 4 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-====== Pull full.hg into test (using -R)
-pulling from full.hg
-searching for changes
-no changes found
-====== Pull full.hg into empty (using -R)
-pulling from full.hg
-searching for changes
-no changes found
-====== Rollback empty
-rolling back to revision -1 (undo pull)
-====== Pull full.hg into empty again (using -R)
-pulling from full.hg
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 9 changesets with 7 changes to 4 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-====== Log -R full.hg in fresh empty
-changeset:   8:088ff9d6e1e1
-tag:         tip
-parent:      3:ac69c658229d
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.3m
-
-changeset:   7:27f57c869697
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.3m
-
-changeset:   6:1e3f6b843bd6
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.3
-
-changeset:   5:024e4e7df376
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.2
-
-changeset:   4:5f4f3ceb285e
-parent:      0:5649c9d34dd8
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.1
-
-changeset:   3:ac69c658229d
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.3
-
-changeset:   2:d62976ca1e50
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.2
-
-changeset:   1:10b2180f755b
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.1
-
-changeset:   0:5649c9d34dd8
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.0
-
-====== Pull ../full.hg into empty (with hook)
-changegroup hook: HG_NODE=5649c9d34dd87d0ecb5fd39672128376e83b22e1 HG_SOURCE=pull HG_URL=bundle:../full.hg 
-pulling from bundle://../full.hg
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 9 changesets with 7 changes to 4 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-====== Rollback empty
-rolling back to revision -1 (undo pull)
-====== Log -R bundle:empty+full.hg
-8 7 6 5 4 3 2 1 0 
-====== Pull full.hg into empty again (using -R; with hook)
-changegroup hook: HG_NODE=5649c9d34dd87d0ecb5fd39672128376e83b22e1 HG_SOURCE=pull HG_URL=bundle:empty+full.hg 
-pulling from full.hg
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 9 changesets with 7 changes to 4 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-====== Create partial clones
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 4 changesets with 4 changes to 1 files
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-====== Log -R full.hg in partial
-changeset:   8:088ff9d6e1e1
-tag:         tip
-parent:      3:ac69c658229d
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.3m
-
-changeset:   7:27f57c869697
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.3m
-
-changeset:   6:1e3f6b843bd6
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.3
-
-changeset:   5:024e4e7df376
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.2
-
-changeset:   4:5f4f3ceb285e
-parent:      0:5649c9d34dd8
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.1
-
-changeset:   3:ac69c658229d
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.3
-
-changeset:   2:d62976ca1e50
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.2
-
-changeset:   1:10b2180f755b
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.1
-
-changeset:   0:5649c9d34dd8
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.0
-
-====== Incoming full.hg in partial
-comparing with bundle://../full.hg
-searching for changes
-changeset:   4:5f4f3ceb285e
-parent:      0:5649c9d34dd8
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.1
-
-changeset:   5:024e4e7df376
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.2
-
-changeset:   6:1e3f6b843bd6
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.3
-
-changeset:   7:27f57c869697
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.3m
-
-changeset:   8:088ff9d6e1e1
-tag:         tip
-parent:      3:ac69c658229d
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.3m
-
-====== Outgoing -R full.hg vs partial2 in partial
-comparing with ../partial2
-searching for changes
-changeset:   4:5f4f3ceb285e
-parent:      0:5649c9d34dd8
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.1
-
-changeset:   5:024e4e7df376
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.2
-
-changeset:   6:1e3f6b843bd6
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.3
-
-changeset:   7:27f57c869697
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.3m
-
-changeset:   8:088ff9d6e1e1
-tag:         tip
-parent:      3:ac69c658229d
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.3m
-
-====== Outgoing -R does-not-exist.hg vs partial2 in partial
-abort: No such file or directory: ../does-not-exist.hg
-====== Direct clone from bundle (all-history)
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 9 changesets with 7 changes to 4 files (+1 heads)
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-changeset:   8:088ff9d6e1e1
-tag:         tip
-parent:      3:ac69c658229d
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     0.3m
-
-changeset:   7:27f57c869697
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1.3m
-
-====== Unbundle incremental bundles into fresh empty in one go
-1 changesets found
-1 changesets found
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-====== test for 540d1059c802
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-searching for changes
-1 changesets found
-comparing with ../bundle.hg
-searching for changes
-changeset:   2:ed1b79f46b9a
-tag:         tip
-parent:      0:bbd179dfa0a7
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     change foo
-
-===== test that verify bundle does not traceback
-abort: 00changelog.i@bbd179dfa0a7: unknown parent!
-abort: cannot verify bundle or remote repos
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-2 files, 2 changesets, 2 total revisions
-====== diff against bundle
-diff -r 088ff9d6e1e1 anotherfile
---- a/anotherfile	Mon Jan 12 13:46:40 1970 +0000
-+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
-@@ -1,4 +0,0 @@
--0
--1
--2
--3
-====== bundle single branch
-adding a
-adding b
-adding b1
-0 files updated, 0 files merged, 2 files removed, 0 files unresolved
-adding c
-created new head
-adding c1
-== bundling via incoming
-comparing with .
-searching for changes
-d2ae7f538514cd87c17547b0de4cea71fe1af9fb
-5ece8e77363e2b5269e27c66828b72da29e4341a
-== bundling
-searching for changes
-common changesets up to c0025332f9ed
-2 changesets found
-list of changesets:
-d2ae7f538514cd87c17547b0de4cea71fe1af9fb
-5ece8e77363e2b5269e27c66828b72da29e4341a
-bundling changes: 0 chunks
-bundling changes: 1 chunks
-bundling changes: 2 chunks
-bundling changes: 3 chunks
-bundling changes: 4 chunks
-bundling changes: 5 chunks
-bundling changes: 6 chunks
-bundling manifests: 0 chunks
-bundling manifests: 1 chunks
-bundling manifests: 2 chunks
-bundling manifests: 3 chunks
-bundling manifests: 4 chunks
-bundling manifests: 5 chunks
-bundling manifests: 6 chunks
-bundling files: b 0 chunks
-bundling files: b 1 chunks
-bundling files: b 2 chunks
-bundling files: b 3 chunks
-bundling files: b1 4 chunks
-bundling files: b1 5 chunks
-bundling files: b1 6 chunks
-bundling files: b1 7 chunks
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-bundle.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,558 @@
+  $ cp "$TESTDIR"/printenv.py .
+
+Setting up test
+
+  $ hg init test
+  $ cd test
+  $ echo 0 > afile
+  $ hg add afile
+  $ hg commit -m "0.0" -d "1000000 0"
+  $ echo 1 >> afile
+  $ hg commit -m "0.1" -d "1000000 0"
+  $ echo 2 >> afile
+  $ hg commit -m "0.2" -d "1000000 0"
+  $ echo 3 >> afile
+  $ hg commit -m "0.3" -d "1000000 0"
+  $ hg update -C 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo 1 >> afile
+  $ hg commit -m "1.1" -d "1000000 0"
+  created new head
+  $ echo 2 >> afile
+  $ hg commit -m "1.2" -d "1000000 0"
+  $ echo "a line" > fred
+  $ echo 3 >> afile
+  $ hg add fred
+  $ hg commit -m "1.3" -d "1000000 0"
+  $ hg mv afile adifferentfile
+  $ hg commit -m "1.3m" -d "1000000 0"
+  $ hg update -C 3
+  1 files updated, 0 files merged, 2 files removed, 0 files unresolved
+  $ hg mv afile anotherfile
+  $ hg commit -m "0.3m" -d "1000000 0"
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  4 files, 9 changesets, 7 total revisions
+  $ cd ..
+  $ hg init empty
+
+Bundle --all
+
+  $ hg -R test bundle --all all.hg
+  9 changesets found
+
+Bundle test to full.hg
+
+  $ hg -R test bundle full.hg empty
+  searching for changes
+  9 changesets found
+
+Unbundle full.hg in test
+
+  $ hg -R test unbundle full.hg
+  adding changesets
+  adding manifests
+  adding file changes
+  added 0 changesets with 0 changes to 4 files
+  (run 'hg update' to get a working copy)
+
+Verify empty
+
+  $ hg -R empty heads
+  $ hg -R empty verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  0 files, 0 changesets, 0 total revisions
+
+Pull full.hg into test (using --cwd)
+
+  $ hg --cwd test pull ../full.hg
+  pulling from ../full.hg
+  searching for changes
+  no changes found
+
+Pull full.hg into empty (using --cwd)
+
+  $ hg --cwd empty pull ../full.hg
+  pulling from ../full.hg
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 9 changesets with 7 changes to 4 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+
+Rollback empty
+
+  $ hg -R empty rollback
+  rolling back to revision -1 (undo pull)
+
+Pull full.hg into empty again (using --cwd)
+
+  $ hg --cwd empty pull ../full.hg
+  pulling from ../full.hg
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 9 changesets with 7 changes to 4 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+
+Pull full.hg into test (using -R)
+
+  $ hg -R test pull full.hg
+  pulling from full.hg
+  searching for changes
+  no changes found
+
+Pull full.hg into empty (using -R)
+
+  $ hg -R empty pull full.hg
+  pulling from full.hg
+  searching for changes
+  no changes found
+
+Rollback empty
+
+  $ hg -R empty rollback
+  rolling back to revision -1 (undo pull)
+
+Pull full.hg into empty again (using -R)
+
+  $ hg -R empty pull full.hg
+  pulling from full.hg
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 9 changesets with 7 changes to 4 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+
+Log -R full.hg in fresh empty
+
+  $ rm -r empty
+  $ hg init empty
+  $ cd empty
+  $ hg -R bundle://../full.hg log
+  changeset:   8:088ff9d6e1e1
+  tag:         tip
+  parent:      3:ac69c658229d
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.3m
+  
+  changeset:   7:27f57c869697
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.3m
+  
+  changeset:   6:1e3f6b843bd6
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.3
+  
+  changeset:   5:024e4e7df376
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.2
+  
+  changeset:   4:5f4f3ceb285e
+  parent:      0:5649c9d34dd8
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.1
+  
+  changeset:   3:ac69c658229d
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.3
+  
+  changeset:   2:d62976ca1e50
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.2
+  
+  changeset:   1:10b2180f755b
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.1
+  
+  changeset:   0:5649c9d34dd8
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.0
+  
+
+Pull ../full.hg into empty (with hook)
+
+  $ echo '[hooks]' >> .hg/hgrc
+  $ echo 'changegroup = python ../printenv.py changegroup' >> .hg/hgrc
+
+doesn't work (yet ?)
+
+hg -R bundle://../full.hg verify
+
+  $ hg pull bundle://../full.hg
+  changegroup hook: HG_NODE=5649c9d34dd87d0ecb5fd39672128376e83b22e1 HG_SOURCE=pull HG_URL=bundle:../full.hg 
+  pulling from bundle://../full.hg
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 9 changesets with 7 changes to 4 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+
+Rollback empty
+
+  $ hg rollback
+  rolling back to revision -1 (undo pull)
+  $ cd ..
+
+Log -R bundle:empty+full.hg
+
+  $ hg -R bundle:empty+full.hg log --template="{rev} "; echo ""
+  8 7 6 5 4 3 2 1 0 
+
+Pull full.hg into empty again (using -R; with hook)
+
+  $ hg -R empty pull full.hg
+  changegroup hook: HG_NODE=5649c9d34dd87d0ecb5fd39672128376e83b22e1 HG_SOURCE=pull HG_URL=bundle:empty+full.hg 
+  pulling from full.hg
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 9 changesets with 7 changes to 4 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+
+Create partial clones
+
+  $ rm -r empty
+  $ hg init empty
+  $ hg clone -r 3 test partial
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 4 changesets with 4 changes to 1 files
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg clone partial partial2
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd partial
+
+Log -R full.hg in partial
+
+  $ hg -R bundle://../full.hg log
+  changeset:   8:088ff9d6e1e1
+  tag:         tip
+  parent:      3:ac69c658229d
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.3m
+  
+  changeset:   7:27f57c869697
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.3m
+  
+  changeset:   6:1e3f6b843bd6
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.3
+  
+  changeset:   5:024e4e7df376
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.2
+  
+  changeset:   4:5f4f3ceb285e
+  parent:      0:5649c9d34dd8
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.1
+  
+  changeset:   3:ac69c658229d
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.3
+  
+  changeset:   2:d62976ca1e50
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.2
+  
+  changeset:   1:10b2180f755b
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.1
+  
+  changeset:   0:5649c9d34dd8
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.0
+  
+
+Incoming full.hg in partial
+
+  $ hg incoming bundle://../full.hg
+  comparing with bundle://../full.hg
+  searching for changes
+  changeset:   4:5f4f3ceb285e
+  parent:      0:5649c9d34dd8
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.1
+  
+  changeset:   5:024e4e7df376
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.2
+  
+  changeset:   6:1e3f6b843bd6
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.3
+  
+  changeset:   7:27f57c869697
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.3m
+  
+  changeset:   8:088ff9d6e1e1
+  tag:         tip
+  parent:      3:ac69c658229d
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.3m
+  
+
+Outgoing -R full.hg vs partial2 in partial
+
+  $ hg -R bundle://../full.hg outgoing ../partial2
+  comparing with ../partial2
+  searching for changes
+  changeset:   4:5f4f3ceb285e
+  parent:      0:5649c9d34dd8
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.1
+  
+  changeset:   5:024e4e7df376
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.2
+  
+  changeset:   6:1e3f6b843bd6
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.3
+  
+  changeset:   7:27f57c869697
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.3m
+  
+  changeset:   8:088ff9d6e1e1
+  tag:         tip
+  parent:      3:ac69c658229d
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.3m
+  
+
+Outgoing -R does-not-exist.hg vs partial2 in partial
+
+  $ hg -R bundle://../does-not-exist.hg outgoing ../partial2
+  abort: No such file or directory: ../does-not-exist.hg
+  $ cd ..
+
+Direct clone from bundle (all-history)
+
+  $ hg clone full.hg full-clone
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 9 changesets with 7 changes to 4 files (+1 heads)
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg -R full-clone heads
+  changeset:   8:088ff9d6e1e1
+  tag:         tip
+  parent:      3:ac69c658229d
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     0.3m
+  
+  changeset:   7:27f57c869697
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1.3m
+  
+  $ rm -r full-clone
+
+test for http://mercurial.selenic.com/bts/issue216
+
+Unbundle incremental bundles into fresh empty in one go
+
+  $ rm -r empty
+  $ hg init empty
+  $ hg -R test bundle --base null -r 0 ../0.hg
+  1 changesets found
+  $ hg -R test bundle --base 0    -r 1 ../1.hg
+  1 changesets found
+  $ hg -R empty unbundle -u ../0.hg ../1.hg
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+test for 540d1059c802
+
+test for 540d1059c802
+
+  $ hg init orig
+  $ cd orig
+  $ echo foo > foo
+  $ hg add foo
+  $ hg ci -m 'add foo'
+
+  $ hg clone . ../copy
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg tag foo
+
+  $ cd ../copy
+  $ echo >> foo
+  $ hg ci -m 'change foo'
+  $ hg bundle ../bundle.hg ../orig
+  searching for changes
+  1 changesets found
+
+  $ cd ../orig
+  $ hg incoming ../bundle.hg
+  comparing with ../bundle.hg
+  searching for changes
+  changeset:   2:ed1b79f46b9a
+  tag:         tip
+  parent:      0:bbd179dfa0a7
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     change foo
+  
+  $ cd ..
+
+test for http://mercurial.selenic.com/bts/issue1144
+
+test that verify bundle does not traceback
+
+partial history bundle, fails w/ unkown parent
+
+  $ hg -R bundle.hg verify
+  abort: 00changelog.i@bbd179dfa0a7: unknown parent!
+
+full history bundle, refuses to verify non-local repo
+
+  $ hg -R all.hg verify
+  abort: cannot verify bundle or remote repos
+
+but, regular verify must continue to work
+
+  $ hg -R orig verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  2 files, 2 changesets, 2 total revisions
+
+diff against bundle
+
+  $ hg init b
+  $ cd b
+  $ hg -R ../all.hg diff -r tip
+  diff -r 088ff9d6e1e1 anotherfile
+  --- a/anotherfile	Mon Jan 12 13:46:40 1970 +0000
+  +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
+  @@ -1,4 +0,0 @@
+  -0
+  -1
+  -2
+  -3
+  $ cd ..
+
+bundle single branch
+
+  $ hg init branchy
+  $ cd branchy
+  $ echo a >a
+  $ hg ci -Ama
+  adding a
+  $ echo b >b
+  $ hg ci -Amb
+  adding b
+  $ echo b1 >b1
+  $ hg ci -Amb1
+  adding b1
+  $ hg up 0
+  0 files updated, 0 files merged, 2 files removed, 0 files unresolved
+  $ echo c >c
+  $ hg ci -Amc
+  adding c
+  created new head
+  $ echo c1 >c1
+  $ hg ci -Amc1
+  adding c1
+  $ hg clone -q .#tip part
+
+== bundling via incoming
+
+  $ hg in -R part --bundle incoming.hg --template "{node}\n" .
+  comparing with .
+  searching for changes
+  d2ae7f538514cd87c17547b0de4cea71fe1af9fb
+  5ece8e77363e2b5269e27c66828b72da29e4341a
+
+== bundling
+
+  $ hg bundle bundle.hg part --debug
+  searching for changes
+  common changesets up to c0025332f9ed
+  2 changesets found
+  list of changesets:
+  d2ae7f538514cd87c17547b0de4cea71fe1af9fb
+  5ece8e77363e2b5269e27c66828b72da29e4341a
+  bundling changes: 0 chunks
+  bundling changes: 1 chunks
+  bundling changes: 2 chunks
+  bundling changes: 3 chunks
+  bundling changes: 4 chunks
+  bundling changes: 5 chunks
+  bundling changes: 6 chunks
+  bundling manifests: 0 chunks
+  bundling manifests: 1 chunks
+  bundling manifests: 2 chunks
+  bundling manifests: 3 chunks
+  bundling manifests: 4 chunks
+  bundling manifests: 5 chunks
+  bundling manifests: 6 chunks
+  bundling files: b 0 chunks
+  bundling files: b 1 chunks
+  bundling files: b 2 chunks
+  bundling files: b 3 chunks
+  bundling files: b1 4 chunks
+  bundling files: b1 5 chunks
+  bundling files: b1 6 chunks
+  bundling files: b1 7 chunks
+
--- a/tests/test-cat	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,18 +0,0 @@
-#!/bin/sh
-#
-mkdir t
-cd t
-hg init
-echo 0 > a
-echo 0 > b
-hg ci -A -m m -d "1000000 0"
-hg rm a
-hg cat a
-hg cat --decode a # more tests in test-encode
-echo 1 > b
-hg ci -m m -d "1000000 0"
-echo 2 > b
-hg cat -r 0 a
-hg cat -r 0 b
-hg cat -r 1 a
-hg cat -r 1 b
--- a/tests/test-cat.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,8 +0,0 @@
-adding a
-adding b
-0
-0
-0
-0
-a: No such file in rev 03f6b0774996
-1
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-cat.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,24 @@
+  $ mkdir t
+  $ cd t
+  $ hg init
+  $ echo 0 > a
+  $ echo 0 > b
+  $ hg ci -A -m m -d "1000000 0"
+  adding a
+  adding b
+  $ hg rm a
+  $ hg cat a
+  0
+  $ hg cat --decode a # more tests in test-encode
+  0
+  $ echo 1 > b
+  $ hg ci -m m -d "1000000 0"
+  $ echo 2 > b
+  $ hg cat -r 0 a
+  0
+  $ hg cat -r 0 b
+  0
+  $ hg cat -r 1 a
+  a: No such file in rev 03f6b0774996
+  $ hg cat -r 1 b
+  1
--- a/tests/test-changelog-exec	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,32 +0,0 @@
-#!/bin/sh
-# b51a8138292a introduced a regression where we would mention in the
-# changelog executable files added by the second parent of a merge.
-# Test that that doesn't happen anymore
-
-"$TESTDIR/hghave" execbit || exit 80
-
-hg init repo
-cd repo
-echo foo > foo
-hg ci -qAm 'add foo'
-
-echo bar > bar
-chmod +x bar
-hg ci -qAm 'add bar'
-echo '% manifest of p2:'
-hg manifest
-echo
-
-hg up -qC 0
-echo >> foo
-hg ci -m 'change foo'
-echo '% manifest of p1:'
-hg manifest
-
-hg merge
-hg ci -m 'merge'
-
-echo '% this should not mention bar:'
-hg tip -v
-
-hg debugindex .hg/store/data/bar.i
--- a/tests/test-changelog-exec.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,22 +0,0 @@
-% manifest of p2:
-bar
-foo
-
-created new head
-% manifest of p1:
-foo
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-% this should not mention bar:
-changeset:   3:ef2fc9b4a51b
-tag:         tip
-parent:      2:ed1b79f46b9a
-parent:      1:d394a8db219b
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-description:
-merge
-
-
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0       5      0       1 b004912a8510 000000000000 000000000000
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-changelog-exec.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,53 @@
+b51a8138292a introduced a regression where we would mention in the
+changelog executable files added by the second parent of a merge. Test
+that that doesn't happen anymore
+
+  $ "$TESTDIR/hghave" execbit || exit 80
+
+  $ hg init repo
+  $ cd repo
+  $ echo foo > foo
+  $ hg ci -qAm 'add foo'
+
+  $ echo bar > bar
+  $ chmod +x bar
+  $ hg ci -qAm 'add bar'
+
+manifest of p2:
+
+  $ hg manifest
+  bar
+  foo
+
+  $ hg up -qC 0
+  $ echo >> foo
+  $ hg ci -m 'change foo'
+  created new head
+
+manifest of p1:
+
+  $ hg manifest
+  foo
+
+  $ hg merge
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg ci -m 'merge'
+
+this should not mention bar:
+
+  $ hg tip -v
+  changeset:   3:ef2fc9b4a51b
+  tag:         tip
+  parent:      2:ed1b79f46b9a
+  parent:      1:d394a8db219b
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  description:
+  merge
+  
+  
+
+  $ hg debugindex .hg/store/data/bar.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0       5      0       1 b004912a8510 000000000000 000000000000
--- a/tests/test-check-code	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-check-code	Sat Aug 14 03:30:35 2010 +0200
@@ -35,3 +35,5 @@
 
 check_code=`dirname $0`/../contrib/check-code.py
 ${check_code} ./wrong.py ./correct.py ./quote.py ./non-py24.py
+
+exit 0
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-check-code-hg.py	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,24 @@
+# Pass all working directory files through check-code.py
+
+import sys, os, imp
+rootdir = os.path.abspath(os.path.join(os.path.dirname(sys.argv[0]), '..'))
+if not os.path.isdir(os.path.join(rootdir, '.hg')):
+    sys.stderr.write('skipped: cannot check code on non-repository sources\n')
+    sys.exit(80)
+
+checkpath = os.path.join(rootdir, 'contrib/check-code.py')
+checkcode = imp.load_source('checkcode', checkpath)
+
+from mercurial import hg, ui
+u = ui.ui()
+repo = hg.repository(u, rootdir)
+checked = 0
+wctx = repo[None]
+for f in wctx:
+    # ignore removed and unknown files
+    if f not in wctx:
+        continue
+    checked += 1
+    checkcode.checkfile(os.path.join(rootdir, f))
+if not checked:
+    sys.stderr.write('no file checked!\n')
--- a/tests/test-clone	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,222 +0,0 @@
-#!/bin/sh
-
-echo
-echo % prepare repo a
-mkdir a
-cd a
-hg init
-echo a > a
-hg add a
-hg commit -m test
-echo first line > b
-hg add b
-# create a non-inlined filelog
-python -c 'for x in range(10000): print x' >> data1
-for j in 0 1 2 3 4 5 6 7 8 9; do
-    cat data1 >> b
-    hg commit -m test
-done
-echo % "list files in store/data (should show a 'b.d')"
-for i in .hg/store/data/*; do
-    echo $i
-done
-
-echo
-echo % default operation
-hg clone . ../b
-cd ../b
-cat a
-hg verify
-
-echo
-echo % no update, with debug option
-hg --debug clone -U . ../c
-cd ../c
-cat a 2>/dev/null || echo "a not present"
-hg verify
-
-echo
-echo % default destination
-mkdir ../d
-cd ../d
-hg clone ../a
-cd a
-hg cat a
-
-echo
-echo % "check that we drop the file: from the path before"
-echo % "writing the .hgrc"
-cd ../..
-hg clone file:a e
-grep 'file:' e/.hg/hgrc
-
-echo
-echo % check that path aliases are expanded
-hg clone -q -U --config 'paths.foobar=a#0' foobar f
-hg -R f showconfig paths.default | sed -e 's,.*/,,'
-
-echo
-echo % use --pull
-hg clone --pull a g
-hg -R g verify
-
-echo
-echo % clone to '.'
-mkdir h
-cd h
-hg clone ../a .
-cd ..
-
-echo
-echo
-echo % "*** tests for option -u ***"
-echo
-
-
-echo
-echo % "adding some more history to repo a"
-cd a
-echo % "tag ref1"
-hg tag ref1
-echo the quick brown fox >a
-hg ci -m "hacked default"
-echo % "updating back to ref1"
-hg up ref1
-echo
-echo % "add branch 'stable' to repo a for later tests"
-hg branch stable
-echo some text >a
-hg ci -m "starting branch stable"
-echo % "tag ref2"
-hg tag ref2
-echo some more text >a
-hg ci -m "another change for branch stable"
-echo
-echo % "updating back to ref2"
-hg up ref2
-echo
-echo % "parents of repo a"
-hg parents
-echo
-echo % "repo a has two heads"
-hg heads
-cd ..
-
-echo
-echo % "testing clone -U -u 1 a ua (must abort)"
-hg clone -U -u 1 a ua
-
-echo
-echo % "testing clone -u . a ua"
-hg clone -u . a ua
-echo
-echo % "repo ua has both heads"
-hg -R ua heads
-echo
-echo % "same revision checked out in repo a and ua"
-hg -R a parents --template "{node|short}\n"
-hg -R ua parents --template "{node|short}\n"
-rm -r ua
-
-echo
-echo % "testing clone --pull -u . a ua"
-hg clone --pull -u . a ua
-echo
-echo % "repo ua has both heads"
-hg -R ua heads
-echo
-echo % "same revision checked out in repo a and ua"
-hg -R a parents --template "{node|short}\n"
-hg -R ua parents --template "{node|short}\n"
-rm -r ua
-
-echo
-echo % "testing clone -u stable a ua"
-hg clone -u stable a ua
-echo
-echo % "repo ua has both heads"
-hg -R ua heads
-echo
-echo % "branch stable is checked out"
-hg -R ua parents
-rm -r ua
-
-echo
-echo % "testing clone a ua"
-hg clone a ua
-echo
-echo % "repo ua has both heads"
-hg -R ua heads
-echo
-echo % "branch default is checked out"
-hg -R ua parents
-rm -r ua
-
-echo
-echo % "testing clone -u . a#stable ua"
-hg clone -u . a#stable ua
-echo
-echo % "repo ua has only branch stable"
-hg -R ua heads
-echo
-echo % "same revision checked out in repo a and ua"
-hg -R a parents --template "{node|short}\n"
-hg -R ua parents --template "{node|short}\n"
-rm -r ua
-
-echo
-echo % "testing clone -u . -r stable a ua"
-hg clone -u . -r stable a ua
-echo
-echo % "repo ua has only branch stable"
-hg -R ua heads
-echo
-echo % "same revision checked out in repo a and ua"
-hg -R a parents --template "{node|short}\n"
-hg -R ua parents --template "{node|short}\n"
-rm -r ua
-
-echo
-echo % "testing clone -r stable a ua"
-hg clone -r stable a ua
-echo
-echo % "repo ua has only branch stable"
-hg -R ua heads
-echo
-echo % "branch stable is checked out"
-hg -R ua parents
-rm -r ua
-
-echo
-echo % "testing clone -u . -r stable -r default a ua"
-hg clone -u . -r stable -r default a ua
-echo
-echo % "repo ua has two heads"
-hg -R ua heads
-echo
-echo % "same revision checked out in repo a and ua"
-hg -R a parents --template "{node|short}\n"
-hg -R ua parents --template "{node|short}\n"
-rm -r ua
-
-cat <<EOF > simpleclone.py
-from mercurial import ui, hg
-myui = ui.ui()
-repo = hg.repository(myui, 'a')
-hg.clone(myui, repo, dest="ua")
-EOF
-
-python simpleclone.py
-rm -r ua
-
-cat <<EOF > branchclone.py
-from mercurial import ui, hg
-myui = ui.ui()
-repo = hg.repository(myui, 'a')
-hg.clone(myui, repo, dest="ua", branch=["stable",])
-EOF
-
-python branchclone.py
-rm -r ua
-
-exit 0
--- a/tests/test-clone-cgi	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-clone-cgi	Sat Aug 14 03:30:35 2010 +0200
@@ -55,7 +55,7 @@
 SERVER_SOFTWARE="Apache/2.0.53 (Fedora)"; export SERVER_SOFTWARE
 
 echo % try hgweb request
-QUERY_STRING="cmd=changegroup"; export QUERY_STRING
+QUERY_STRING="cmd=changegroup&roots=0000000000000000000000000000000000000000"; export QUERY_STRING
 python hgweb.cgi >page1 2>&1 ; echo $?
 python "$TESTDIR/md5sum.py" page1
 
--- a/tests/test-clone.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,323 +0,0 @@
-
-% prepare repo a
-% list files in store/data (should show a 'b.d')
-.hg/store/data/a.i
-.hg/store/data/b.d
-.hg/store/data/b.i
-
-% default operation
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-a
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-2 files, 11 changesets, 11 total revisions
-
-% no update, with debug option
-linked 8 files
-a not present
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-2 files, 11 changesets, 11 total revisions
-
-% default destination
-destination directory: a
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-a
-
-% check that we drop the file: from the path before
-% writing the .hgrc
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-% check that path aliases are expanded
-a#0
-
-% use --pull
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 11 changesets with 11 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-2 files, 11 changesets, 11 total revisions
-
-% clone to .
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-
-% *** tests for option -u ***
-
-
-% adding some more history to repo a
-% tag ref1
-% updating back to ref1
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-
-% add branch 'stable' to repo a for later tests
-marked working directory as branch stable
-% tag ref2
-
-% updating back to ref2
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-
-% parents of repo a
-changeset:   13:e8ece76546a6
-branch:      stable
-tag:         ref2
-parent:      10:a7949464abda
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     starting branch stable
-
-
-% repo a has two heads
-changeset:   15:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-changeset:   12:f21241060d6a
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     hacked default
-
-
-% testing clone -U -u 1 a ua (must abort)
-abort: cannot specify both --noupdate and --updaterev
-
-% testing clone -u . a ua
-updating to branch stable
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-% repo ua has both heads
-changeset:   15:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-changeset:   12:f21241060d6a
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     hacked default
-
-
-% same revision checked out in repo a and ua
-e8ece76546a6
-e8ece76546a6
-
-% testing clone --pull -u . a ua
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 16 changesets with 16 changes to 3 files (+1 heads)
-updating to branch stable
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-% repo ua has both heads
-changeset:   15:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-changeset:   12:f21241060d6a
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     hacked default
-
-
-% same revision checked out in repo a and ua
-e8ece76546a6
-e8ece76546a6
-
-% testing clone -u stable a ua
-updating to branch stable
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-% repo ua has both heads
-changeset:   15:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-changeset:   12:f21241060d6a
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     hacked default
-
-
-% branch stable is checked out
-changeset:   15:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-
-% testing clone a ua
-updating to branch default
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-% repo ua has both heads
-changeset:   15:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-changeset:   12:f21241060d6a
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     hacked default
-
-
-% branch default is checked out
-changeset:   12:f21241060d6a
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     hacked default
-
-
-% testing clone -u . a#stable ua
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 14 changesets with 14 changes to 3 files
-updating to branch stable
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-% repo ua has only branch stable
-changeset:   13:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-changeset:   10:a7949464abda
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     test
-
-
-% same revision checked out in repo a and ua
-e8ece76546a6
-e8ece76546a6
-
-% testing clone -u . -r stable a ua
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 14 changesets with 14 changes to 3 files
-updating to branch stable
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-% repo ua has only branch stable
-changeset:   13:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-changeset:   10:a7949464abda
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     test
-
-
-% same revision checked out in repo a and ua
-e8ece76546a6
-e8ece76546a6
-
-% testing clone -r stable a ua
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 14 changesets with 14 changes to 3 files
-updating to branch stable
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-% repo ua has only branch stable
-changeset:   13:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-changeset:   10:a7949464abda
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     test
-
-
-% branch stable is checked out
-changeset:   13:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-
-% testing clone -u . -r stable -r default a ua
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 16 changesets with 16 changes to 3 files (+1 heads)
-updating to branch stable
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-
-% repo ua has two heads
-changeset:   15:0aae7cf88f0d
-branch:      stable
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     another change for branch stable
-
-changeset:   12:f21241060d6a
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     hacked default
-
-
-% same revision checked out in repo a and ua
-e8ece76546a6
-e8ece76546a6
-updating to branch default
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 14 changesets with 14 changes to 3 files
-updating to branch stable
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-clone.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,449 @@
+Prepare repo a:
+
+  $ mkdir a
+  $ cd a
+  $ hg init
+  $ echo a > a
+  $ hg add a
+  $ hg commit -m test
+  $ echo first line > b
+  $ hg add b
+
+Create a non-inlined filelog:
+
+  $ python -c 'for x in range(10000): print x' >> data1
+  $ for j in 0 1 2 3 4 5 6 7 8 9; do
+  >   cat data1 >> b
+  >   hg commit -m test
+  > done
+
+List files in store/data (should show a 'b.d'):
+
+  $ for i in .hg/store/data/*; do
+  >   echo $i
+  > done
+  .hg/store/data/a.i
+  .hg/store/data/b.d
+  .hg/store/data/b.i
+
+Default operation:
+
+  $ hg clone . ../b
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd ../b
+  $ cat a
+  a
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  2 files, 11 changesets, 11 total revisions
+
+No update, with debug option:
+
+  $ hg --debug clone -U . ../c
+  linked 8 files
+  $ cd ../c
+  $ cat a 2>/dev/null || echo "a not present"
+  a not present
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  2 files, 11 changesets, 11 total revisions
+
+Default destination:
+
+  $ mkdir ../d
+  $ cd ../d
+  $ hg clone ../a
+  destination directory: a
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd a
+  $ hg cat a
+  a
+  $ cd ../..
+
+Check that we drop the 'file:' from the path before writing the .hgrc:
+
+  $ hg clone file:a e
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ grep 'file:' e/.hg/hgrc
+
+Check that path aliases are expanded:
+
+  $ hg clone -q -U --config 'paths.foobar=a#0' foobar f
+  $ hg -R f showconfig paths.default
+  .*/a#0
+
+Use --pull:
+
+  $ hg clone --pull a g
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 11 changesets with 11 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg -R g verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  2 files, 11 changesets, 11 total revisions
+
+Clone to '.':
+
+  $ mkdir h
+  $ cd h
+  $ hg clone ../a .
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd ..
+
+
+*** Tests for option -u ***
+
+Adding some more history to repo a:
+
+  $ cd a
+  $ hg tag ref1
+  $ echo the quick brown fox >a
+  $ hg ci -m "hacked default"
+  $ hg up ref1
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg branch stable
+  marked working directory as branch stable
+  $ echo some text >a
+  $ hg ci -m "starting branch stable"
+  $ hg tag ref2
+  $ echo some more text >a
+  $ hg ci -m "another change for branch stable"
+  $ hg up ref2
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg parents
+  changeset:   13:e8ece76546a6
+  branch:      stable
+  tag:         ref2
+  parent:      10:a7949464abda
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     starting branch stable
+  
+
+Repo a has two heads:
+
+  $ hg heads
+  changeset:   15:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+  changeset:   12:f21241060d6a
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     hacked default
+  
+
+  $ cd ..
+
+
+Testing --noupdate with --updaterev (must abort):
+
+  $ hg clone --noupdate --updaterev 1 a ua
+  abort: cannot specify both --noupdate and --updaterev
+
+
+Testing clone -u:
+
+  $ hg clone -u . a ua
+  updating to branch stable
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+Repo ua has both heads:
+
+  $ hg -R ua heads
+  changeset:   15:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+  changeset:   12:f21241060d6a
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     hacked default
+  
+
+Same revision checked out in repo a and ua:
+
+  $ hg -R a parents --template "{node|short}\n"
+  e8ece76546a6
+  $ hg -R ua parents --template "{node|short}\n"
+  e8ece76546a6
+
+  $ rm -r ua
+
+
+Testing clone --pull -u:
+
+  $ hg clone --pull -u . a ua
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 16 changesets with 16 changes to 3 files (+1 heads)
+  updating to branch stable
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+Repo ua has both heads:
+
+  $ hg -R ua heads
+  changeset:   15:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+  changeset:   12:f21241060d6a
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     hacked default
+  
+
+Same revision checked out in repo a and ua:
+
+  $ hg -R a parents --template "{node|short}\n"
+  e8ece76546a6
+  $ hg -R ua parents --template "{node|short}\n"
+  e8ece76546a6
+
+  $ rm -r ua
+
+
+Testing clone -u <branch>:
+
+  $ hg clone -u stable a ua
+  updating to branch stable
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+Repo ua has both heads:
+
+  $ hg -R ua heads
+  changeset:   15:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+  changeset:   12:f21241060d6a
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     hacked default
+  
+
+Branch 'stable' is checked out:
+
+  $ hg -R ua parents
+  changeset:   15:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+
+  $ rm -r ua
+
+
+Testing default checkout:
+
+  $ hg clone a ua
+  updating to branch default
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+Repo ua has both heads:
+
+  $ hg -R ua heads
+  changeset:   15:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+  changeset:   12:f21241060d6a
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     hacked default
+  
+
+Branch 'default' is checked out:
+
+  $ hg -R ua parents
+  changeset:   12:f21241060d6a
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     hacked default
+  
+
+  $ rm -r ua
+
+
+Testing #<branch>:
+
+  $ hg clone -u . a#stable ua
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 14 changesets with 14 changes to 3 files
+  updating to branch stable
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+Repo ua has branch 'stable' and 'default' (was changed in fd511e9eeea6):
+
+  $ hg -R ua heads
+  changeset:   13:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+  changeset:   10:a7949464abda
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     test
+  
+
+Same revision checked out in repo a and ua:
+
+  $ hg -R a parents --template "{node|short}\n"
+  e8ece76546a6
+  $ hg -R ua parents --template "{node|short}\n"
+  e8ece76546a6
+
+  $ rm -r ua
+
+
+Testing -u -r <branch>:
+
+  $ hg clone -u . -r stable a ua
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 14 changesets with 14 changes to 3 files
+  updating to branch stable
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+Repo ua has branch 'stable' and 'default' (was changed in fd511e9eeea6):
+
+  $ hg -R ua heads
+  changeset:   13:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+  changeset:   10:a7949464abda
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     test
+  
+
+Same revision checked out in repo a and ua:
+
+  $ hg -R a parents --template "{node|short}\n"
+  e8ece76546a6
+  $ hg -R ua parents --template "{node|short}\n"
+  e8ece76546a6
+
+  $ rm -r ua
+
+
+Testing -r <branch>:
+
+  $ hg clone -r stable a ua
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 14 changesets with 14 changes to 3 files
+  updating to branch stable
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+Repo ua has branch 'stable' and 'default' (was changed in fd511e9eeea6):
+
+  $ hg -R ua heads
+  changeset:   13:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+  changeset:   10:a7949464abda
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     test
+  
+
+Branch 'stable' is checked out:
+
+  $ hg -R ua parents
+  changeset:   13:0aae7cf88f0d
+  branch:      stable
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     another change for branch stable
+  
+
+  $ rm -r ua
+
+
+Testing issue2267:
+
+  $ cat <<EOF > simpleclone.py
+  > from mercurial import ui, hg
+  > myui = ui.ui()
+  > repo = hg.repository(myui, 'a')
+  > hg.clone(myui, repo, dest="ua")
+  > EOF
+
+  $ python simpleclone.py
+  updating to branch default
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+  $ rm -r ua
+
+  $ cat <<EOF > branchclone.py
+  > from mercurial import ui, hg
+  > myui = ui.ui()
+  > repo = hg.repository(myui, 'a')
+  > hg.clone(myui, repo, dest="ua", branch=["stable",])
+  > EOF
+
+  $ python branchclone.py
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 14 changesets with 14 changes to 3 files
+  updating to branch stable
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ rm -r ua
--- a/tests/test-command-template	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-command-template	Sat Aug 14 03:30:35 2010 +0200
@@ -125,6 +125,7 @@
 hg log --template '{desc|firstline}\n'
 hg log --template '{node|short}\n'
 hg log --template '<changeset author="{author|xmlescape}"/>\n'
+hg log --template '{rev}: {children}\n'
 
 echo '# formatnode filter works'
 echo '#  quiet'
--- a/tests/test-command-template.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-command-template.out	Sat Aug 14 03:30:35 2010 +0200
@@ -1018,6 +1018,15 @@
 <changeset author="other@place"/>
 <changeset author="A. N. Other &lt;other@place&gt;"/>
 <changeset author="User Name &lt;user@hostname&gt;"/>
+8: 
+7: 8:95c24699272e
+6: 
+5: 6:c7b487c6c50e
+4: 6:c7b487c6c50e
+3: 4:32a18f097fcc 5:13207e5a10d9
+2: 3:10e46f2dcbf4
+1: 2:97054abb4ab8
+0: 1:b608e9d1a3f0
 # formatnode filter works
 #  quiet
 1e4e1b8f71e0
--- a/tests/test-commit	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,126 +0,0 @@
-#!/bin/sh
-
-echo % commit date test
-hg init test
-cd test
-echo foo > foo
-hg add foo
-HGEDITOR=true hg commit -m ""
-hg commit -d '0 0' -m commit-1
-echo foo >> foo
-hg commit -d '1 4444444' -m commit-3
-hg commit -d '1	15.1' -m commit-4
-hg commit -d 'foo bar' -m commit-5
-hg commit -d ' 1 4444' -m commit-6
-hg commit -d '111111111111 0' -m commit-7
-
-echo % commit added file that has been deleted
-echo bar > bar
-hg add bar
-rm bar
-hg commit -d "1000000 0" -m commit-8
-hg commit -d "1000000 0" -m commit-8-2 bar
-
-hg -q revert -a --no-backup
-
-mkdir dir
-echo boo > dir/file
-hg add
-hg -v commit -m commit-9 dir
-
-echo > dir.file
-hg add
-hg commit -m commit-10 dir dir.file
-
-echo >> dir/file
-mkdir bleh
-mkdir dir2
-cd bleh
-hg commit -m commit-11 .
-hg commit -m commit-12 ../dir ../dir2
-hg -v commit -m commit-13 ../dir
-cd ..
-
-hg commit -m commit-14 does-not-exist
-ln -s foo baz
-hg commit -m commit-15 baz
-touch quux
-hg commit -m commit-16 quux
-echo >> dir/file
-hg -v commit -m commit-17 dir/file
-# An empty date was interpreted as epoch origin
-echo foo >> foo
-hg commit -d '' -m commit-no-date
-hg tip --template '{date|isodate}\n' | grep '1970'
-cd ..
-
-echo % partial subdir commit test
-hg init test2
-cd test2
-mkdir foo
-echo foo > foo/foo
-mkdir bar
-echo bar > bar/bar
-hg add
-hg ci -d '1000000 0' -m commit-subdir-1 foo
-hg ci -d '1000001 0' -m commit-subdir-2 bar
-echo % subdir log 1
-hg log -v foo
-echo % subdir log 2
-hg log -v bar
-echo % full log
-hg log -v
-cd ..
-
-echo % dot and subdir commit test
-hg init test3
-cd test3
-mkdir foo
-echo foo content > foo/plain-file
-hg add foo/plain-file
-hg ci -d '1000000 0' -m commit-foo-subdir foo
-echo modified foo content > foo/plain-file
-hg ci -d '2000000 0' -m commit-foo-dot .
-echo % full log
-hg log -v
-echo % subdir log
-cd foo
-hg log .
-cd ..
-cd ..
-
-cd ..
-hg init issue1049
-cd issue1049
-echo a > a
-hg ci -Ama
-echo a >> a
-hg ci -mb
-hg up 0
-echo b >> a
-hg ci -mc
-HGMERGE=true hg merge
-echo % should fail because we are specifying a file name
-hg ci -mmerge a
-echo % should fail because we are specifying a pattern
-hg ci -mmerge -I a
-echo % should succeed
-hg ci -mmerge
-cd ..
-
-
-echo % test commit message content
-hg init commitmsg
-cd commitmsg
-echo changed > changed
-echo removed > removed
-hg ci -qAm init
-
-hg rm removed
-echo changed >> changed
-echo added > added
-hg add added
-HGEDITOR=cat hg ci -A
-cd ..
-
-exit 0
--- a/tests/test-commit-copy	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,14 +0,0 @@
-#!/bin/sh
-
-hg init dir
-cd dir
-echo bleh > bar
-hg add bar
-hg ci -m 'add bar'
-
-hg cp bar foo
-echo >> bar
-hg ci -m 'cp bar foo; change bar'
-
-hg debugrename foo
-hg debugindex .hg/store/data/bar.i
--- a/tests/test-commit-copy.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,4 +0,0 @@
-foo renamed from bar:26d3ca0dfd18e44d796b564e38dd173c9668d3a9
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0       6      0       0 26d3ca0dfd18 000000000000 000000000000
-     1         6       7      1       1 d267bddd54f7 26d3ca0dfd18 000000000000
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-commit-copy.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,16 @@
+  $ hg init dir
+  $ cd dir
+  $ echo bleh > bar
+  $ hg add bar
+  $ hg ci -m 'add bar'
+
+  $ hg cp bar foo
+  $ echo >> bar
+  $ hg ci -m 'cp bar foo; change bar'
+
+  $ hg debugrename foo
+  foo renamed from bar:26d3ca0dfd18e44d796b564e38dd173c9668d3a9
+  $ hg debugindex .hg/store/data/bar.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0       6      0       0 26d3ca0dfd18 000000000000 000000000000
+       1         6       7      1       1 d267bddd54f7 26d3ca0dfd18 000000000000
--- a/tests/test-commit-unresolved	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,41 +0,0 @@
-#!/bin/sh
-
-echo "[extensions]" >> $HGRCPATH
-echo "graphlog=" >> $HGRCPATH
-
-addcommit () {
-    echo $1 > $1
-    hg add $1
-    hg commit -d "${2} 0" -m $1
-}
-
-commit () {
-    hg commit -d "${2} 0" -m $1
-}
-
-hg init a
-cd a
-addcommit "A" 0
-addcommit "B" 1
-echo "C" >> A
-commit "C" 2
-
-hg update -C 0
-echo "D" >> A
-commit "D" 3
-
-echo
-echo "% Merging a conflict araises"
-hg merge
-
-echo
-echo "% Correct the conflict without marking the file as resolved"
-echo "ABCD" > A
-hg commit -m "Merged"
-
-echo
-echo "% Mark the conflict as resolved and commit"
-hg resolve -m A
-hg commit -m "Merged"
-
-exit 0
--- a/tests/test-commit-unresolved.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,14 +0,0 @@
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-created new head
-
-% Merging a conflict araises
-merging A
-warning: conflicts during merge.
-merging A failed!
-1 files updated, 0 files merged, 0 files removed, 1 files unresolved
-use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon
-
-% Correct the conflict without marking the file as resolved
-abort: unresolved merge conflicts (see hg resolve)
-
-% Mark the conflict as resolved and commit
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-commit-unresolved.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,47 @@
+  $ echo "[extensions]" >> $HGRCPATH
+  $ echo "graphlog=" >> $HGRCPATH
+
+  $ addcommit () {
+  >     echo $1 > $1
+  >     hg add $1
+  >     hg commit -d "${2} 0" -m $1
+  > }
+
+  $ commit () {
+  >     hg commit -d "${2} 0" -m $1
+  > }
+
+  $ hg init a
+  $ cd a
+  $ addcommit "A" 0
+  $ addcommit "B" 1
+  $ echo "C" >> A
+  $ commit "C" 2
+
+  $ hg update -C 0
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ echo "D" >> A
+  $ commit "D" 3
+  created new head
+
+Merging a conflict araises
+
+  $ hg merge
+  merging A
+  warning: conflicts during merge.
+  merging A failed!
+  1 files updated, 0 files merged, 0 files removed, 1 files unresolved
+  use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon
+
+Correct the conflict without marking the file as resolved
+
+  $ echo "ABCD" > A
+  $ hg commit -m "Merged"
+  abort: unresolved merge conflicts (see hg resolve)
+
+Mark the conflict as resolved and commit
+
+  $ hg resolve -m A
+  $ hg commit -m "Merged"
+
+  $ exit 0
--- a/tests/test-commit.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,117 +0,0 @@
-% commit date test
-abort: empty commit message
-abort: impossible time zone offset: 4444444
-abort: invalid date: '1\t15.1' 
-abort: invalid date: 'foo bar' 
-abort: date exceeds 32 bits: 111111111111
-% commit added file that has been deleted
-nothing changed
-abort: bar: file not found!
-adding dir/file
-dir/file
-committed changeset 2:d2a76177cb42
-adding dir.file
-abort: dir: no match under directory!
-abort: bleh: no match under directory!
-abort: dir2: no match under directory!
-dir/file
-committed changeset 3:1cd62a2d8db5
-abort: does-not-exist: No such file or directory
-abort: baz: file not tracked!
-abort: quux: file not tracked!
-dir/file
-committed changeset 4:49176991390e
-% partial subdir commit test
-adding bar/bar
-adding foo/foo
-% subdir log 1
-changeset:   0:6ef3cb06bb80
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-files:       foo/foo
-description:
-commit-subdir-1
-
-
-% subdir log 2
-changeset:   1:f2e51572cf5a
-tag:         tip
-user:        test
-date:        Mon Jan 12 13:46:41 1970 +0000
-files:       bar/bar
-description:
-commit-subdir-2
-
-
-% full log
-changeset:   1:f2e51572cf5a
-tag:         tip
-user:        test
-date:        Mon Jan 12 13:46:41 1970 +0000
-files:       bar/bar
-description:
-commit-subdir-2
-
-
-changeset:   0:6ef3cb06bb80
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-files:       foo/foo
-description:
-commit-subdir-1
-
-
-% dot and subdir commit test
-% full log
-changeset:   1:d9180e04fa8a
-tag:         tip
-user:        test
-date:        Sat Jan 24 03:33:20 1970 +0000
-files:       foo/plain-file
-description:
-commit-foo-dot
-
-
-changeset:   0:80b572aaf098
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-files:       foo/plain-file
-description:
-commit-foo-subdir
-
-
-% subdir log
-changeset:   1:d9180e04fa8a
-tag:         tip
-user:        test
-date:        Sat Jan 24 03:33:20 1970 +0000
-summary:     commit-foo-dot
-
-changeset:   0:80b572aaf098
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     commit-foo-subdir
-
-adding a
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-merging a
-0 files updated, 1 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-% should fail because we are specifying a file name
-abort: cannot partially commit a merge (do not specify files or patterns)
-% should fail because we are specifying a pattern
-abort: cannot partially commit a merge (do not specify files or patterns)
-% should succeed
-% test commit message content
-
-
-HG: Enter commit message.  Lines beginning with 'HG:' are removed.
-HG: Leave message empty to abort commit.
-HG: --
-HG: user: test
-HG: branch 'default'
-HG: added added
-HG: changed changed
-HG: removed removed
-abort: empty commit message
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-commit.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,253 @@
+commit date test
+
+  $ hg init test
+  $ cd test
+  $ echo foo > foo
+  $ hg add foo
+  $ HGEDITOR=true hg commit -m ""
+  abort: empty commit message
+  $ hg commit -d '0 0' -m commit-1
+  $ echo foo >> foo
+  $ hg commit -d '1 4444444' -m commit-3
+  abort: impossible time zone offset: 4444444
+  $ hg commit -d '1	15.1' -m commit-4
+  abort: invalid date: '1\t15.1' 
+  $ hg commit -d 'foo bar' -m commit-5
+  abort: invalid date: 'foo bar' 
+  $ hg commit -d ' 1 4444' -m commit-6
+  $ hg commit -d '111111111111 0' -m commit-7
+  abort: date exceeds 32 bits: 111111111111
+
+commit added file that has been deleted
+
+  $ echo bar > bar
+  $ hg add bar
+  $ rm bar
+  $ hg commit -d "1000000 0" -m commit-8
+  nothing changed
+  $ hg commit -d "1000000 0" -m commit-8-2 bar
+  abort: bar: file not found!
+
+  $ hg -q revert -a --no-backup
+
+  $ mkdir dir
+  $ echo boo > dir/file
+  $ hg add
+  adding dir/file
+  $ hg -v commit -m commit-9 dir
+  dir/file
+  committed changeset 2:d2a76177cb42
+
+  $ echo > dir.file
+  $ hg add
+  adding dir.file
+  $ hg commit -m commit-10 dir dir.file
+  abort: dir: no match under directory!
+
+  $ echo >> dir/file
+  $ mkdir bleh
+  $ mkdir dir2
+  $ cd bleh
+  $ hg commit -m commit-11 .
+  abort: bleh: no match under directory!
+  $ hg commit -m commit-12 ../dir ../dir2
+  abort: dir2: no match under directory!
+  $ hg -v commit -m commit-13 ../dir
+  dir/file
+  committed changeset 3:1cd62a2d8db5
+  $ cd ..
+
+  $ hg commit -m commit-14 does-not-exist
+  abort: does-not-exist: No such file or directory
+  $ ln -s foo baz
+  $ hg commit -m commit-15 baz
+  abort: baz: file not tracked!
+  $ touch quux
+  $ hg commit -m commit-16 quux
+  abort: quux: file not tracked!
+  $ echo >> dir/file
+  $ hg -v commit -m commit-17 dir/file
+  dir/file
+  committed changeset 4:49176991390e
+
+An empty date was interpreted as epoch origin
+
+  $ echo foo >> foo
+  $ hg commit -d '' -m commit-no-date
+  $ hg tip --template '{date|isodate}\n' | grep '1970'
+  $ cd ..
+
+
+partial subdir commit test
+
+  $ hg init test2
+  $ cd test2
+  $ mkdir foo
+  $ echo foo > foo/foo
+  $ mkdir bar
+  $ echo bar > bar/bar
+  $ hg add
+  adding bar/bar
+  adding foo/foo
+  $ hg ci -d '1000000 0' -m commit-subdir-1 foo
+  $ hg ci -d '1000001 0' -m commit-subdir-2 bar
+
+subdir log 1
+
+  $ hg log -v foo
+  changeset:   0:6ef3cb06bb80
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  files:       foo/foo
+  description:
+  commit-subdir-1
+  
+  
+
+subdir log 2
+
+  $ hg log -v bar
+  changeset:   1:f2e51572cf5a
+  tag:         tip
+  user:        test
+  date:        Mon Jan 12 13:46:41 1970 +0000
+  files:       bar/bar
+  description:
+  commit-subdir-2
+  
+  
+
+full log
+
+  $ hg log -v
+  changeset:   1:f2e51572cf5a
+  tag:         tip
+  user:        test
+  date:        Mon Jan 12 13:46:41 1970 +0000
+  files:       bar/bar
+  description:
+  commit-subdir-2
+  
+  
+  changeset:   0:6ef3cb06bb80
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  files:       foo/foo
+  description:
+  commit-subdir-1
+  
+  
+  $ cd ..
+
+
+dot and subdir commit test
+
+  $ hg init test3
+  $ cd test3
+  $ mkdir foo
+  $ echo foo content > foo/plain-file
+  $ hg add foo/plain-file
+  $ hg ci -d '1000000 0' -m commit-foo-subdir foo
+  $ echo modified foo content > foo/plain-file
+  $ hg ci -d '2000000 0' -m commit-foo-dot .
+
+full log
+
+  $ hg log -v
+  changeset:   1:d9180e04fa8a
+  tag:         tip
+  user:        test
+  date:        Sat Jan 24 03:33:20 1970 +0000
+  files:       foo/plain-file
+  description:
+  commit-foo-dot
+  
+  
+  changeset:   0:80b572aaf098
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  files:       foo/plain-file
+  description:
+  commit-foo-subdir
+  
+  
+
+subdir log
+
+  $ cd foo
+  $ hg log .
+  changeset:   1:d9180e04fa8a
+  tag:         tip
+  user:        test
+  date:        Sat Jan 24 03:33:20 1970 +0000
+  summary:     commit-foo-dot
+  
+  changeset:   0:80b572aaf098
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     commit-foo-subdir
+  
+  $ cd ..
+  $ cd ..
+
+  $ cd ..
+  $ hg init issue1049
+  $ cd issue1049
+  $ echo a > a
+  $ hg ci -Ama
+  adding a
+  $ echo a >> a
+  $ hg ci -mb
+  $ hg up 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo b >> a
+  $ hg ci -mc
+  created new head
+  $ HGMERGE=true hg merge
+  merging a
+  0 files updated, 1 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+
+should fail because we are specifying a file name
+
+  $ hg ci -mmerge a
+  abort: cannot partially commit a merge (do not specify files or patterns)
+
+should fail because we are specifying a pattern
+
+  $ hg ci -mmerge -I a
+  abort: cannot partially commit a merge (do not specify files or patterns)
+
+should succeed
+
+  $ hg ci -mmerge
+  $ cd ..
+
+
+test commit message content
+
+  $ hg init commitmsg
+  $ cd commitmsg
+  $ echo changed > changed
+  $ echo removed > removed
+  $ hg ci -qAm init
+
+  $ hg rm removed
+  $ echo changed >> changed
+  $ echo added > added
+  $ hg add added
+  $ HGEDITOR=cat hg ci -A
+  
+  
+  HG: Enter commit message.  Lines beginning with 'HG:' are removed.
+  HG: Leave message empty to abort commit.
+  HG: --
+  HG: user: test
+  HG: branch 'default'
+  HG: added added
+  HG: changed changed
+  HG: removed removed
+  abort: empty commit message
+  $ cd ..
+
+  $ exit 0
--- a/tests/test-committer	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,36 +0,0 @@
-#!/bin/sh
-
-unset HGUSER
-EMAIL="My Name <myname@example.com>"
-export EMAIL
-
-hg init test
-cd test
-touch asdf
-hg add asdf
-hg commit -d '1000000 0' -m commit-1
-hg tip
-
-unset EMAIL
-echo 1234 > asdf
-hg commit -d '1000000 0' -u "foo@bar.com" -m commit-1
-hg tip
-echo "[ui]" >> .hg/hgrc
-echo "username = foobar <foo@bar.com>" >> .hg/hgrc
-echo 12 > asdf
-hg commit -d '1000000 0' -m commit-1
-hg tip
-echo 1 > asdf
-hg commit -d '1000000 0' -u "foo@bar.com" -m commit-1
-hg tip
-echo 123 > asdf
-echo "[ui]" > .hg/hgrc
-echo "username = " >> .hg/hgrc
-hg commit -d '1000000 0' -m commit-1
-rm .hg/hgrc
-hg commit -d '1000000 0' -m commit-1 2>&1 | sed -e "s/'[^']*'/user@host/"
-
-echo space > asdf
-hg commit -d '1000000 0' -u ' ' -m commit-1
-
-true
--- a/tests/test-committer.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,29 +0,0 @@
-changeset:   0:9426b370c206
-tag:         tip
-user:        My Name <myname@example.com>
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     commit-1
-
-changeset:   1:4997f15a1b24
-tag:         tip
-user:        foo@bar.com
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     commit-1
-
-changeset:   2:72b8012b424e
-tag:         tip
-user:        foobar <foo@bar.com>
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     commit-1
-
-changeset:   3:35ff3067bedd
-tag:         tip
-user:        foo@bar.com
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     commit-1
-
-abort: no username supplied (see "hg help config")
-No username found, using user@host instead
-transaction abort!
-rollback completed
-abort: empty username!
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-committer.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,63 @@
+  $ unset HGUSER
+  $ EMAIL="My Name <myname@example.com>"
+  $ export EMAIL
+
+  $ hg init test
+  $ cd test
+  $ touch asdf
+  $ hg add asdf
+  $ hg commit -d '1000000 0' -m commit-1
+  $ hg tip
+  changeset:   0:9426b370c206
+  tag:         tip
+  user:        My Name <myname@example.com>
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     commit-1
+  
+
+  $ unset EMAIL
+  $ echo 1234 > asdf
+  $ hg commit -d '1000000 0' -u "foo@bar.com" -m commit-1
+  $ hg tip
+  changeset:   1:4997f15a1b24
+  tag:         tip
+  user:        foo@bar.com
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     commit-1
+  
+  $ echo "[ui]" >> .hg/hgrc
+  $ echo "username = foobar <foo@bar.com>" >> .hg/hgrc
+  $ echo 12 > asdf
+  $ hg commit -d '1000000 0' -m commit-1
+  $ hg tip
+  changeset:   2:72b8012b424e
+  tag:         tip
+  user:        foobar <foo@bar.com>
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     commit-1
+  
+  $ echo 1 > asdf
+  $ hg commit -d '1000000 0' -u "foo@bar.com" -m commit-1
+  $ hg tip
+  changeset:   3:35ff3067bedd
+  tag:         tip
+  user:        foo@bar.com
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     commit-1
+  
+  $ echo 123 > asdf
+  $ echo "[ui]" > .hg/hgrc
+  $ echo "username = " >> .hg/hgrc
+  $ hg commit -d '1000000 0' -m commit-1
+  abort: no username supplied (see "hg help config")
+  $ rm .hg/hgrc
+  $ hg commit -d '1000000 0' -m commit-1 2>&1
+  No username found, using '[^']*' instead
+
+  $ echo space > asdf
+  $ hg commit -d '1000000 0' -u ' ' -m commit-1
+  transaction abort!
+  rollback completed
+  abort: empty username!
+
+  $ true
--- a/tests/test-conflict	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-#!/bin/sh
-
-hg init
-echo "nothing" > a
-hg add a
-hg commit -m ancestor -d "1000000 0"
-echo "something" > a
-hg commit -m branch1 -d "1000000 0"
-hg co 0
-echo "something else" > a
-hg commit -m branch2 -d "1000000 0"
-hg merge 1
-hg id
-cat a
-hg status
--- a/tests/test-conflict.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-merging a
-warning: conflicts during merge.
-merging a failed!
-0 files updated, 0 files merged, 0 files removed, 1 files unresolved
-use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon
-e7fe8eb3e180+0d24b7662d3e+ tip
-<<<<<<< local
-something else
-=======
-something
->>>>>>> other
-M a
-? a.orig
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-conflict.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,32 @@
+  $ hg init
+  $ echo "nothing" > a
+  $ hg add a
+  $ hg commit -m ancestor -d "1000000 0"
+  $ echo "something" > a
+  $ hg commit -m branch1 -d "1000000 0"
+  $ hg co 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo "something else" > a
+  $ hg commit -m branch2 -d "1000000 0"
+  created new head
+
+  $ hg merge 1
+  merging a
+  warning: conflicts during merge.
+  merging a failed!
+  0 files updated, 0 files merged, 0 files removed, 1 files unresolved
+  use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon
+
+  $ hg id
+  e7fe8eb3e180+0d24b7662d3e+ tip
+
+  $ cat a
+  <<<<<<< local
+  something else
+  =======
+  something
+  >>>>>>> other
+
+  $ hg status
+  M a
+  ? a.orig
--- a/tests/test-convert-filemap	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-convert-filemap	Sat Aug 14 03:30:35 2010 +0200
@@ -128,3 +128,14 @@
 hg --cwd source cat copied
 echo 'copied2:'
 hg --cwd renames.repo cat copied2
+
+echo % filemap errors
+cat > errors.fmap <<EOF
+include dir/ # beware that comments changes error line numbers!
+exclude /dir
+rename dir//dir /dir//dir/ "out of sync"
+include
+EOF
+hg -q convert --filemap errors.fmap source errors.repo
+
+true # happy ending
--- a/tests/test-convert-filemap.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-convert-filemap.out	Sat Aug 14 03:30:35 2010 +0200
@@ -157,3 +157,11 @@
 foo
 copied2:
 foo
+% filemap errors
+errors.fmap:1: superfluous / in exclude 'dir/'
+errors.fmap:3: superfluous / in include '/dir'
+errors.fmap:3: superfluous / in rename '/dir'
+errors.fmap:3: superfluous / in exclude 'dir//dir'
+errors.fmap:4: unknown directive 'out of sync'
+errors.fmap:5: path to exclude is missing
+abort: errors in filemap
--- a/tests/test-convert-hg-source	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-convert-hg-source	Sat Aug 14 03:30:35 2010 +0200
@@ -32,6 +32,10 @@
 chmod +x baz
 hg ci -m 'mark baz executable' -d '5 0'
 
+hg branch foo
+hg ci -m 'branch foo' -d '6 0'
+hg ci --close-branch -m 'close' -d '7 0'
+
 cd ..
 hg convert --datesort orig new 2>&1 | grep -v 'subversion python bindings could not be loaded'
 cd new
--- a/tests/test-convert-hg-source.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-convert-hg-source.out	Sat Aug 14 03:30:35 2010 +0200
@@ -7,16 +7,19 @@
 1 files updated, 1 files merged, 0 files removed, 0 files unresolved
 (branch merge, don't forget to commit)
 created new head
+marked working directory as branch foo
 initializing destination new repository
 scanning source...
 sorting...
 converting...
-5 add foo bar
-4 change foo
-3 make bar and baz copies of foo
-2 merge local copy
-1 merge remote copy
-0 mark baz executable
+7 add foo bar
+6 change foo
+5 make bar and baz copies of foo
+4 merge local copy
+3 merge remote copy
+2 mark baz executable
+1 branch foo
+0 close
 comparing with ../orig
 searching for changes
 no changes found
--- a/tests/test-convert.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-convert.out	Sat Aug 14 03:30:35 2010 +0200
@@ -65,7 +65,7 @@
 
       rename path/to/source path/to/destination
 
-    Comment lines start with '#'. A specificed path matches if it equals the
+    Comment lines start with '#'. A specified path matches if it equals the
     full relative name of a file or one of its parent directories. The
     'include' or 'exclude' directive with the longest matching path applies,
     so line order does not matter.
@@ -74,7 +74,7 @@
     be included in the destination repository, and the exclusion of all other
     files and directories not explicitly included. The 'exclude' directive
     causes files or directories to be omitted. The 'rename' directive renames
-    a file or directory if is converted. To rename from a subdirectory into
+    a file or directory if it is converted. To rename from a subdirectory into
     the root of the repository, use '.' as the path to rename to.
 
     The splicemap is a file that allows insertion of synthetic history,
--- a/tests/test-copy	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,31 +0,0 @@
-#!/bin/sh
-
-hg init
-echo a > a
-hg add a
-hg commit -m "1" -d "1000000 0"
-hg status
-hg copy a b
-hg status
-hg sum
-hg --debug commit -m "2" -d "1000000 0"
-echo "we should see two history entries"
-hg history -v
-echo "we should see one log entry for a"
-hg log a
-echo "this should show a revision linked to changeset 0"
-hg debugindex .hg/store/data/a.i
-echo "we should see one log entry for b"
-hg log b
-echo "this should show a revision linked to changeset 1"
-hg debugindex .hg/store/data/b.i
-
-echo "this should show the rename information in the metadata"
-hg debugdata .hg/store/data/b.d 0 | head -3 | tail -2
-
-$TESTDIR/md5sum.py .hg/store/data/b.i
-hg cat b > bsum
-$TESTDIR/md5sum.py bsum
-hg cat a > asum
-$TESTDIR/md5sum.py asum
-hg verify
--- a/tests/test-copy.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,57 +0,0 @@
-A b
-parent: 0:33aaa84a386b tip
- 1
-branch: default
-commit: 1 copied
-update: (current)
-b
- b: copy a:b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3
-committed changeset 1:76973b01f66a012648546c979ea4c41de9e7d8cd
-we should see two history entries
-changeset:   1:76973b01f66a
-tag:         tip
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-files:       b
-description:
-2
-
-
-changeset:   0:33aaa84a386b
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-files:       a
-description:
-1
-
-
-we should see one log entry for a
-changeset:   0:33aaa84a386b
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     1
-
-this should show a revision linked to changeset 0
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0       3      0       0 b789fdd96dc2 000000000000 000000000000
-we should see one log entry for b
-changeset:   1:76973b01f66a
-tag:         tip
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     2
-
-this should show a revision linked to changeset 1
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0      65      0       1 37d9b5d994ea 000000000000 000000000000
-this should show the rename information in the metadata
-copy: a
-copyrev: b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3
-4999f120a3b88713bbefddd195cf5133  .hg/store/data/b.i
-60b725f10c9c85c70d97880dfe8191b3  bsum
-60b725f10c9c85c70d97880dfe8191b3  asum
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-2 files, 2 changesets, 2 total revisions
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-copy.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,91 @@
+  $ hg init
+  $ echo a > a
+  $ hg add a
+  $ hg commit -m "1" -d "1000000 0"
+  $ hg status
+  $ hg copy a b
+  $ hg status
+  A b
+  $ hg sum
+  parent: 0:33aaa84a386b tip
+   1
+  branch: default
+  commit: 1 copied
+  update: (current)
+  $ hg --debug commit -m "2" -d "1000000 0"
+  b
+   b: copy a:b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3
+  committed changeset 1:76973b01f66a012648546c979ea4c41de9e7d8cd
+
+we should see two history entries
+
+  $ hg history -v
+  changeset:   1:76973b01f66a
+  tag:         tip
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  files:       b
+  description:
+  2
+  
+  
+  changeset:   0:33aaa84a386b
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  files:       a
+  description:
+  1
+  
+  
+
+we should see one log entry for a
+
+  $ hg log a
+  changeset:   0:33aaa84a386b
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     1
+  
+
+this should show a revision linked to changeset 0
+
+  $ hg debugindex .hg/store/data/a.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0       3      0       0 b789fdd96dc2 000000000000 000000000000
+
+we should see one log entry for b
+
+  $ hg log b
+  changeset:   1:76973b01f66a
+  tag:         tip
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     2
+  
+
+this should show a revision linked to changeset 1
+
+  $ hg debugindex .hg/store/data/b.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0      65      0       1 37d9b5d994ea 000000000000 000000000000
+
+this should show the rename information in the metadata
+
+  $ hg debugdata .hg/store/data/b.d 0 | head -3 | tail -2
+  copy: a
+  copyrev: b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3
+
+  $ $TESTDIR/md5sum.py .hg/store/data/b.i
+  4999f120a3b88713bbefddd195cf5133  .hg/store/data/b.i
+  $ hg cat b > bsum
+  $ $TESTDIR/md5sum.py bsum
+  60b725f10c9c85c70d97880dfe8191b3  bsum
+  $ hg cat a > asum
+  $ $TESTDIR/md5sum.py asum
+  60b725f10c9c85c70d97880dfe8191b3  asum
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  2 files, 2 changesets, 2 total revisions
--- a/tests/test-debugbuilddag	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-debugbuilddag	Sat Aug 14 03:30:35 2010 +0200
@@ -13,6 +13,8 @@
 hg debugbuilddag '+2:f +3:p2 @temp <f+4 @default /p2 +2' -q -oa
 echo -- dag
 hg debugdag -t -b
+echo -- tip
+hg id
 echo -- glog
 hg glog --template '{rev}: {desc} [{branches}] @ {date}\n'
 echo -- glog of
@@ -35,6 +37,8 @@
 hg debugbuilddag '+2:f +3:p2 @temp <f+4 @default /p2 +2' -q -mn
 echo -- dag
 hg debugdag -t -b
+echo -- tip
+hg id
 echo -- glog
 hg glog --template '{rev}: {desc} [{branches}] @ {date}\n'
 echo -- glog mf
--- a/tests/test-debugbuilddag.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-debugbuilddag.out	Sat Aug 14 03:30:35 2010 +0200
@@ -4,6 +4,8 @@
 +3:p2
 @temp*f+3
 @default*/p2+2:tip
+-- tip
+f96e381c614c tip
 -- glog
 @  11: r11 [] @ 11.00
 |
@@ -101,6 +103,8 @@
 +3:p2
 @temp*f+3
 @default*/p2+2:tip
+-- tip
+9c5ce9b70771 tip
 -- glog
 @  11: r11 [] @ 11.00
 |
--- a/tests/test-diff-color.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-diff-color.out	Sat Aug 14 03:30:35 2010 +0200
@@ -30,7 +30,7 @@
 diff --git a/a b/a
 old mode 100644
 new mode 100755
-1 hunks, 2 lines changed
+1 hunks, 1 lines changed
 examine changes to 'a'? [Ynsfdaq?] 
 @@ -2,7 +2,7 @@
  c
@@ -48,7 +48,7 @@
 diff --git a/a b/a
 old mode 100644
 new mode 100755
-1 hunks, 2 lines changed
+1 hunks, 1 lines changed
 examine changes to 'a'? [Ynsfdaq?] 
 @@ -2,7 +2,7 @@
  c
--- a/tests/test-diff-upgrade	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-diff-upgrade	Sat Aug 14 03:30:35 2010 +0200
@@ -35,7 +35,7 @@
 python -c "file('binary', 'wb').write('\0\0')"
 python -c "file('newbinary', 'wb').write('\0')"
 rm rmbinary
-hg addremove
+hg addremove -s 0
 
 echo '% git=no: regular diff for all files'
 hg autodiff --git=no
--- a/tests/test-dirstate-future	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,13 +0,0 @@
-#!/bin/sh
-
-hg init
-echo a > a
-hg add
-hg ci -m1
-
-# set mtime of a into the future
-touch -t 202101011200 a
-
-# status must not set a's entry to unset (issue1790)
-hg status
-hg debugstate
--- a/tests/test-dirstate-future.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,2 +0,0 @@
-adding a
-n 644          2 2021-01-01 12:00:00 a
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-dirstate-future.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,18 @@
+Prepare test repo:
+
+  $ hg init
+  $ echo a > a
+  $ hg add
+  adding a
+  $ hg ci -m1
+
+Set mtime of a into the future:
+
+  $ touch -t 202101011200 a
+
+Status must not set a's entry to unset (issue1790):
+
+  $ hg status
+  $ hg debugstate
+  n 644          2 2021-01-01 12:00:00 a
+
--- a/tests/test-dumprevlog	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,61 +0,0 @@
-#!/bin/sh
-
-CONTRIBDIR=$TESTDIR/../contrib
-
-echo % prepare repo-a
-mkdir repo-a
-cd repo-a
-hg init
-
-echo this is file a > a
-hg add a
-hg commit -m first
-
-echo adding to file a >> a
-hg commit -m second
-
-echo adding more to file a >> a
-hg commit -m third
-
-hg verify
-
-echo
-echo % dumping revlog of file a to stdout
-python $CONTRIBDIR/dumprevlog .hg/store/data/a.i
-echo % dumprevlog done
-
-echo
-echo % dump all revlogs to file repo.dump
-find .hg/store -name "*.i" | sort | xargs python $CONTRIBDIR/dumprevlog > ../repo.dump
-
-cd ..
-
-mkdir repo-b
-cd repo-b
-hg init
-
-echo
-echo % undumping into repo-b
-python $CONTRIBDIR/undumprevlog < ../repo.dump
-echo % undumping done
-
-cd ..
-
-echo
-echo % clone --pull repo-b repo-c  to rebuild fncache
-hg clone --pull -U repo-b repo-c
-
-cd repo-c
-
-echo
-echo % verify repo-c
-hg verify
-
-cd ..
-
-echo
-echo % comparing repos
-hg -R repo-c incoming repo-a
-hg -R repo-a incoming repo-c
-
-exit 0
--- a/tests/test-dumprevlog.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,67 +0,0 @@
-% prepare repo-a
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-1 files, 3 changesets, 3 total revisions
-
-% dumping revlog of file a to stdout
-file: .hg/store/data/a.i
-node: 183d2312b35066fb6b3b449b84efc370d50993d0
-linkrev: 0
-parents: 0000000000000000000000000000000000000000 0000000000000000000000000000000000000000
-length: 15
--start-
-this is file a
-
--end-
-node: b1047953b6e6b633c0d8197eaa5116fbdfd3095b
-linkrev: 1
-parents: 183d2312b35066fb6b3b449b84efc370d50993d0 0000000000000000000000000000000000000000
-length: 32
--start-
-this is file a
-adding to file a
-
--end-
-node: 8c4fd1f7129b8cdec6c7f58bf48fb5237a4030c1
-linkrev: 2
-parents: b1047953b6e6b633c0d8197eaa5116fbdfd3095b 0000000000000000000000000000000000000000
-length: 54
--start-
-this is file a
-adding to file a
-adding more to file a
-
--end-
-% dumprevlog done
-
-% dump all revlogs to file repo.dump
-
-% undumping into repo-b
-.hg/store/00changelog.i
-.hg/store/00manifest.i
-.hg/store/data/a.i
-% undumping done
-
-% clone --pull repo-b repo-c to rebuild fncache
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 3 changesets with 3 changes to 1 files
-
-% verify repo-c
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-1 files, 3 changesets, 3 total revisions
-
-% comparing repos
-comparing with repo-a
-searching for changes
-no changes found
-comparing with repo-c
-searching for changes
-no changes found
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-dumprevlog.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,107 @@
+Set vars:
+
+  $ CONTRIBDIR=$TESTDIR/../contrib
+
+Prepare repo-a:
+
+  $ mkdir repo-a
+  $ cd repo-a
+  $ hg init
+
+  $ echo this is file a > a
+  $ hg add a
+  $ hg commit -m first
+
+  $ echo adding to file a >> a
+  $ hg commit -m second
+
+  $ echo adding more to file a >> a
+  $ hg commit -m third
+
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  1 files, 3 changesets, 3 total revisions
+
+Dumping revlog of file a to stdout:
+
+  $ python $CONTRIBDIR/dumprevlog .hg/store/data/a.i
+  file: .hg/store/data/a.i
+  node: 183d2312b35066fb6b3b449b84efc370d50993d0
+  linkrev: 0
+  parents: 0000000000000000000000000000000000000000 0000000000000000000000000000000000000000
+  length: 15
+  -start-
+  this is file a
+  
+  -end-
+  node: b1047953b6e6b633c0d8197eaa5116fbdfd3095b
+  linkrev: 1
+  parents: 183d2312b35066fb6b3b449b84efc370d50993d0 0000000000000000000000000000000000000000
+  length: 32
+  -start-
+  this is file a
+  adding to file a
+  
+  -end-
+  node: 8c4fd1f7129b8cdec6c7f58bf48fb5237a4030c1
+  linkrev: 2
+  parents: b1047953b6e6b633c0d8197eaa5116fbdfd3095b 0000000000000000000000000000000000000000
+  length: 54
+  -start-
+  this is file a
+  adding to file a
+  adding more to file a
+  
+  -end-
+
+Dump all revlogs to file repo.dump:
+
+  $ find .hg/store -name "*.i" | sort | xargs python $CONTRIBDIR/dumprevlog > ../repo.dump
+  $ cd ..
+
+Undumping into repo-b:
+
+  $ mkdir repo-b
+  $ cd repo-b
+  $ hg init
+  $ python $CONTRIBDIR/undumprevlog < ../repo.dump
+  .hg/store/00changelog.i
+  .hg/store/00manifest.i
+  .hg/store/data/a.i
+  $ cd ..
+
+Rebuild fncache with clone --pull:
+
+  $ hg clone --pull -U repo-b repo-c
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 3 changesets with 3 changes to 1 files
+
+Verify:
+
+  $ hg -R repo-c verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  1 files, 3 changesets, 3 total revisions
+
+Compare repos:
+
+  $ hg -R repo-c incoming repo-a
+  comparing with repo-a
+  searching for changes
+  no changes found
+
+  $ hg -R repo-a incoming repo-c
+  comparing with repo-c
+  searching for changes
+  no changes found
+
+  $ exit 0
+
--- a/tests/test-empty	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,17 +0,0 @@
-#!/bin/sh
-
-hg init a
-cd a
-hg log
-hg grep wah
-hg manifest
-hg verify
-ls .hg
-ls .hg/store
-
-cd ..
-hg clone a b
-cd b
-hg verify
-ls .hg
-ls .hg/store
--- a/tests/test-empty.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,21 +0,0 @@
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-0 files, 0 changesets, 0 total revisions
-00changelog.i
-requires
-store
-updating to branch default
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-0 files, 0 changesets, 0 total revisions
-00changelog.i
-branch
-dirstate
-hgrc
-requires
-store
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-empty.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,52 @@
+Create an empty repo:
+
+  $ hg init a
+  $ cd a
+
+Try some commands:
+
+  $ hg log
+  $ hg grep wah
+  $ hg manifest
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  0 files, 0 changesets, 0 total revisions
+
+Check the basic files created:
+
+  $ ls .hg
+  00changelog.i
+  requires
+  store
+
+Should be empty:
+
+  $ ls .hg/store
+
+Poke at a clone:
+
+  $ cd ..
+  $ hg clone a b
+  updating to branch default
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd b
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  0 files, 0 changesets, 0 total revisions
+  $ ls .hg
+  00changelog.i
+  branch
+  dirstate
+  hgrc
+  requires
+  store
+
+Should be empty:
+
+  $ ls .hg/store
--- a/tests/test-flags	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,50 +0,0 @@
-#!/bin/sh -e
-
-umask 027
-mkdir test1
-cd test1
-
-hg init
-touch a b
-hg add a b
-hg ci -m "added a b" -d "1000000 0"
-
-cd ..
-hg clone test1 test3
-mkdir test2
-cd test2
-
-hg init
-hg pull ../test1
-hg co
-chmod +x a
-hg ci -m "chmod +x a" -d "1000000 0"
-echo % the changelog should mention file a:
-hg tip --template '{files}\n'
-
-cd ../test1
-echo 123 >>a
-hg ci -m "a updated" -d "1000000 0"
-
-hg pull ../test2
-hg heads
-hg history
-
-hg -v merge
-
-cd ../test3
-echo 123 >>b
-hg ci -m "b updated" -d "1000000 0"
-
-hg pull ../test2
-hg heads
-hg history
-
-hg -v merge
-
-ls -l ../test[123]/a > foo
-cut -b 1-10 < foo
-
-hg debugindex .hg/store/data/a.i
-hg debugindex ../test2/.hg/store/data/a.i
-hg debugindex ../test1/.hg/store/data/a.i
--- a/tests/test-flags.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,100 +0,0 @@
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-pulling from ../test1
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-(run 'hg update' to get a working copy)
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-% the changelog should mention file a:
-a
-pulling from ../test2
-searching for changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 0 changes to 0 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-changeset:   2:37dccb76c058
-tag:         tip
-parent:      0:4536b1c2ca69
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     chmod +x a
-
-changeset:   1:a187cb361a5a
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     a updated
-
-changeset:   2:37dccb76c058
-tag:         tip
-parent:      0:4536b1c2ca69
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     chmod +x a
-
-changeset:   1:a187cb361a5a
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     a updated
-
-changeset:   0:4536b1c2ca69
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     added a b
-
-resolving manifests
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-pulling from ../test2
-searching for changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 0 changes to 0 files (+1 heads)
-(run 'hg heads' to see heads, 'hg merge' to merge)
-changeset:   2:37dccb76c058
-tag:         tip
-parent:      0:4536b1c2ca69
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     chmod +x a
-
-changeset:   1:d54568174d8e
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     b updated
-
-changeset:   2:37dccb76c058
-tag:         tip
-parent:      0:4536b1c2ca69
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     chmod +x a
-
-changeset:   1:d54568174d8e
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     b updated
-
-changeset:   0:4536b1c2ca69
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     added a b
-
-resolving manifests
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
--rwxr-x---
--rwxr-x---
--rwxr-x---
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0       0      0       0 b80de5d13875 000000000000 000000000000
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0       0      0       0 b80de5d13875 000000000000 000000000000
-   rev    offset  length   base linkrev nodeid       p1           p2
-     0         0       0      0       0 b80de5d13875 000000000000 000000000000
-     1         0       5      1       1 7fe919cc0336 b80de5d13875 000000000000
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-flags.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,149 @@
+  $ umask 027
+  $ mkdir test1
+  $ cd test1
+
+  $ hg init
+  $ touch a b
+  $ hg add a b
+  $ hg ci -m "added a b" -d "1000000 0"
+
+  $ cd ..
+  $ hg clone test1 test3
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ mkdir test2
+  $ cd test2
+
+  $ hg init
+  $ hg pull ../test1
+  pulling from ../test1
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  (run 'hg update' to get a working copy)
+  $ hg co
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ chmod +x a
+  $ hg ci -m "chmod +x a" -d "1000000 0"
+
+the changelog should mention file a:
+
+  $ hg tip --template '{files}\n'
+  a
+
+  $ cd ../test1
+  $ echo 123 >>a
+  $ hg ci -m "a updated" -d "1000000 0"
+
+  $ hg pull ../test2
+  pulling from ../test2
+  searching for changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 0 changes to 0 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+  $ hg heads
+  changeset:   2:37dccb76c058
+  tag:         tip
+  parent:      0:4536b1c2ca69
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     chmod +x a
+  
+  changeset:   1:a187cb361a5a
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     a updated
+  
+  $ hg history
+  changeset:   2:37dccb76c058
+  tag:         tip
+  parent:      0:4536b1c2ca69
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     chmod +x a
+  
+  changeset:   1:a187cb361a5a
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     a updated
+  
+  changeset:   0:4536b1c2ca69
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     added a b
+  
+
+  $ hg -v merge
+  resolving manifests
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+
+  $ cd ../test3
+  $ echo 123 >>b
+  $ hg ci -m "b updated" -d "1000000 0"
+
+  $ hg pull ../test2
+  pulling from ../test2
+  searching for changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 0 changes to 0 files (+1 heads)
+  (run 'hg heads' to see heads, 'hg merge' to merge)
+  $ hg heads
+  changeset:   2:37dccb76c058
+  tag:         tip
+  parent:      0:4536b1c2ca69
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     chmod +x a
+  
+  changeset:   1:d54568174d8e
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     b updated
+  
+  $ hg history
+  changeset:   2:37dccb76c058
+  tag:         tip
+  parent:      0:4536b1c2ca69
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     chmod +x a
+  
+  changeset:   1:d54568174d8e
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     b updated
+  
+  changeset:   0:4536b1c2ca69
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     added a b
+  
+
+  $ hg -v merge
+  resolving manifests
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+
+  $ ls -l ../test[123]/a > foo
+  $ cut -b 1-10 < foo
+  -rwxr-x---
+  -rwxr-x---
+  -rwxr-x---
+
+  $ hg debugindex .hg/store/data/a.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0       0      0       0 b80de5d13875 000000000000 000000000000
+  $ hg debugindex ../test2/.hg/store/data/a.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0       0      0       0 b80de5d13875 000000000000 000000000000
+  $ hg debugindex ../test1/.hg/store/data/a.i
+     rev    offset  length   base linkrev nodeid       p1           p2
+       0         0       0      0       0 b80de5d13875 000000000000 000000000000
+       1         0       5      1       1 7fe919cc0336 b80de5d13875 000000000000
--- a/tests/test-fncache	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,70 +0,0 @@
-#!/bin/sh
-
-echo "% init repo1"
-hg init repo1
-cd repo1
-
-echo
-echo "% add a; ci"
-echo "some text" > a
-hg add
-hg ci -m first
-
-echo
-echo "% cat .hg/store/fncache"
-cat .hg/store/fncache
-
-echo
-echo "% add a.i/b; ci"
-mkdir a.i
-echo "some other text" > a.i/b
-hg add
-hg ci -m second
-
-echo
-echo "% cat .hg/store/fncache"
-cat .hg/store/fncache
-
-echo
-echo "% add a.i.hg/c; ci"
-mkdir a.i.hg
-echo "yet another text" > a.i.hg/c
-hg add
-hg ci -m third
-
-echo
-echo "% cat .hg/store/fncache"
-cat .hg/store/fncache
-
-echo
-echo "% hg verify"
-hg verify
-
-echo
-echo "% rm .hg/store/fncache"
-rm .hg/store/fncache
-
-echo
-echo "% hg verify"
-hg verify
-
-# try non store repo encoding
-cd ..
-echo % non store repo
-hg --config format.usestore=False init foo
-cd foo
-mkdir tst.d
-echo foo > tst.d/foo
-hg ci -Amfoo
-find .hg | sort
-
-cd ..
-echo % non fncache repo
-hg --config format.usefncache=False init bar
-cd bar
-mkdir tst.d
-echo foo > tst.d/Foo
-hg ci -Amfoo
-find .hg | sort
-
-exit 0
--- a/tests/test-fncache.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,75 +0,0 @@
-% init repo1
-
-% add a; ci
-adding a
-
-% cat .hg/store/fncache
-data/a.i
-
-% add a.i/b; ci
-adding a.i/b
-
-% cat .hg/store/fncache
-data/a.i
-data/a.i.hg/b.i
-
-% add a.i.hg/c; ci
-adding a.i.hg/c
-
-% cat .hg/store/fncache
-data/a.i
-data/a.i.hg/b.i
-data/a.i.hg.hg/c.i
-
-% hg verify
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-3 files, 3 changesets, 3 total revisions
-
-% rm .hg/store/fncache
-
-% hg verify
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
- data/a.i@0: missing revlog!
- data/a.i.hg/c.i@2: missing revlog!
- data/a.i/b.i@1: missing revlog!
-3 files, 3 changesets, 3 total revisions
-3 integrity errors encountered!
-(first damaged changeset appears to be 0)
-% non store repo
-adding tst.d/foo
-.hg
-.hg/00changelog.i
-.hg/00manifest.i
-.hg/data
-.hg/data/tst.d.hg
-.hg/data/tst.d.hg/foo.i
-.hg/dirstate
-.hg/last-message.txt
-.hg/requires
-.hg/undo
-.hg/undo.branch
-.hg/undo.desc
-.hg/undo.dirstate
-% non fncache repo
-adding tst.d/Foo
-.hg
-.hg/00changelog.i
-.hg/dirstate
-.hg/last-message.txt
-.hg/requires
-.hg/store
-.hg/store/00changelog.i
-.hg/store/00manifest.i
-.hg/store/data
-.hg/store/data/tst.d.hg
-.hg/store/data/tst.d.hg/_foo.i
-.hg/store/undo
-.hg/undo.branch
-.hg/undo.desc
-.hg/undo.dirstate
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-fncache.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,108 @@
+Init repo1:
+
+  $ hg init repo1
+  $ cd repo1
+  $ echo "some text" > a
+  $ hg add
+  adding a
+  $ hg ci -m first
+  $ cat .hg/store/fncache
+  data/a.i
+
+Testing a.i/b:
+
+  $ mkdir a.i
+  $ echo "some other text" > a.i/b
+  $ hg add
+  adding a.i/b
+  $ hg ci -m second
+  $ cat .hg/store/fncache
+  data/a.i
+  data/a.i.hg/b.i
+
+Testing a.i.hg/c:
+
+  $ mkdir a.i.hg
+  $ echo "yet another text" > a.i.hg/c
+  $ hg add
+  adding a.i.hg/c
+  $ hg ci -m third
+  $ cat .hg/store/fncache
+  data/a.i
+  data/a.i.hg/b.i
+  data/a.i.hg.hg/c.i
+
+Testing verify:
+
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  3 files, 3 changesets, 3 total revisions
+
+  $ rm .hg/store/fncache
+
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+   data/a.i@0: missing revlog!
+   data/a.i.hg/c.i@2: missing revlog!
+   data/a.i/b.i@1: missing revlog!
+  3 files, 3 changesets, 3 total revisions
+  3 integrity errors encountered!
+  (first damaged changeset appears to be 0)
+  $ cd ..
+
+Non store repo:
+
+  $ hg --config format.usestore=False init foo
+  $ cd foo
+  $ mkdir tst.d
+  $ echo foo > tst.d/foo
+  $ hg ci -Amfoo
+  adding tst.d/foo
+  $ find .hg | sort
+  .hg
+  .hg/00changelog.i
+  .hg/00manifest.i
+  .hg/data
+  .hg/data/tst.d.hg
+  .hg/data/tst.d.hg/foo.i
+  .hg/dirstate
+  .hg/last-message.txt
+  .hg/requires
+  .hg/undo
+  .hg/undo.branch
+  .hg/undo.desc
+  .hg/undo.dirstate
+  $ cd ..
+
+Non fncache repo:
+
+  $ hg --config format.usefncache=False init bar
+  $ cd bar
+  $ mkdir tst.d
+  $ echo foo > tst.d/Foo
+  $ hg ci -Amfoo
+  adding tst.d/Foo
+  $ find .hg | sort
+  .hg
+  .hg/00changelog.i
+  .hg/dirstate
+  .hg/last-message.txt
+  .hg/requires
+  .hg/store
+  .hg/store/00changelog.i
+  .hg/store/00manifest.i
+  .hg/store/data
+  .hg/store/data/tst.d.hg
+  .hg/store/data/tst.d.hg/_foo.i
+  .hg/store/undo
+  .hg/undo.branch
+  .hg/undo.desc
+  .hg/undo.dirstate
+  $ cd ..
+
--- a/tests/test-gendoc.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-gendoc.out	Sat Aug 14 03:30:35 2010 +0200
@@ -23,6 +23,9 @@
 % extracting documentation from pt_BR
 checking for parse errors
 
+% extracting documentation from ro
+checking for parse errors
+
 % extracting documentation from sv
 checking for parse errors
 
--- a/tests/test-hgweb-commands	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-hgweb-commands	Sat Aug 14 03:30:35 2010 +0200
@@ -46,11 +46,11 @@
 echo % heads
 "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '?cmd=heads'
 echo % lookup
-"$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '?cmd=lookup&node=1'
+"$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '?cmd=lookup&key=1'
 echo % branches
-"$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '?cmd=branches'
+"$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '?cmd=branches&nodes=0000000000000000000000000000000000000000'
 echo % changegroup
-"$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '?cmd=changegroup' \
+"$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '?cmd=changegroup&roots=0000000000000000000000000000000000000000' \
     | $TESTDIR/printrepr.py
 echo % stream_out
 "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '?cmd=stream_out'
--- a/tests/test-hgweb-commands.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-hgweb-commands.out	Sat Aug 14 03:30:35 2010 +0200
@@ -852,11 +852,11 @@
 % lookup
 200 Script output follows
 
-0 'key'
+1 a4f92ed23982be056b9852de5dfe873eaac7f0de
 % branches
 200 Script output follows
 
-1d22e65f027e5a0609357e7d8e7508cd2ba5d2fe 2ef0ac749a14e4f57a5a822464a0902c6f7f448f 0000000000000000000000000000000000000000 0000000000000000000000000000000000000000
+0000000000000000000000000000000000000000 0000000000000000000000000000000000000000 0000000000000000000000000000000000000000 0000000000000000000000000000000000000000
 % changegroup
 200 Script output follows
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-hgweb-raw	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,23 @@
+#!/bin/sh
+
+hg init test
+cd test
+mkdir sub
+cat >'sub/some "text".txt' <<ENDSOME
+This is just some random text
+that will go inside the file and take a few lines.
+It is very boring to read, but computers don't
+care about things like that.
+ENDSOME
+hg add 'sub/some "text".txt'
+hg commit -d "1 0" -m "Just some text"
+hg serve -p $HGPORT -A access.log -E error.log -d --pid-file=hg.pid
+cat hg.pid >> $DAEMON_PIDS
+("$TESTDIR/get-with-headers.py" localhost:$HGPORT '/?f=a23bf1310f6e;file=sub/some%20%22text%22.txt;style=raw' content-type content-length content-disposition) >getoutput.txt &
+
+sleep 5
+kill `cat hg.pid`
+sleep 1 # wait for server to scream and die
+cat getoutput.txt
+cat access.log error.log | \
+  sed 's/^[^ ]*\( [^[]*\[\)[^]]*\(\].*\)$/host\1date\2/'
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-hgweb-raw.out	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,10 @@
+200 Script output follows
+content-type: text/plain; charset="ascii"
+content-length: 157
+content-disposition: inline; filename="some \"text\".txt"
+
+This is just some random text
+that will go inside the file and take a few lines.
+It is very boring to read, but computers don't
+care about things like that.
+host - - [date] "GET /?f=a23bf1310f6e;file=sub/some%20%22text%22.txt;style=raw HTTP/1.1" 200 -
--- a/tests/test-hook	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,273 +0,0 @@
-#!/bin/sh
-
-cp "$TESTDIR"/printenv.py .
-
-# commit hooks can see env vars
-hg init a
-cd a
-echo "[hooks]" > .hg/hgrc
-echo 'commit = unset HG_LOCAL HG_TAG; python ../printenv.py commit' >> .hg/hgrc
-echo 'commit.b = unset HG_LOCAL HG_TAG; python ../printenv.py commit.b' >> .hg/hgrc
-echo 'precommit = unset HG_LOCAL HG_NODE HG_TAG; python ../printenv.py precommit' >> .hg/hgrc
-echo 'pretxncommit = unset HG_LOCAL HG_TAG; python ../printenv.py pretxncommit' >> .hg/hgrc
-echo 'pretxncommit.tip = hg -q tip' >> .hg/hgrc
-echo 'pre-identify = python ../printenv.py pre-identify 1' >> .hg/hgrc
-echo 'pre-cat = python ../printenv.py pre-cat' >> .hg/hgrc
-echo 'post-cat = python ../printenv.py post-cat' >> .hg/hgrc
-echo a > a
-hg add a
-hg commit -m a -d "1000000 0"
-
-hg clone . ../b
-cd ../b
-
-# changegroup hooks can see env vars
-echo '[hooks]' > .hg/hgrc
-echo 'prechangegroup = python ../printenv.py prechangegroup' >> .hg/hgrc
-echo 'changegroup = python ../printenv.py changegroup' >> .hg/hgrc
-echo 'incoming = python ../printenv.py incoming' >> .hg/hgrc
-
-# pretxncommit and commit hooks can see both parents of merge
-cd ../a
-echo b >> a
-hg commit -m a1 -d "1 0"
-hg update -C 0
-echo b > b
-hg add b
-hg commit -m b -d '1 0'
-hg merge 1
-hg commit -m merge -d '2 0'
-
-# test generic hooks
-hg id
-hg cat b
-
-cd ../b
-hg pull ../a
-
-# tag hooks can see env vars
-cd ../a
-echo 'pretag = python ../printenv.py pretag' >> .hg/hgrc
-echo 'tag = unset HG_PARENT1 HG_PARENT2; python ../printenv.py tag' >> .hg/hgrc
-hg tag -d '3 0' a
-hg tag -l la
-
-# pretag hook can forbid tagging
-echo 'pretag.forbid = python ../printenv.py pretag.forbid 1' >> .hg/hgrc
-hg tag -d '4 0' fa
-hg tag -l fla
-
-# pretxncommit hook can see changeset, can roll back txn, changeset
-# no more there after
-echo 'pretxncommit.forbid0 = hg tip -q' >> .hg/hgrc
-echo 'pretxncommit.forbid1 = python ../printenv.py pretxncommit.forbid 1' >> .hg/hgrc
-echo z > z
-hg add z
-hg -q tip
-hg commit -m 'fail' -d '4 0'
-hg -q tip
-
-# precommit hook can prevent commit
-echo 'precommit.forbid = python ../printenv.py precommit.forbid 1' >> .hg/hgrc
-hg commit -m 'fail' -d '4 0'
-hg -q tip
-
-# preupdate hook can prevent update
-echo 'preupdate = python ../printenv.py preupdate' >> .hg/hgrc
-hg update 1
-
-# update hook
-echo 'update = python ../printenv.py update' >> .hg/hgrc
-hg update
-
-# prechangegroup hook can prevent incoming changes
-cd ../b
-hg -q tip
-echo '[hooks]' > .hg/hgrc
-echo 'prechangegroup.forbid = python ../printenv.py prechangegroup.forbid 1' >> .hg/hgrc
-hg pull ../a
-
-# pretxnchangegroup hook can see incoming changes, can roll back txn,
-# incoming changes no longer there after
-echo '[hooks]' > .hg/hgrc
-echo 'pretxnchangegroup.forbid0 = hg tip -q' >> .hg/hgrc
-echo 'pretxnchangegroup.forbid1 = python ../printenv.py pretxnchangegroup.forbid 1' >> .hg/hgrc
-hg pull ../a
-hg -q tip
-
-# outgoing hooks can see env vars
-rm .hg/hgrc
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing = python ../printenv.py preoutgoing' >> ../a/.hg/hgrc
-echo 'outgoing = python ../printenv.py outgoing' >> ../a/.hg/hgrc
-hg pull ../a
-hg rollback
-
-# preoutgoing hook can prevent outgoing changes
-echo 'preoutgoing.forbid = python ../printenv.py preoutgoing.forbid 1' >> ../a/.hg/hgrc
-hg pull ../a
-
-# outgoing hooks work for local clones
-cd ..
-echo '[hooks]' > a/.hg/hgrc
-echo 'preoutgoing = python ../printenv.py preoutgoing' >> a/.hg/hgrc
-echo 'outgoing = python ../printenv.py outgoing' >> a/.hg/hgrc
-hg clone a c
-rm -rf c
-
-# preoutgoing hook can prevent outgoing changes for local clones
-echo 'preoutgoing.forbid = python ../printenv.py preoutgoing.forbid 1' >> a/.hg/hgrc
-hg clone a zzz
-cd b
-
-cat > hooktests.py <<EOF
-from mercurial import util
-
-uncallable = 0
-
-def printargs(args):
-    args.pop('ui', None)
-    args.pop('repo', None)
-    a = list(args.items())
-    a.sort()
-    print 'hook args:'
-    for k, v in a:
-       print ' ', k, v
-
-def passhook(**args):
-    printargs(args)
-
-def failhook(**args):
-    printargs(args)
-    return True
-
-class LocalException(Exception):
-    pass
-
-def raisehook(**args):
-    raise LocalException('exception from hook')
-
-def aborthook(**args):
-    raise util.Abort('raise abort from hook')
-
-def brokenhook(**args):
-    return 1 + {}
-
-class container:
-    unreachable = 1
-EOF
-
-echo '# test python hooks'
-PYTHONPATH="`pwd`:$PYTHONPATH"
-export PYTHONPATH
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.broken = python:hooktests.brokenhook' >> ../a/.hg/hgrc
-hg pull ../a 2>&1 | grep 'raised an exception'
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.raise = python:hooktests.raisehook' >> ../a/.hg/hgrc
-hg pull ../a 2>&1 | grep 'raised an exception'
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.abort = python:hooktests.aborthook' >> ../a/.hg/hgrc
-hg pull ../a
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.fail = python:hooktests.failhook' >> ../a/.hg/hgrc
-hg pull ../a
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.uncallable = python:hooktests.uncallable' >> ../a/.hg/hgrc
-hg pull ../a
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.nohook = python:hooktests.nohook' >> ../a/.hg/hgrc
-hg pull ../a
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.nomodule = python:nomodule' >> ../a/.hg/hgrc
-hg pull ../a
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.badmodule = python:nomodule.nowhere' >> ../a/.hg/hgrc
-hg pull ../a
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.unreachable = python:hooktests.container.unreachable' >> ../a/.hg/hgrc
-hg pull ../a
-
-echo '[hooks]' > ../a/.hg/hgrc
-echo 'preoutgoing.pass = python:hooktests.passhook' >> ../a/.hg/hgrc
-hg pull ../a
-
-echo '# make sure --traceback works'
-echo '[hooks]' > .hg/hgrc
-echo 'commit.abort = python:hooktests.aborthook' >> .hg/hgrc
-
-echo aa > a
-hg --traceback commit -d '0 0' -ma 2>&1 | grep '^Traceback'
-
-cd ..
-hg init c
-cd c
-
-cat > hookext.py <<EOF
-def autohook(**args):
-    print "Automatically installed hook"
-
-def reposetup(ui, repo):
-    repo.ui.setconfig("hooks", "commit.auto", autohook)
-EOF
-echo '[extensions]' >> .hg/hgrc
-echo 'hookext = hookext.py' >> .hg/hgrc
-
-touch foo
-hg add foo
-hg ci -d '0 0' -m 'add foo'
-echo >> foo
-hg ci --debug -d '0 0' -m 'change foo' | sed -e 's/ at .*>/>/'
-
-hg showconfig hooks | sed -e 's/ at .*>/>/'
-
-echo '# test python hook configured with python:[file]:[hook] syntax'
-cd ..
-mkdir d
-cd d
-hg init repo
-mkdir hooks
-
-cd hooks
-cat > testhooks.py <<EOF
-def testhook(**args):
-    print 'hook works'
-EOF
-echo '[hooks]' > ../repo/.hg/hgrc
-echo "pre-commit.test = python:`pwd`/testhooks.py:testhook" >> ../repo/.hg/hgrc
-
-cd ../repo
-hg commit -d '0 0'
-
-cd ../../b
-echo '# make sure --traceback works on hook import failure'
-cat > importfail.py <<EOF
-import somebogusmodule
-# dereference something in the module to force demandimport to load it
-somebogusmodule.whatever
-EOF
-
-echo '[hooks]' > .hg/hgrc
-echo 'precommit.importfail = python:importfail.whatever' >> .hg/hgrc
-
-echo a >> a
-hg --traceback commit -d '0 0' -ma 2>&1 | egrep '^(exception|Traceback|ImportError)'
-
-echo '# commit and update hooks should run after command completion (issue 1827)'
-echo '[hooks]' > .hg/hgrc
-echo 'commit = hg id' >> .hg/hgrc
-echo 'update = hg id' >> .hg/hgrc
-echo bb > a
-hg ci -d '0 0' -ma
-hg up 0
-
-exit 0
--- a/tests/test-hook.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,177 +0,0 @@
-precommit hook: HG_PARENT1=0000000000000000000000000000000000000000 
-pretxncommit hook: HG_NODE=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PARENT1=0000000000000000000000000000000000000000 HG_PENDING=$HGTMP/test-hook/a 
-0:29b62aeb769f
-commit hook: HG_NODE=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PARENT1=0000000000000000000000000000000000000000 
-commit.b hook: HG_NODE=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PARENT1=0000000000000000000000000000000000000000 
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-precommit hook: HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
-pretxncommit hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PENDING=$HGTMP/test-hook/a 
-1:b702efe96888
-commit hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
-commit.b hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-precommit hook: HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
-pretxncommit hook: HG_NODE=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PENDING=$HGTMP/test-hook/a 
-2:1324a5531bac
-commit hook: HG_NODE=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
-commit.b hook: HG_NODE=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
-created new head
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-precommit hook: HG_PARENT1=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT2=b702efe9688826e3a91283852b328b84dbf37bc2 
-pretxncommit hook: HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_PARENT1=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT2=b702efe9688826e3a91283852b328b84dbf37bc2 HG_PENDING=$HGTMP/test-hook/a 
-3:4c52fb2e4022
-commit hook: HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_PARENT1=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT2=b702efe9688826e3a91283852b328b84dbf37bc2 
-commit.b hook: HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_PARENT1=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT2=b702efe9688826e3a91283852b328b84dbf37bc2 
-pre-identify hook: HG_ARGS=id HG_OPTS={'tags': None, 'rev': '', 'num': None, 'branch': None, 'id': None} HG_PATS=[] 
-warning: pre-identify hook exited with status 1
-pre-cat hook: HG_ARGS=cat b HG_OPTS={'rev': '', 'decode': None, 'exclude': [], 'output': '', 'include': []} HG_PATS=['b'] 
-post-cat hook: HG_ARGS=cat b HG_OPTS={'rev': '', 'decode': None, 'exclude': [], 'output': '', 'include': []} HG_PATS=['b'] HG_RESULT=0 
-b
-prechangegroup hook: HG_SOURCE=pull HG_URL=file: 
-changegroup hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_SOURCE=pull HG_URL=file: 
-incoming hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_SOURCE=pull HG_URL=file: 
-incoming hook: HG_NODE=1324a5531bac09b329c3845d35ae6a7526874edb HG_SOURCE=pull HG_URL=file: 
-incoming hook: HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_SOURCE=pull HG_URL=file: 
-pulling from ../a
-searching for changes
-adding changesets
-adding manifests
-adding file changes
-added 3 changesets with 2 changes to 2 files
-(run 'hg update' to get a working copy)
-pretag hook: HG_LOCAL=0 HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_TAG=a 
-precommit hook: HG_PARENT1=4c52fb2e402287dd5dc052090682536c8406c321 
-pretxncommit hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PARENT1=4c52fb2e402287dd5dc052090682536c8406c321 HG_PENDING=$HGTMP/test-hook/a 
-4:8ea2ef7ad3e8
-commit hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PARENT1=4c52fb2e402287dd5dc052090682536c8406c321 
-commit.b hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PARENT1=4c52fb2e402287dd5dc052090682536c8406c321 
-tag hook: HG_LOCAL=0 HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_TAG=a 
-pretag hook: HG_LOCAL=1 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=la 
-tag hook: HG_LOCAL=1 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=la 
-pretag hook: HG_LOCAL=0 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=fa 
-pretag.forbid hook: HG_LOCAL=0 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=fa 
-abort: pretag.forbid hook exited with status 1
-pretag hook: HG_LOCAL=1 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=fla 
-pretag.forbid hook: HG_LOCAL=1 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=fla 
-abort: pretag.forbid hook exited with status 1
-4:8ea2ef7ad3e8
-precommit hook: HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 
-pretxncommit hook: HG_NODE=fad284daf8c032148abaffcd745dafeceefceb61 HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PENDING=$HGTMP/test-hook/a 
-5:fad284daf8c0
-5:fad284daf8c0
-pretxncommit.forbid hook: HG_NODE=fad284daf8c032148abaffcd745dafeceefceb61 HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PENDING=$HGTMP/test-hook/a 
-transaction abort!
-rollback completed
-abort: pretxncommit.forbid1 hook exited with status 1
-4:8ea2ef7ad3e8
-precommit hook: HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 
-precommit.forbid hook: HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 
-abort: precommit.forbid hook exited with status 1
-4:8ea2ef7ad3e8
-preupdate hook: HG_PARENT1=b702efe96888 
-0 files updated, 0 files merged, 2 files removed, 0 files unresolved
-preupdate hook: HG_PARENT1=8ea2ef7ad3e8 
-update hook: HG_ERROR=0 HG_PARENT1=8ea2ef7ad3e8 
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-3:4c52fb2e4022
-prechangegroup.forbid hook: HG_SOURCE=pull HG_URL=file: 
-pulling from ../a
-searching for changes
-abort: prechangegroup.forbid hook exited with status 1
-4:8ea2ef7ad3e8
-pretxnchangegroup.forbid hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PENDING=$HGTMP/test-hook/b HG_SOURCE=pull HG_URL=file: 
-pulling from ../a
-searching for changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-transaction abort!
-rollback completed
-abort: pretxnchangegroup.forbid1 hook exited with status 1
-3:4c52fb2e4022
-preoutgoing hook: HG_SOURCE=pull 
-outgoing hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_SOURCE=pull 
-pulling from ../a
-searching for changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-(run 'hg update' to get a working copy)
-rolling back to revision 3 (undo pull)
-preoutgoing hook: HG_SOURCE=pull 
-preoutgoing.forbid hook: HG_SOURCE=pull 
-pulling from ../a
-searching for changes
-abort: preoutgoing.forbid hook exited with status 1
-preoutgoing hook: HG_SOURCE=clone 
-outgoing hook: HG_NODE=0000000000000000000000000000000000000000 HG_SOURCE=clone 
-updating to branch default
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
-preoutgoing hook: HG_SOURCE=clone 
-preoutgoing.forbid hook: HG_SOURCE=clone 
-abort: preoutgoing.forbid hook exited with status 1
-# test python hooks
-error: preoutgoing.broken hook raised an exception: unsupported operand type(s) for +: 'int' and 'dict'
-error: preoutgoing.raise hook raised an exception: exception from hook
-pulling from ../a
-searching for changes
-error: preoutgoing.abort hook failed: raise abort from hook
-abort: raise abort from hook
-pulling from ../a
-searching for changes
-hook args:
-  hooktype preoutgoing
-  source pull
-abort: preoutgoing.fail hook failed
-pulling from ../a
-searching for changes
-abort: preoutgoing.uncallable hook is invalid ("hooktests.uncallable" is not callable)
-pulling from ../a
-searching for changes
-abort: preoutgoing.nohook hook is invalid ("hooktests.nohook" is not defined)
-pulling from ../a
-searching for changes
-abort: preoutgoing.nomodule hook is invalid ("nomodule" not in a module)
-pulling from ../a
-searching for changes
-abort: preoutgoing.badmodule hook is invalid (import of "nomodule" failed)
-pulling from ../a
-searching for changes
-abort: preoutgoing.unreachable hook is invalid (import of "hooktests.container" failed)
-pulling from ../a
-searching for changes
-hook args:
-  hooktype preoutgoing
-  source pull
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-(run 'hg update' to get a working copy)
-# make sure --traceback works
-Traceback (most recent call last):
-Automatically installed hook
-foo
-calling hook commit.auto: <function autohook>
-Automatically installed hook
-committed changeset 1:52998019f6252a2b893452765fcb0a47351a5708
-hooks.commit.auto=<function autohook>
-# test python hook configured with python:[file]:[hook] syntax
-hook works
-nothing changed
-# make sure --traceback works on hook import failure
-exception from first failed import attempt:
-Traceback (most recent call last):
-ImportError: No module named somebogusmodule
-exception from second failed import attempt:
-Traceback (most recent call last):
-ImportError: No module named hgext_importfail
-Traceback (most recent call last):
-# commit and update hooks should run after command completion (issue 1827)
-8da618c33484 tip
-29b62aeb769f
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-hook.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,465 @@
+  $ cp "$TESTDIR"/printenv.py .
+
+# commit hooks can see env vars
+
+  $ hg init a
+  $ cd a
+  $ echo "[hooks]" > .hg/hgrc
+  $ echo 'commit = unset HG_LOCAL HG_TAG; python ../printenv.py commit' >> .hg/hgrc
+  $ echo 'commit.b = unset HG_LOCAL HG_TAG; python ../printenv.py commit.b' >> .hg/hgrc
+  $ echo 'precommit = unset HG_LOCAL HG_NODE HG_TAG; python ../printenv.py precommit' >> .hg/hgrc
+  $ echo 'pretxncommit = unset HG_LOCAL HG_TAG; python ../printenv.py pretxncommit' >> .hg/hgrc
+  $ echo 'pretxncommit.tip = hg -q tip' >> .hg/hgrc
+  $ echo 'pre-identify = python ../printenv.py pre-identify 1' >> .hg/hgrc
+  $ echo 'pre-cat = python ../printenv.py pre-cat' >> .hg/hgrc
+  $ echo 'post-cat = python ../printenv.py post-cat' >> .hg/hgrc
+  $ echo a > a
+  $ hg add a
+  $ hg commit -m a -d "1000000 0"
+  precommit hook: HG_PARENT1=0000000000000000000000000000000000000000 
+  pretxncommit hook: HG_NODE=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PARENT1=0000000000000000000000000000000000000000 HG_PENDING=$HGTMP/test-hook.t/a 
+  0:29b62aeb769f
+  commit hook: HG_NODE=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PARENT1=0000000000000000000000000000000000000000 
+  commit.b hook: HG_NODE=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PARENT1=0000000000000000000000000000000000000000 
+
+  $ hg clone . ../b
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd ../b
+
+# changegroup hooks can see env vars
+
+  $ echo '[hooks]' > .hg/hgrc
+  $ echo 'prechangegroup = python ../printenv.py prechangegroup' >> .hg/hgrc
+  $ echo 'changegroup = python ../printenv.py changegroup' >> .hg/hgrc
+  $ echo 'incoming = python ../printenv.py incoming' >> .hg/hgrc
+
+# pretxncommit and commit hooks can see both parents of merge
+
+  $ cd ../a
+  $ echo b >> a
+  $ hg commit -m a1 -d "1 0"
+  precommit hook: HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
+  pretxncommit hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PENDING=$HGTMP/test-hook.t/a 
+  1:b702efe96888
+  commit hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
+  commit.b hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
+  $ hg update -C 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo b > b
+  $ hg add b
+  $ hg commit -m b -d '1 0'
+  precommit hook: HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
+  pretxncommit hook: HG_NODE=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b HG_PENDING=$HGTMP/test-hook.t/a 
+  2:1324a5531bac
+  commit hook: HG_NODE=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
+  commit.b hook: HG_NODE=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT1=29b62aeb769fdf78d8d9c5f28b017f76d7ef824b 
+  created new head
+  $ hg merge 1
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg commit -m merge -d '2 0'
+  precommit hook: HG_PARENT1=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT2=b702efe9688826e3a91283852b328b84dbf37bc2 
+  pretxncommit hook: HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_PARENT1=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT2=b702efe9688826e3a91283852b328b84dbf37bc2 HG_PENDING=$HGTMP/test-hook.t/a 
+  3:4c52fb2e4022
+  commit hook: HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_PARENT1=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT2=b702efe9688826e3a91283852b328b84dbf37bc2 
+  commit.b hook: HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_PARENT1=1324a5531bac09b329c3845d35ae6a7526874edb HG_PARENT2=b702efe9688826e3a91283852b328b84dbf37bc2 
+
+# test generic hooks
+
+  $ hg id
+  pre-identify hook: HG_ARGS=id HG_OPTS={'tags': None, 'rev': '', 'num': None, 'branch': None, 'id': None} HG_PATS=[] 
+  warning: pre-identify hook exited with status 1
+  $ hg cat b
+  pre-cat hook: HG_ARGS=cat b HG_OPTS={'rev': '', 'decode': None, 'exclude': [], 'output': '', 'include': []} HG_PATS=['b'] 
+  post-cat hook: HG_ARGS=cat b HG_OPTS={'rev': '', 'decode': None, 'exclude': [], 'output': '', 'include': []} HG_PATS=['b'] HG_RESULT=0 
+  b
+
+  $ cd ../b
+  $ hg pull ../a
+  prechangegroup hook: HG_SOURCE=pull HG_URL=file: 
+  changegroup hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_SOURCE=pull HG_URL=file: 
+  incoming hook: HG_NODE=b702efe9688826e3a91283852b328b84dbf37bc2 HG_SOURCE=pull HG_URL=file: 
+  incoming hook: HG_NODE=1324a5531bac09b329c3845d35ae6a7526874edb HG_SOURCE=pull HG_URL=file: 
+  incoming hook: HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_SOURCE=pull HG_URL=file: 
+  pulling from ../a
+  searching for changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 3 changesets with 2 changes to 2 files
+  (run 'hg update' to get a working copy)
+
+# tag hooks can see env vars
+
+  $ cd ../a
+  $ echo 'pretag = python ../printenv.py pretag' >> .hg/hgrc
+  $ echo 'tag = unset HG_PARENT1 HG_PARENT2; python ../printenv.py tag' >> .hg/hgrc
+  $ hg tag -d '3 0' a
+  pretag hook: HG_LOCAL=0 HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_TAG=a 
+  precommit hook: HG_PARENT1=4c52fb2e402287dd5dc052090682536c8406c321 
+  pretxncommit hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PARENT1=4c52fb2e402287dd5dc052090682536c8406c321 HG_PENDING=$HGTMP/test-hook.t/a 
+  4:8ea2ef7ad3e8
+  commit hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PARENT1=4c52fb2e402287dd5dc052090682536c8406c321 
+  commit.b hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PARENT1=4c52fb2e402287dd5dc052090682536c8406c321 
+  tag hook: HG_LOCAL=0 HG_NODE=4c52fb2e402287dd5dc052090682536c8406c321 HG_TAG=a 
+  $ hg tag -l la
+  pretag hook: HG_LOCAL=1 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=la 
+  tag hook: HG_LOCAL=1 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=la 
+
+# pretag hook can forbid tagging
+
+  $ echo 'pretag.forbid = python ../printenv.py pretag.forbid 1' >> .hg/hgrc
+  $ hg tag -d '4 0' fa
+  pretag hook: HG_LOCAL=0 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=fa 
+  pretag.forbid hook: HG_LOCAL=0 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=fa 
+  abort: pretag.forbid hook exited with status 1
+  $ hg tag -l fla
+  pretag hook: HG_LOCAL=1 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=fla 
+  pretag.forbid hook: HG_LOCAL=1 HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_TAG=fla 
+  abort: pretag.forbid hook exited with status 1
+
+# pretxncommit hook can see changeset, can roll back txn, changeset
+# no more there after
+
+  $ echo 'pretxncommit.forbid0 = hg tip -q' >> .hg/hgrc
+  $ echo 'pretxncommit.forbid1 = python ../printenv.py pretxncommit.forbid 1' >> .hg/hgrc
+  $ echo z > z
+  $ hg add z
+  $ hg -q tip
+  4:8ea2ef7ad3e8
+  $ hg commit -m 'fail' -d '4 0'
+  precommit hook: HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 
+  pretxncommit hook: HG_NODE=fad284daf8c032148abaffcd745dafeceefceb61 HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PENDING=$HGTMP/test-hook.t/a 
+  5:fad284daf8c0
+  5:fad284daf8c0
+  pretxncommit.forbid hook: HG_NODE=fad284daf8c032148abaffcd745dafeceefceb61 HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PENDING=$HGTMP/test-hook.t/a 
+  transaction abort!
+  rollback completed
+  abort: pretxncommit.forbid1 hook exited with status 1
+  $ hg -q tip
+  4:8ea2ef7ad3e8
+
+# precommit hook can prevent commit
+
+  $ echo 'precommit.forbid = python ../printenv.py precommit.forbid 1' >> .hg/hgrc
+  $ hg commit -m 'fail' -d '4 0'
+  precommit hook: HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 
+  precommit.forbid hook: HG_PARENT1=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 
+  abort: precommit.forbid hook exited with status 1
+  $ hg -q tip
+  4:8ea2ef7ad3e8
+
+# preupdate hook can prevent update
+
+  $ echo 'preupdate = python ../printenv.py preupdate' >> .hg/hgrc
+  $ hg update 1
+  preupdate hook: HG_PARENT1=b702efe96888 
+  0 files updated, 0 files merged, 2 files removed, 0 files unresolved
+
+# update hook
+
+  $ echo 'update = python ../printenv.py update' >> .hg/hgrc
+  $ hg update
+  preupdate hook: HG_PARENT1=8ea2ef7ad3e8 
+  update hook: HG_ERROR=0 HG_PARENT1=8ea2ef7ad3e8 
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+# prechangegroup hook can prevent incoming changes
+
+  $ cd ../b
+  $ hg -q tip
+  3:4c52fb2e4022
+  $ echo '[hooks]' > .hg/hgrc
+  $ echo 'prechangegroup.forbid = python ../printenv.py prechangegroup.forbid 1' >> .hg/hgrc
+  $ hg pull ../a
+  prechangegroup.forbid hook: HG_SOURCE=pull HG_URL=file: 
+  pulling from ../a
+  searching for changes
+  abort: prechangegroup.forbid hook exited with status 1
+
+# pretxnchangegroup hook can see incoming changes, can roll back txn,
+# incoming changes no longer there after
+
+  $ echo '[hooks]' > .hg/hgrc
+  $ echo 'pretxnchangegroup.forbid0 = hg tip -q' >> .hg/hgrc
+  $ echo 'pretxnchangegroup.forbid1 = python ../printenv.py pretxnchangegroup.forbid 1' >> .hg/hgrc
+  $ hg pull ../a
+  4:8ea2ef7ad3e8
+  pretxnchangegroup.forbid hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_PENDING=$HGTMP/test-hook.t/b HG_SOURCE=pull HG_URL=file: 
+  pulling from ../a
+  searching for changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  transaction abort!
+  rollback completed
+  abort: pretxnchangegroup.forbid1 hook exited with status 1
+  $ hg -q tip
+  3:4c52fb2e4022
+
+# outgoing hooks can see env vars
+
+  $ rm .hg/hgrc
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing = python ../printenv.py preoutgoing' >> ../a/.hg/hgrc
+  $ echo 'outgoing = python ../printenv.py outgoing' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  preoutgoing hook: HG_SOURCE=pull 
+  outgoing hook: HG_NODE=8ea2ef7ad3e8cac946c72f1e0c79d6aebc301198 HG_SOURCE=pull 
+  pulling from ../a
+  searching for changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  (run 'hg update' to get a working copy)
+  $ hg rollback
+  rolling back to revision 3 (undo pull)
+
+# preoutgoing hook can prevent outgoing changes
+
+  $ echo 'preoutgoing.forbid = python ../printenv.py preoutgoing.forbid 1' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  preoutgoing hook: HG_SOURCE=pull 
+  preoutgoing.forbid hook: HG_SOURCE=pull 
+  pulling from ../a
+  searching for changes
+  abort: preoutgoing.forbid hook exited with status 1
+
+# outgoing hooks work for local clones
+
+  $ cd ..
+  $ echo '[hooks]' > a/.hg/hgrc
+  $ echo 'preoutgoing = python ../printenv.py preoutgoing' >> a/.hg/hgrc
+  $ echo 'outgoing = python ../printenv.py outgoing' >> a/.hg/hgrc
+  $ hg clone a c
+  preoutgoing hook: HG_SOURCE=clone 
+  outgoing hook: HG_NODE=0000000000000000000000000000000000000000 HG_SOURCE=clone 
+  updating to branch default
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ rm -rf c
+
+# preoutgoing hook can prevent outgoing changes for local clones
+
+  $ echo 'preoutgoing.forbid = python ../printenv.py preoutgoing.forbid 1' >> a/.hg/hgrc
+  $ hg clone a zzz
+  preoutgoing hook: HG_SOURCE=clone 
+  preoutgoing.forbid hook: HG_SOURCE=clone 
+  abort: preoutgoing.forbid hook exited with status 1
+  $ cd b
+
+  $ cat > hooktests.py <<EOF
+  > from mercurial import util
+  > 
+  > uncallable = 0
+  > 
+  > def printargs(args):
+  >     args.pop('ui', None)
+  >     args.pop('repo', None)
+  >     a = list(args.items())
+  >     a.sort()
+  >     print 'hook args:'
+  >     for k, v in a:
+  >        print ' ', k, v
+  > 
+  > def passhook(**args):
+  >     printargs(args)
+  > 
+  > def failhook(**args):
+  >     printargs(args)
+  >     return True
+  > 
+  > class LocalException(Exception):
+  >     pass
+  > 
+  > def raisehook(**args):
+  >     raise LocalException('exception from hook')
+  > 
+  > def aborthook(**args):
+  >     raise util.Abort('raise abort from hook')
+  > 
+  > def brokenhook(**args):
+  >     return 1 + {}
+  > 
+  > class container:
+  >     unreachable = 1
+  > EOF
+
+# test python hooks
+
+  $ PYTHONPATH="`pwd`:$PYTHONPATH"
+  $ export PYTHONPATH
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.broken = python:hooktests.brokenhook' >> ../a/.hg/hgrc
+  $ hg pull ../a 2>&1 | grep 'raised an exception'
+  error: preoutgoing.broken hook raised an exception: unsupported operand type(s) for +: 'int' and 'dict'
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.raise = python:hooktests.raisehook' >> ../a/.hg/hgrc
+  $ hg pull ../a 2>&1 | grep 'raised an exception'
+  error: preoutgoing.raise hook raised an exception: exception from hook
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.abort = python:hooktests.aborthook' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  pulling from ../a
+  searching for changes
+  error: preoutgoing.abort hook failed: raise abort from hook
+  abort: raise abort from hook
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.fail = python:hooktests.failhook' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  pulling from ../a
+  searching for changes
+  hook args:
+    hooktype preoutgoing
+    source pull
+  abort: preoutgoing.fail hook failed
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.uncallable = python:hooktests.uncallable' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  pulling from ../a
+  searching for changes
+  abort: preoutgoing.uncallable hook is invalid ("hooktests.uncallable" is not callable)
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.nohook = python:hooktests.nohook' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  pulling from ../a
+  searching for changes
+  abort: preoutgoing.nohook hook is invalid ("hooktests.nohook" is not defined)
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.nomodule = python:nomodule' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  pulling from ../a
+  searching for changes
+  abort: preoutgoing.nomodule hook is invalid ("nomodule" not in a module)
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.badmodule = python:nomodule.nowhere' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  pulling from ../a
+  searching for changes
+  abort: preoutgoing.badmodule hook is invalid (import of "nomodule" failed)
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.unreachable = python:hooktests.container.unreachable' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  pulling from ../a
+  searching for changes
+  abort: preoutgoing.unreachable hook is invalid (import of "hooktests.container" failed)
+
+  $ echo '[hooks]' > ../a/.hg/hgrc
+  $ echo 'preoutgoing.pass = python:hooktests.passhook' >> ../a/.hg/hgrc
+  $ hg pull ../a
+  pulling from ../a
+  searching for changes
+  hook args:
+    hooktype preoutgoing
+    source pull
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  (run 'hg update' to get a working copy)
+
+# make sure --traceback works
+
+  $ echo '[hooks]' > .hg/hgrc
+  $ echo 'commit.abort = python:hooktests.aborthook' >> .hg/hgrc
+
+  $ echo aa > a
+  $ hg --traceback commit -d '0 0' -ma 2>&1 | grep '^Traceback'
+  Traceback (most recent call last):
+
+  $ cd ..
+  $ hg init c
+  $ cd c
+
+  $ cat > hookext.py <<EOF
+  > def autohook(**args):
+  >     print "Automatically installed hook"
+  > 
+  > def reposetup(ui, repo):
+  >     repo.ui.setconfig("hooks", "commit.auto", autohook)
+  > EOF
+  $ echo '[extensions]' >> .hg/hgrc
+  $ echo 'hookext = hookext.py' >> .hg/hgrc
+
+  $ touch foo
+  $ hg add foo
+  $ hg ci -d '0 0' -m 'add foo'
+  Automatically installed hook
+  $ echo >> foo
+  $ hg ci --debug -d '0 0' -m 'change foo'
+  foo
+  calling hook commit.auto: <function autohook at .*>
+  Automatically installed hook
+  committed changeset 1:52998019f6252a2b893452765fcb0a47351a5708
+
+  $ hg showconfig hooks
+  hooks.commit.auto=<function autohook at .*>
+
+# test python hook configured with python:[file]:[hook] syntax
+
+  $ cd ..
+  $ mkdir d
+  $ cd d
+  $ hg init repo
+  $ mkdir hooks
+
+  $ cd hooks
+  $ cat > testhooks.py <<EOF
+  > def testhook(**args):
+  >     print 'hook works'
+  > EOF
+  $ echo '[hooks]' > ../repo/.hg/hgrc
+  $ echo "pre-commit.test = python:`pwd`/testhooks.py:testhook" >> ../repo/.hg/hgrc
+
+  $ cd ../repo
+  $ hg commit -d '0 0'
+  hook works
+  nothing changed
+
+  $ cd ../../b
+
+# make sure --traceback works on hook import failure
+
+  $ cat > importfail.py <<EOF
+  > import somebogusmodule
+  > # dereference something in the module to force demandimport to load it
+  > somebogusmodule.whatever
+  > EOF
+
+  $ echo '[hooks]' > .hg/hgrc
+  $ echo 'precommit.importfail = python:importfail.whatever' >> .hg/hgrc
+
+  $ echo a >> a
+  $ hg --traceback commit -d '0 0' -ma 2>&1 | egrep '^(exception|Traceback|ImportError)'
+  exception from first failed import attempt:
+  Traceback (most recent call last):
+  ImportError: No module named somebogusmodule
+  exception from second failed import attempt:
+  Traceback (most recent call last):
+  ImportError: No module named hgext_importfail
+  Traceback (most recent call last):
+
+# commit and update hooks should run after command completion (issue 1827)
+
+  $ echo '[hooks]' > .hg/hgrc
+  $ echo 'commit = hg id' >> .hg/hgrc
+  $ echo 'update = hg id' >> .hg/hgrc
+  $ echo bb > a
+  $ hg ci -d '0 0' -ma
+  8da618c33484 tip
+  $ hg up 0
+  29b62aeb769f
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+  $ exit 0
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-http-branchmap	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,58 @@
+#!/bin/sh
+
+hgserve()
+{
+    hg serve -a localhost -p $HGPORT1 -d --pid-file=hg.pid -E errors.log -v $@ \
+        | sed -e 's/:[0-9][0-9]*//g' -e 's/http:\/\/[^/]*\//http:\/\/localhost\//'
+    cat hg.pid >> "$DAEMON_PIDS"
+}
+
+hg init a
+hg --encoding utf-8 -R a branch æ
+echo foo > a/foo
+hg -R a ci -Am foo
+
+hgserve -R a --config web.push_ssl=False --config web.allow_push=* --encoding latin1
+hg --encoding utf-8 clone http://localhost:$HGPORT1 b
+hg --encoding utf-8 -R b log
+echo bar >> b/foo
+hg -R b ci -m bar
+hg --encoding utf-8 -R b push | sed "s/$HGPORT1/PORT/"
+hg -R a --encoding utf-8 log
+
+kill `cat hg.pid`
+
+
+# verify 7e7d56fe4833 (encoding fallback in branchmap to maintain compatibility with 1.3.x)
+
+cat <<EOF > oldhg
+import sys
+from mercurial import ui, hg, commands
+
+class StdoutWrapper(object):
+    def __init__(self, stdout):
+        self._file = stdout
+
+    def write(self, data):
+        if data == '47\n':
+            # latin1 encoding is one %xx (3 bytes) shorter
+            data = '44\n'
+        elif data.startswith('%C3%A6 '):
+            # translate to latin1 encoding
+            data = '%%E6 %s' % data[7:]
+        self._file.write(data)
+
+    def __getattr__(self, name):
+        return getattr(self._file, name)
+
+sys.stdout = StdoutWrapper(sys.stdout)
+sys.stderr = StdoutWrapper(sys.stderr)
+
+myui = ui.ui()
+repo = hg.repository(myui, 'a')
+commands.serve(myui, repo, stdio=True)
+EOF
+
+echo baz >> b/foo
+hg -R b ci -m baz
+hg push -R b -e 'python oldhg' ssh://dummy/ --encoding latin1
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-http-branchmap.out	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,42 @@
+marked working directory as branch æ
+adding foo
+listening at http://localhost/ (bound to 127.0.0.1)
+requesting all changes
+adding changesets
+adding manifests
+adding file changes
+added 1 changesets with 1 changes to 1 files
+updating to branch æ
+1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+changeset:   0:867c11ce77b8
+branch:      æ
+tag:         tip
+user:        test
+date:        Thu Jan 01 00:00:00 1970 +0000
+summary:     foo
+
+pushing to http://localhost:PORT
+searching for changes
+remote: adding changesets
+remote: adding manifests
+remote: adding file changes
+remote: added 1 changesets with 1 changes to 1 files
+changeset:   1:58e7c90d67cb
+branch:      æ
+tag:         tip
+user:        test
+date:        Thu Jan 01 00:00:00 1970 +0000
+summary:     bar
+
+changeset:   0:867c11ce77b8
+branch:      æ
+user:        test
+date:        Thu Jan 01 00:00:00 1970 +0000
+summary:     foo
+
+pushing to ssh://dummy/
+searching for changes
+remote: adding changesets
+remote: adding manifests
+remote: adding file changes
+remote: added 1 changesets with 1 changes to 1 files
--- a/tests/test-identify	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,46 +0,0 @@
-#!/bin/sh
-
-"$TESTDIR/hghave" no-outer-repo || exit 80
-
-echo % no repo
-hg id
-
-echo % create repo
-hg init test
-cd test
-echo a > a
-hg ci -Ama
-
-echo % basic id usage
-hg id
-hg id --debug
-hg id -q
-hg id -v
-
-echo % with options
-hg id -r.
-hg id -n
-hg id -t
-hg id -b
-hg id -i
-hg id -n -t -b -i
-
-echo % with modifications
-echo b > a
-hg id -n -t -b -i
-
-echo % other local repo
-cd ..
-hg -R test id
-hg id test
-
-echo % with remote http repo
-cd test
-hg serve -p $HGPORT1 -d --pid-file=hg.pid
-cat hg.pid >> $DAEMON_PIDS
-hg id http://localhost:$HGPORT1/
-
-echo % remote with tags?
-hg id -t http://localhost:$HGPORT1/
-
-true # ends with util.Abort -> returns 255
--- a/tests/test-identify.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,25 +0,0 @@
-% no repo
-abort: There is no Mercurial repository here (.hg not found)
-% create repo
-adding a
-% basic id usage
-cb9a9f314b8b tip
-cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b tip
-cb9a9f314b8b
-cb9a9f314b8b tip
-% with options
-cb9a9f314b8b tip
-0
-tip
-default
-cb9a9f314b8b
-cb9a9f314b8b 0 default tip
-% with modifications
-cb9a9f314b8b+ 0+ default tip
-% other local repo
-cb9a9f314b8b+ tip
-cb9a9f314b8b+ tip
-% with remote http repo
-cb9a9f314b8b
-% remote with tags?
-abort: can't query remote revision number, branch, or tags
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-identify.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,69 @@
+  $ "$TESTDIR/hghave" no-outer-repo || exit 80
+
+no repo
+
+  $ hg id
+  abort: There is no Mercurial repository here (.hg not found)
+
+create repo
+
+  $ hg init test
+  $ cd test
+  $ echo a > a
+  $ hg ci -Ama
+  adding a
+
+basic id usage
+
+  $ hg id
+  cb9a9f314b8b tip
+  $ hg id --debug
+  cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b tip
+  $ hg id -q
+  cb9a9f314b8b
+  $ hg id -v
+  cb9a9f314b8b tip
+
+with options
+
+  $ hg id -r.
+  cb9a9f314b8b tip
+  $ hg id -n
+  0
+  $ hg id -t
+  tip
+  $ hg id -b
+  default
+  $ hg id -i
+  cb9a9f314b8b
+  $ hg id -n -t -b -i
+  cb9a9f314b8b 0 default tip
+
+with modifications
+
+  $ echo b > a
+  $ hg id -n -t -b -i
+  cb9a9f314b8b+ 0+ default tip
+
+other local repo
+
+  $ cd ..
+  $ hg -R test id
+  cb9a9f314b8b+ tip
+  $ hg id test
+  cb9a9f314b8b+ tip
+
+with remote http repo
+
+  $ cd test
+  $ hg serve -p $HGPORT1 -d --pid-file=hg.pid
+  $ cat hg.pid >> $DAEMON_PIDS
+  $ hg id http://localhost:$HGPORT1/
+  cb9a9f314b8b
+
+remote with tags?
+
+  $ hg id -t http://localhost:$HGPORT1/
+  abort: can't query remote revision number, branch, or tags
+
+  $ true # ends with util.Abort -> returns 255
--- a/tests/test-import	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,497 +0,0 @@
-#!/bin/sh
-
-hg init a
-mkdir a/d1
-mkdir a/d1/d2
-echo line 1 > a/a
-echo line 1 > a/d1/d2/a
-hg --cwd a ci -Ama
-
-echo line 2 >> a/a
-hg --cwd a ci -u someone -d '1 0' -m'second change'
-
-echo % import exported patch
-hg clone -r0 a b
-hg --cwd a export tip > tip.patch
-hg --cwd b import ../tip.patch
-echo % message should be same
-hg --cwd b tip | grep 'second change'
-echo % committer should be same
-hg --cwd b tip | grep someone
-rm -r b
-
-echo % import exported patch with external patcher
-cat > dummypatch.py <<EOF
-print 'patching file a'
-file('a', 'wb').write('line2\n')
-EOF
-chmod +x dummypatch.py
-hg clone -r0 a b
-hg --cwd a export tip > tip.patch
-hg --config ui.patch='python ../dummypatch.py' --cwd b import ../tip.patch
-cat b/a
-rm -r b
-
-echo % import of plain diff should fail without message
-hg clone -r0 a b
-hg --cwd a diff -r0:1 > tip.patch
-hg --cwd b import ../tip.patch
-rm -r b
-
-echo % import of plain diff should be ok with message
-hg clone -r0 a b
-hg --cwd a diff -r0:1 > tip.patch
-hg --cwd b import -mpatch ../tip.patch
-rm -r b
-
-echo % import of plain diff with specific date and user
-hg clone -r0 a b
-hg --cwd a diff -r0:1 > tip.patch
-hg --cwd b import -mpatch -d '1 0' -u 'user@nowhere.net' ../tip.patch
-hg -R b tip -pv
-rm -r b
-
-echo % import of plain diff should be ok with --no-commit
-hg clone -r0 a b
-hg --cwd a diff -r0:1 > tip.patch
-hg --cwd b import --no-commit ../tip.patch
-hg --cwd b diff --nodates
-rm -r b
-
-echo % hg -R repo import
-# put the clone in a subdir - having a directory named "a"
-# used to hide a bug.
-mkdir dir
-hg clone -r0 a dir/b
-hg --cwd a export tip > dir/tip.patch
-cd dir
-hg -R b import tip.patch
-cd ..
-rm -r dir
-
-echo % import from stdin
-hg clone -r0 a b
-hg --cwd a export tip | hg --cwd b import -
-rm -r b
-
-echo % import two patches in one stream
-hg init b
-hg --cwd a export 0:tip | hg --cwd b import -
-hg --cwd a id
-hg --cwd b id
-rm -r b
-
-echo % override commit message
-hg clone -r0 a b
-hg --cwd a export tip | hg --cwd b import -m 'override' -
-hg --cwd b tip | grep override
-rm -r b
-
-cat > mkmsg.py <<EOF
-import email.Message, sys
-msg = email.Message.Message()
-msg.set_payload('email commit message\n' + open('tip.patch', 'rb').read())
-msg['Subject'] = 'email patch'
-msg['From'] = 'email patcher'
-sys.stdout.write(msg.as_string())
-EOF
-
-echo % plain diff in email, subject, message body
-hg clone -r0 a b
-hg --cwd a diff -r0:1 > tip.patch
-python mkmsg.py > msg.patch
-hg --cwd b import ../msg.patch
-hg --cwd b tip | grep email
-rm -r b
-
-echo % plain diff in email, no subject, message body
-hg clone -r0 a b
-grep -v '^Subject:' msg.patch | hg --cwd b import -
-rm -r b
-
-echo % plain diff in email, subject, no message body
-hg clone -r0 a b
-grep -v '^email ' msg.patch | hg --cwd b import -
-rm -r b
-
-echo % plain diff in email, no subject, no message body, should fail
-hg clone -r0 a b
-egrep -v '^(Subject|email)' msg.patch | hg --cwd b import -
-rm -r b
-
-echo % hg export in email, should use patch header
-hg clone -r0 a b
-hg --cwd a export tip > tip.patch
-python mkmsg.py | hg --cwd b import -
-hg --cwd b tip | grep second
-rm -r b
-
-# subject: duplicate detection, removal of [PATCH]
-# The '---' tests the gitsendmail handling without proper mail headers
-cat > mkmsg2.py <<EOF
-import email.Message, sys
-msg = email.Message.Message()
-msg.set_payload('email patch\n\nnext line\n---\n' + open('tip.patch').read())
-msg['Subject'] = '[PATCH] email patch'
-msg['From'] = 'email patcher'
-sys.stdout.write(msg.as_string())
-EOF
-
-echo '% plain diff in email, [PATCH] subject, message body with subject'
-hg clone -r0 a b
-hg --cwd a diff -r0:1 > tip.patch
-python mkmsg2.py | hg --cwd b import -
-hg --cwd b tip --template '{desc}\n'
-rm -r b
-
-# We weren't backing up the correct dirstate file when importing many patches
-# (issue963)
-echo '% import patch1 patch2; rollback'
-echo line 3 >> a/a
-hg --cwd a ci -m'third change'
-hg --cwd a export -o '../patch%R' 1 2
-hg clone -qr0 a b
-hg --cwd b parents --template 'parent: {rev}\n'
-hg --cwd b import ../patch1 ../patch2
-hg --cwd b rollback
-hg --cwd b parents --template 'parent: {rev}\n'
-rm -r b
-
-# bug non regression test
-# importing a patch in a subdirectory failed at the commit stage
-echo line 2 >> a/d1/d2/a
-hg --cwd a ci -u someoneelse -d '1 0' -m'subdir change'
-echo % hg import in a subdirectory
-hg clone -r0 a b
-hg --cwd a export tip | sed -e 's/d1\/d2\///' > tip.patch
-dir=`pwd`
-cd b/d1/d2 2>&1 > /dev/null
-hg import  ../../../tip.patch
-cd "$dir"
-echo "% message should be 'subdir change'"
-hg --cwd b tip | grep 'subdir change'
-echo "% committer should be 'someoneelse'"
-hg --cwd b tip | grep someoneelse
-echo "% should be empty"
-hg --cwd b status
-
-
-# Test fuzziness (ambiguous patch location, fuzz=2)
-echo % test fuzziness
-hg init fuzzy
-cd fuzzy
-echo line1 > a
-echo line0 >> a
-echo line3 >> a
-hg ci -Am adda
-echo line1 > a
-echo line2 >> a
-echo line0 >> a
-echo line3 >> a
-hg ci -m change a
-hg export tip > tip.patch
-hg up -C 0
-echo line1 > a
-echo line0 >> a
-echo line1 >> a
-echo line0 >> a
-hg ci -m brancha
-hg import --no-commit -v tip.patch
-hg revert -a
-echo '% test fuzziness with eol=auto'
-hg --config patch.eol=auto import --no-commit -v tip.patch
-cd ..
-
-# Test hunk touching empty files (issue906)
-hg init empty
-cd empty
-touch a
-touch b1
-touch c1
-echo d > d
-hg ci -Am init
-echo a > a
-echo b > b1
-hg mv b1 b2
-echo c > c1
-hg copy c1 c2
-rm d
-touch d
-hg diff --git
-hg ci -m empty
-hg export --git tip > empty.diff
-hg up -C 0
-hg import empty.diff
-for name in a b1 b2 c1 c2 d;
-do
-    echo % $name file
-    test -f $name && cat $name
-done
-cd ..
-
-# Test importing a patch ending with a binary file removal
-echo % test trailing binary removal
-hg init binaryremoval
-cd binaryremoval
-echo a > a
-python -c "file('b', 'wb').write('a\x00b')"
-hg ci -Am addall
-hg rm a
-hg rm b
-hg st
-hg ci -m remove
-hg export --git . > remove.diff
-cat remove.diff | grep git
-hg up -C 0
-hg import remove.diff
-hg manifest
-cd ..
-
-echo % 'test update+rename with common name (issue 927)'
-hg init t
-cd t
-touch a
-hg ci -Am t
-echo a > a
-# Here, bfile.startswith(afile)
-hg copy a a2
-hg ci -m copya
-hg export --git tip > copy.diff
-hg up -C 0
-hg import copy.diff
-echo % view a
-# a should contain an 'a'
-cat a
-echo % view a2
-# and a2 should have duplicated it
-cat a2
-cd ..
-
-echo % 'test -p0'
-hg init p0
-cd p0
-echo a > a
-hg ci -Am t
-hg import -p0 - << EOF
-foobar
---- a	Sat Apr 12 22:43:58 2008 -0400
-+++ a	Sat Apr 12 22:44:05 2008 -0400
-@@ -1,1 +1,1 @@
--a
-+bb
-EOF
-hg status
-cat a
-cd ..
-
-echo % 'test paths outside repo root'
-mkdir outside
-touch outside/foo
-hg init inside
-cd inside
-hg import - <<EOF
-diff --git a/a b/b
-rename from ../outside/foo
-rename to bar
-EOF
-cd ..
-
-echo '% test import with similarity and git and strip (issue295 et al.)'
-hg init sim
-cd sim
-echo 'this is a test' > a
-hg ci -Ama
-cat > ../rename.diff <<EOF
-diff --git a/foo/a b/foo/a
-deleted file mode 100644
---- a/foo/a
-+++ /dev/null
-@@ -1,1 +0,0 @@
--this is a test
-diff --git a/foo/b b/foo/b
-new file mode 100644
---- /dev/null
-+++ b/foo/b
-@@ -0,0 +1,2 @@
-+this is a test
-+foo
-EOF
-hg import --no-commit -v -s 1 ../rename.diff -p2
-hg st -C
-hg revert -a
-rm b
-hg import --no-commit -v -s 100 ../rename.diff -p2
-hg st -C
-cd ..
-
-
-echo '% add empty file from the end of patch (issue 1495)'
-hg init addemptyend
-cd addemptyend
-touch a
-hg addremove
-hg ci -m "commit"
-cat > a.patch <<EOF
-diff --git a/a b/a
---- a/a
-+++ b/a
-@@ -0,0 +1,1 @@
-+a
-diff --git a/b b/b
-new file mode 100644
-EOF
-hg import --no-commit a.patch
-cd ..
-
-echo '% create file when source is not /dev/null'
-cat > create.patch <<EOF
-diff -Naur proj-orig/foo proj-new/foo
---- proj-orig/foo       1969-12-31 16:00:00.000000000 -0800
-+++ proj-new/foo        2009-07-17 16:50:45.801368000 -0700
-@@ -0,0 +1,1 @@
-+a
-EOF
-# some people have patches like the following too
-cat > create2.patch <<EOF
-diff -Naur proj-orig/foo proj-new/foo
---- proj-orig/foo.orig  1969-12-31 16:00:00.000000000 -0800
-+++ proj-new/foo        2009-07-17 16:50:45.801368000 -0700
-@@ -0,0 +1,1 @@
-+a
-EOF
-hg init oddcreate
-cd oddcreate
-hg import --no-commit ../create.patch
-cat foo
-rm foo
-hg revert foo
-hg import --no-commit ../create2.patch
-cat foo
-
-echo % 'first line mistaken for email headers (issue 1859)'
-hg init emailconfusion
-cd emailconfusion
-cat > a.patch <<EOF
-module: summary
-
-description
-
-
-diff -r 000000000000 -r 9b4c1e343b55 test.txt
---- /dev/null
-+++ b/a
-@@ -0,0 +1,1 @@
-+a
-EOF
-hg import -d '0 0' a.patch
-hg parents -v
-cd ..
-
-echo % '--- in commit message'
-hg init commitconfusion
-cd commitconfusion
-cat > a.patch <<EOF
-module: summary
-
---- description
-
-diff --git a/a b/a
-new file mode 100644
---- /dev/null
-+++ b/a
-@@ -0,0 +1,1 @@
-+a
-EOF
-hg import -d '0 0' a.patch
-hg parents -v
-cd ..
-
-echo '% tricky header splitting'
-cat > trickyheaders.patch <<EOF
-From: User A <user@a>
-Subject: [PATCH] from: tricky!
-
-# HG changeset patch
-# User User B
-# Date 1266264441 18000
-# Branch stable
-# Node ID f2be6a1170ac83bf31cb4ae0bad00d7678115bc0
-# Parent  0000000000000000000000000000000000000000
-from: tricky!
-
-That is not a header.
-
-diff -r 000000000000 -r f2be6a1170ac foo
---- /dev/null
-+++ b/foo
-@@ -0,0 +1,1 @@
-+foo
-EOF
-
-hg init trickyheaders
-cd trickyheaders
-hg import -d '0 0' ../trickyheaders.patch
-hg export --git tip
-cd ..
-
-echo '% issue2102'
-hg init issue2102
-cd issue2102
-mkdir -p src/cmd/gc
-touch src/cmd/gc/mksys.bash
-hg ci -Am init
-hg import - <<EOF
-# HG changeset patch
-# User Rob Pike
-# Date 1216685449 25200
-# Node ID 03aa2b206f499ad6eb50e6e207b9e710d6409c98
-# Parent  93d10138ad8df586827ca90b4ddb5033e21a3a84
-help management of empty pkg and lib directories in perforce
-
-R=gri
-DELTA=4  (4 added, 0 deleted, 0 changed)
-OCL=13328
-CL=13328
-
-diff --git a/lib/place-holder b/lib/place-holder
-new file mode 100644
---- /dev/null
-+++ b/lib/place-holder
-@@ -0,0 +1,2 @@
-+perforce does not maintain empty directories.
-+this file helps.
-diff --git a/pkg/place-holder b/pkg/place-holder
-new file mode 100644
---- /dev/null
-+++ b/pkg/place-holder
-@@ -0,0 +1,2 @@
-+perforce does not maintain empty directories.
-+this file helps.
-diff --git a/src/cmd/gc/mksys.bash b/src/cmd/gc/mksys.bash
-old mode 100644
-new mode 100755
-EOF
-hg sum
-hg diff --git -c tip
-cd ..
-
-echo '% diff lines looking like headers'
-hg init difflineslikeheaders
-cd difflineslikeheaders
-echo a >a
-echo b >b
-echo c >c
-hg ci -Am1
-
-echo "key: value" >>a
-echo "key: value" >>b
-echo "foo" >>c
-hg ci -m2
-
-hg up -C 0
-hg diff --git -c1 >want
-hg diff -c1 | hg import --no-commit -
-hg diff --git >have
-diff want have
-cd ..
-
--- a/tests/test-import-eol	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,85 +0,0 @@
-#!/bin/sh
-
-cat > makepatch.py <<EOF
-f = file('eol.diff', 'wb')
-w = f.write
-w('test message\n')
-w('diff --git a/a b/a\n')
-w('--- a/a\n')
-w('+++ b/a\n')
-w('@@ -1,5 +1,5 @@\n')
-w(' a\n')
-w('-bbb\r\n')
-w('+yyyy\r\n')
-w(' cc\r\n')
-w(' \n')
-w(' d\n')
-w('-e\n')
-w('\ No newline at end of file\n')
-w('+z\r\n')
-w('\ No newline at end of file\r\n')
-EOF
-
-hg init repo
-cd repo
-echo '\.diff' > .hgignore
-
-# Test different --eol values
-python -c 'file("a", "wb").write("a\nbbb\ncc\n\nd\ne")'
-hg ci -Am adda
-python ../makepatch.py
-
-echo % invalid eol
-hg --config patch.eol='LFCR' import eol.diff
-hg revert -a
-
-echo % force LF
-hg --traceback --config patch.eol='LF' import eol.diff
-python -c 'print repr(file("a","rb").read())'
-hg st
-
-echo % force CRLF
-hg up -C 0
-hg --traceback --config patch.eol='CRLF' import eol.diff
-python -c 'print repr(file("a","rb").read())'
-hg st
-
-echo % auto EOL on LF file
-hg up -C 0
-hg --traceback --config patch.eol='auto' import eol.diff
-python -c 'print repr(file("a","rb").read())'
-hg st
-
-echo % auto EOL on CRLF file
-python -c 'file("a", "wb").write("a\r\nbbb\r\ncc\r\n\r\nd\r\ne")'
-hg commit -m 'switch EOLs in a'
-hg --traceback --config patch.eol='auto' import eol.diff
-python -c 'print repr(file("a","rb").read())'
-hg st
-
-echo % auto EOL on new file or source without any EOL
-python -c 'file("noeol", "wb").write("noeol")'
-hg add noeol
-hg commit -m 'add noeol'
-python -c 'file("noeol", "wb").write("noeol\r\nnoeol\n")'
-python -c 'file("neweol", "wb").write("neweol\nneweol\r\n")'
-hg add neweol
-hg diff --git > noeol.diff
-hg revert --no-backup noeol neweol
-rm neweol
-hg --traceback --config patch.eol='auto' import -m noeol noeol.diff
-python -c 'print repr(file("noeol","rb").read())'
-python -c 'print repr(file("neweol","rb").read())'
-hg st
-
-# Test --eol and binary patches
-python -c 'file("b", "wb").write("a\x00\nb\r\nd")'
-hg ci -Am addb
-python -c 'file("b", "wb").write("a\x00\nc\r\nd")'
-hg diff --git > bin.diff
-hg revert --no-backup b
-echo % binary patch with --eol
-hg import --config patch.eol='CRLF' -m changeb bin.diff
-python -c 'print repr(file("b","rb").read())'
-hg st
-cd ..
--- a/tests/test-import-eol.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,27 +0,0 @@
-adding .hgignore
-adding a
-% invalid eol
-applying eol.diff
-abort: Unsupported line endings type: LFCR
-% force LF
-applying eol.diff
-'a\nyyyy\ncc\n\nd\ne'
-% force CRLF
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying eol.diff
-'a\r\nyyyy\r\ncc\r\n\r\nd\r\ne'
-% auto EOL on LF file
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying eol.diff
-'a\nyyyy\ncc\n\nd\ne'
-% auto EOL on CRLF file
-applying eol.diff
-'a\r\nyyyy\r\ncc\r\n\r\nd\r\ne'
-% auto EOL on new file or source without any EOL
-applying noeol.diff
-'noeol\r\nnoeol\n'
-'neweol\nneweol\r\n'
-adding b
-% binary patch with --eol
-applying bin.diff
-'a\x00\nc\r\nd'
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-import-eol.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,121 @@
+  $ cat > makepatch.py <<EOF
+  > f = file('eol.diff', 'wb')
+  > w = f.write
+  > w('test message\n')
+  > w('diff --git a/a b/a\n')
+  > w('--- a/a\n')
+  > w('+++ b/a\n')
+  > w('@@ -1,5 +1,5 @@\n')
+  > w(' a\n')
+  > w('-bbb\r\n')
+  > w('+yyyy\r\n')
+  > w(' cc\r\n')
+  > w(' \n')
+  > w(' d\n')
+  > w('-e\n')
+  > w('\ No newline at end of file\n')
+  > w('+z\r\n')
+  > w('\ No newline at end of file\r\n')
+  > EOF
+
+  $ hg init repo
+  $ cd repo
+  $ echo '\.diff' > .hgignore
+
+
+Test different --eol values
+
+  $ python -c 'file("a", "wb").write("a\nbbb\ncc\n\nd\ne")'
+  $ hg ci -Am adda
+  adding .hgignore
+  adding a
+  $ python ../makepatch.py
+
+
+invalid eol
+
+  $ hg --config patch.eol='LFCR' import eol.diff
+  applying eol.diff
+  abort: Unsupported line endings type: LFCR
+  $ hg revert -a
+
+
+force LF
+
+  $ hg --traceback --config patch.eol='LF' import eol.diff
+  applying eol.diff
+  $ python -c 'print repr(file("a","rb").read())'
+  'a\nyyyy\ncc\n\nd\ne'
+  $ hg st
+
+
+force CRLF
+
+  $ hg up -C 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --traceback --config patch.eol='CRLF' import eol.diff
+  applying eol.diff
+  $ python -c 'print repr(file("a","rb").read())'
+  'a\r\nyyyy\r\ncc\r\n\r\nd\r\ne'
+  $ hg st
+
+
+auto EOL on LF file
+
+  $ hg up -C 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --traceback --config patch.eol='auto' import eol.diff
+  applying eol.diff
+  $ python -c 'print repr(file("a","rb").read())'
+  'a\nyyyy\ncc\n\nd\ne'
+  $ hg st
+
+
+auto EOL on CRLF file
+
+  $ python -c 'file("a", "wb").write("a\r\nbbb\r\ncc\r\n\r\nd\r\ne")'
+  $ hg commit -m 'switch EOLs in a'
+  $ hg --traceback --config patch.eol='auto' import eol.diff
+  applying eol.diff
+  $ python -c 'print repr(file("a","rb").read())'
+  'a\r\nyyyy\r\ncc\r\n\r\nd\r\ne'
+  $ hg st
+
+
+auto EOL on new file or source without any EOL
+
+  $ python -c 'file("noeol", "wb").write("noeol")'
+  $ hg add noeol
+  $ hg commit -m 'add noeol'
+  $ python -c 'file("noeol", "wb").write("noeol\r\nnoeol\n")'
+  $ python -c 'file("neweol", "wb").write("neweol\nneweol\r\n")'
+  $ hg add neweol
+  $ hg diff --git > noeol.diff
+  $ hg revert --no-backup noeol neweol
+  $ rm neweol
+  $ hg --traceback --config patch.eol='auto' import -m noeol noeol.diff
+  applying noeol.diff
+  $ python -c 'print repr(file("noeol","rb").read())'
+  'noeol\r\nnoeol\n'
+  $ python -c 'print repr(file("neweol","rb").read())'
+  'neweol\nneweol\r\n'
+  $ hg st
+
+
+Test --eol and binary patches
+
+  $ python -c 'file("b", "wb").write("a\x00\nb\r\nd")'
+  $ hg ci -Am addb
+  adding b
+  $ python -c 'file("b", "wb").write("a\x00\nc\r\nd")'
+  $ hg diff --git > bin.diff
+  $ hg revert --no-backup b
+
+binary patch with --eol
+
+  $ hg import --config patch.eol='CRLF' -m changeb bin.diff
+  applying bin.diff
+  $ python -c 'print repr(file("b","rb").read())'
+  'a\x00\nc\r\nd'
+  $ hg st
+  $ cd ..
--- a/tests/test-import.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,381 +0,0 @@
-adding a
-adding d1/d2/a
-% import exported patch
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying ../tip.patch
-% message should be same
-summary:     second change
-% committer should be same
-user:        someone
-% import exported patch with external patcher
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying ../tip.patch
-line2
-% import of plain diff should fail without message
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying ../tip.patch
-abort: empty commit message
-% import of plain diff should be ok with message
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying ../tip.patch
-% import of plain diff with specific date and user
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying ../tip.patch
-changeset:   1:ca68f19f3a40
-tag:         tip
-user:        user@nowhere.net
-date:        Thu Jan 01 00:00:01 1970 +0000
-files:       a
-description:
-patch
-
-
-diff -r 80971e65b431 -r ca68f19f3a40 a
---- a/a	Thu Jan 01 00:00:00 1970 +0000
-+++ b/a	Thu Jan 01 00:00:01 1970 +0000
-@@ -1,1 +1,2 @@
- line 1
-+line 2
-
-% import of plain diff should be ok with --no-commit
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying ../tip.patch
-diff -r 80971e65b431 a
---- a/a
-+++ b/a
-@@ -1,1 +1,2 @@
- line 1
-+line 2
-% hg -R repo import
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying tip.patch
-% import from stdin
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying patch from stdin
-% import two patches in one stream
-applying patch from stdin
-applied 80971e65b431
-1d4bd90af0e4 tip
-1d4bd90af0e4 tip
-% override commit message
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying patch from stdin
-summary:     override
-% plain diff in email, subject, message body
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying ../msg.patch
-user:        email patcher
-summary:     email patch
-% plain diff in email, no subject, message body
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying patch from stdin
-% plain diff in email, subject, no message body
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying patch from stdin
-% plain diff in email, no subject, no message body, should fail
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying patch from stdin
-abort: empty commit message
-% hg export in email, should use patch header
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying patch from stdin
-summary:     second change
-% plain diff in email, [PATCH] subject, message body with subject
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying patch from stdin
-email patch
-
-next line
----
-% import patch1 patch2; rollback
-parent: 0
-applying ../patch1
-applying ../patch2
-applied 1d4bd90af0e4
-rolling back to revision 1 (undo commit)
-parent: 1
-% hg import in a subdirectory
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying ../../../tip.patch
-% message should be 'subdir change'
-summary:     subdir change
-% committer should be 'someoneelse'
-user:        someoneelse
-% should be empty
-% test fuzziness
-adding a
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-applying tip.patch
-patching file a
-Hunk #1 succeeded at 1 with fuzz 2 (offset -2 lines).
-reverting a
-% test fuzziness with eol=auto
-applying tip.patch
-patching file a
-Hunk #1 succeeded at 1 with fuzz 2 (offset -2 lines).
-adding a
-adding b1
-adding c1
-adding d
-diff --git a/a b/a
---- a/a
-+++ b/a
-@@ -0,0 +1,1 @@
-+a
-diff --git a/b1 b/b2
-rename from b1
-rename to b2
---- a/b1
-+++ b/b2
-@@ -0,0 +1,1 @@
-+b
-diff --git a/c1 b/c1
---- a/c1
-+++ b/c1
-@@ -0,0 +1,1 @@
-+c
-diff --git a/c1 b/c2
-copy from c1
-copy to c2
---- a/c1
-+++ b/c2
-@@ -0,0 +1,1 @@
-+c
-diff --git a/d b/d
---- a/d
-+++ b/d
-@@ -1,1 +0,0 @@
--d
-4 files updated, 0 files merged, 2 files removed, 0 files unresolved
-applying empty.diff
-% a file
-a
-% b1 file
-% b2 file
-b
-% c1 file
-c
-% c2 file
-c
-% d file
-% test trailing binary removal
-adding a
-adding b
-R a
-R b
-diff --git a/a b/a
-diff --git a/b b/b
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying remove.diff
-% test update+rename with common name (issue 927)
-adding a
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-applying copy.diff
-% view a
-a
-% view a2
-a
-% test -p0
-adding a
-applying patch from stdin
-bb
-% test paths outside repo root
-applying patch from stdin
-abort: ../outside/foo not under root
-% test import with similarity and git and strip (issue295 et al.)
-adding a
-applying ../rename.diff
-patching file a
-patching file b
-removing a
-adding b
-recording removal of a as rename to b (88% similar)
-A b
-  a
-R a
-undeleting a
-forgetting b
-applying ../rename.diff
-patching file a
-patching file b
-removing a
-adding b
-A b
-R a
-% add empty file from the end of patch (issue 1495)
-adding a
-applying a.patch
-% create file when source is not /dev/null
-applying ../create.patch
-a
-applying ../create2.patch
-a
-% first line mistaken for email headers (issue 1859)
-applying a.patch
-changeset:   0:5a681217c0ad
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-files:       a
-description:
-module: summary
-
-description
-
-
-% --- in commit message
-applying a.patch
-changeset:   0:f34d9187897d
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-files:       a
-description:
-module: summary
-
-
-% tricky header splitting
-applying ../trickyheaders.patch
-# HG changeset patch
-# User User B
-# Date 0 0
-# Node ID eb56ab91903632294ac504838508cb370c0901d2
-# Parent  0000000000000000000000000000000000000000
-from: tricky!
-
-That is not a header.
-
-diff --git a/foo b/foo
-new file mode 100644
---- /dev/null
-+++ b/foo
-@@ -0,0 +1,1 @@
-+foo
-% issue2102
-adding src/cmd/gc/mksys.bash
-applying patch from stdin
-parent: 1:d59915696727 tip
- help management of empty pkg and lib directories in perforce
-branch: default
-commit: (clean)
-update: (current)
-diff --git a/lib/place-holder b/lib/place-holder
-new file mode 100644
---- /dev/null
-+++ b/lib/place-holder
-@@ -0,0 +1,2 @@
-+perforce does not maintain empty directories.
-+this file helps.
-diff --git a/pkg/place-holder b/pkg/place-holder
-new file mode 100644
---- /dev/null
-+++ b/pkg/place-holder
-@@ -0,0 +1,2 @@
-+perforce does not maintain empty directories.
-+this file helps.
-diff --git a/src/cmd/gc/mksys.bash b/src/cmd/gc/mksys.bash
-old mode 100644
-new mode 100755
-% diff lines looking like headers
-adding a
-adding b
-adding c
-3 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying patch from stdin
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-import.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,916 @@
+  $ hg init a
+  $ mkdir a/d1
+  $ mkdir a/d1/d2
+  $ echo line 1 > a/a
+  $ echo line 1 > a/d1/d2/a
+  $ hg --cwd a ci -Ama
+  adding a
+  adding d1/d2/a
+
+  $ echo line 2 >> a/a
+  $ hg --cwd a ci -u someone -d '1 0' -m'second change'
+
+
+import exported patch
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a export tip > tip.patch
+  $ hg --cwd b import ../tip.patch
+  applying ../tip.patch
+
+message should be same
+
+  $ hg --cwd b tip | grep 'second change'
+  summary:     second change
+
+committer should be same
+
+  $ hg --cwd b tip | grep someone
+  user:        someone
+  $ rm -r b
+
+
+import exported patch with external patcher
+
+  $ cat > dummypatch.py <<EOF
+  > print 'patching file a'
+  > file('a', 'wb').write('line2\n')
+  > EOF
+  $ chmod +x dummypatch.py
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a export tip > tip.patch
+  $ hg --config ui.patch='python ../dummypatch.py' --cwd b import ../tip.patch
+  applying ../tip.patch
+  $ cat b/a
+  line2
+  $ rm -r b
+
+
+import of plain diff should fail without message
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a diff -r0:1 > tip.patch
+  $ hg --cwd b import ../tip.patch
+  applying ../tip.patch
+  abort: empty commit message
+  $ rm -r b
+
+
+import of plain diff should be ok with message
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a diff -r0:1 > tip.patch
+  $ hg --cwd b import -mpatch ../tip.patch
+  applying ../tip.patch
+  $ rm -r b
+
+
+import of plain diff with specific date and user
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a diff -r0:1 > tip.patch
+  $ hg --cwd b import -mpatch -d '1 0' -u 'user@nowhere.net' ../tip.patch
+  applying ../tip.patch
+  $ hg -R b tip -pv
+  changeset:   1:ca68f19f3a40
+  tag:         tip
+  user:        user@nowhere.net
+  date:        Thu Jan 01 00:00:01 1970 +0000
+  files:       a
+  description:
+  patch
+  
+  
+  diff -r 80971e65b431 -r ca68f19f3a40 a
+  --- a/a	Thu Jan 01 00:00:00 1970 +0000
+  +++ b/a	Thu Jan 01 00:00:01 1970 +0000
+  @@ -1,1 +1,2 @@
+   line 1
+  +line 2
+  
+  $ rm -r b
+
+
+import of plain diff should be ok with --no-commit
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a diff -r0:1 > tip.patch
+  $ hg --cwd b import --no-commit ../tip.patch
+  applying ../tip.patch
+  $ hg --cwd b diff --nodates
+  diff -r 80971e65b431 a
+  --- a/a
+  +++ b/a
+  @@ -1,1 +1,2 @@
+   line 1
+  +line 2
+  $ rm -r b
+
+
+hg -R repo import
+put the clone in a subdir - having a directory named "a"
+used to hide a bug.
+
+  $ mkdir dir
+  $ hg clone -r0 a dir/b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a export tip > dir/tip.patch
+  $ cd dir
+  $ hg -R b import tip.patch
+  applying tip.patch
+  $ cd ..
+  $ rm -r dir
+
+
+import from stdin
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a export tip | hg --cwd b import -
+  applying patch from stdin
+  $ rm -r b
+
+
+import two patches in one stream
+
+  $ hg init b
+  $ hg --cwd a export 0:tip | hg --cwd b import -
+  applying patch from stdin
+  applied 80971e65b431
+  $ hg --cwd a id
+  1d4bd90af0e4 tip
+  $ hg --cwd b id
+  1d4bd90af0e4 tip
+  $ rm -r b
+
+
+override commit message
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a export tip | hg --cwd b import -m 'override' -
+  applying patch from stdin
+  $ hg --cwd b tip | grep override
+  summary:     override
+  $ rm -r b
+
+  $ cat > mkmsg.py <<EOF
+  > import email.Message, sys
+  > msg = email.Message.Message()
+  > msg.set_payload('email commit message\n' + open('tip.patch', 'rb').read())
+  > msg['Subject'] = 'email patch'
+  > msg['From'] = 'email patcher'
+  > sys.stdout.write(msg.as_string())
+  > EOF
+
+
+plain diff in email, subject, message body
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a diff -r0:1 > tip.patch
+  $ python mkmsg.py > msg.patch
+  $ hg --cwd b import ../msg.patch
+  applying ../msg.patch
+  $ hg --cwd b tip | grep email
+  user:        email patcher
+  summary:     email patch
+  $ rm -r b
+
+
+plain diff in email, no subject, message body
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ grep -v '^Subject:' msg.patch | hg --cwd b import -
+  applying patch from stdin
+  $ rm -r b
+
+
+plain diff in email, subject, no message body
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ grep -v '^email ' msg.patch | hg --cwd b import -
+  applying patch from stdin
+  $ rm -r b
+
+
+plain diff in email, no subject, no message body, should fail
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ egrep -v '^(Subject|email)' msg.patch | hg --cwd b import -
+  applying patch from stdin
+  abort: empty commit message
+  $ rm -r b
+
+
+hg export in email, should use patch header
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a export tip > tip.patch
+  $ python mkmsg.py | hg --cwd b import -
+  applying patch from stdin
+  $ hg --cwd b tip | grep second
+  summary:     second change
+  $ rm -r b
+
+
+subject: duplicate detection, removal of [PATCH]
+The '---' tests the gitsendmail handling without proper mail headers
+
+  $ cat > mkmsg2.py <<EOF
+  > import email.Message, sys
+  > msg = email.Message.Message()
+  > msg.set_payload('email patch\n\nnext line\n---\n' + open('tip.patch').read())
+  > msg['Subject'] = '[PATCH] email patch'
+  > msg['From'] = 'email patcher'
+  > sys.stdout.write(msg.as_string())
+  > EOF
+
+
+plain diff in email, [PATCH] subject, message body with subject
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a diff -r0:1 > tip.patch
+  $ python mkmsg2.py | hg --cwd b import -
+  applying patch from stdin
+  $ hg --cwd b tip --template '{desc}\n'
+  email patch
+  
+  next line
+  ---
+  $ rm -r b
+
+
+We weren't backing up the correct dirstate file when importing many patches
+(issue963)
+import patch1 patch2; rollback
+
+  $ echo line 3 >> a/a
+  $ hg --cwd a ci -m'third change'
+  $ hg --cwd a export -o '../patch%R' 1 2
+  $ hg clone -qr0 a b
+  $ hg --cwd b parents --template 'parent: {rev}\n'
+  parent: 0
+  $ hg --cwd b import ../patch1 ../patch2
+  applying ../patch1
+  applying ../patch2
+  applied 1d4bd90af0e4
+  $ hg --cwd b rollback
+  rolling back to revision 1 (undo commit)
+  $ hg --cwd b parents --template 'parent: {rev}\n'
+  parent: 1
+  $ rm -r b
+
+
+importing a patch in a subdirectory failed at the commit stage
+
+  $ echo line 2 >> a/d1/d2/a
+  $ hg --cwd a ci -u someoneelse -d '1 0' -m'subdir change'
+
+hg import in a subdirectory
+
+  $ hg clone -r0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --cwd a export tip | sed -e 's/d1\/d2\///' > tip.patch
+  $ dir=`pwd`
+  $ cd b/d1/d2 2>&1 > /dev/null
+  $ hg import  ../../../tip.patch
+  applying ../../../tip.patch
+  $ cd "$dir"
+
+message should be 'subdir change'
+
+  $ hg --cwd b tip | grep 'subdir change'
+  summary:     subdir change
+
+committer should be 'someoneelse'
+
+  $ hg --cwd b tip | grep someoneelse
+  user:        someoneelse
+
+should be empty
+
+  $ hg --cwd b status
+
+
+Test fuzziness (ambiguous patch location, fuzz=2)
+
+  $ hg init fuzzy
+  $ cd fuzzy
+  $ echo line1 > a
+  $ echo line0 >> a
+  $ echo line3 >> a
+  $ hg ci -Am adda
+  adding a
+  $ echo line1 > a
+  $ echo line2 >> a
+  $ echo line0 >> a
+  $ echo line3 >> a
+  $ hg ci -m change a
+  $ hg export tip > tip.patch
+  $ hg up -C 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo line1 > a
+  $ echo line0 >> a
+  $ echo line1 >> a
+  $ echo line0 >> a
+  $ hg ci -m brancha
+  created new head
+  $ hg import --no-commit -v tip.patch
+  applying tip.patch
+  patching file a
+  Hunk #1 succeeded at 1 with fuzz 2 (offset -2 lines).
+  $ hg revert -a
+  reverting a
+
+test fuzziness with eol=auto
+
+  $ hg --config patch.eol=auto import --no-commit -v tip.patch
+  applying tip.patch
+  patching file a
+  Hunk #1 succeeded at 1 with fuzz 2 (offset -2 lines).
+  $ cd ..
+
+
+Test hunk touching empty files (issue906)
+
+  $ hg init empty
+  $ cd empty
+  $ touch a
+  $ touch b1
+  $ touch c1
+  $ echo d > d
+  $ hg ci -Am init
+  adding a
+  adding b1
+  adding c1
+  adding d
+  $ echo a > a
+  $ echo b > b1
+  $ hg mv b1 b2
+  $ echo c > c1
+  $ hg copy c1 c2
+  $ rm d
+  $ touch d
+  $ hg diff --git
+  diff --git a/a b/a
+  --- a/a
+  +++ b/a
+  @@ -0,0 +1,1 @@
+  +a
+  diff --git a/b1 b/b2
+  rename from b1
+  rename to b2
+  --- a/b1
+  +++ b/b2
+  @@ -0,0 +1,1 @@
+  +b
+  diff --git a/c1 b/c1
+  --- a/c1
+  +++ b/c1
+  @@ -0,0 +1,1 @@
+  +c
+  diff --git a/c1 b/c2
+  copy from c1
+  copy to c2
+  --- a/c1
+  +++ b/c2
+  @@ -0,0 +1,1 @@
+  +c
+  diff --git a/d b/d
+  --- a/d
+  +++ b/d
+  @@ -1,1 +0,0 @@
+  -d
+  $ hg ci -m empty
+  $ hg export --git tip > empty.diff
+  $ hg up -C 0
+  4 files updated, 0 files merged, 2 files removed, 0 files unresolved
+  $ hg import empty.diff
+  applying empty.diff
+  $ for name in a b1 b2 c1 c2 d; do
+  >   echo % $name file
+  >   test -f $name && cat $name
+  >   done
+  % a file
+  a
+  % b1 file
+  % b2 file
+  b
+  % c1 file
+  c
+  % c2 file
+  c
+  % d file
+  $ cd ..
+
+
+Test importing a patch ending with a binary file removal
+
+  $ hg init binaryremoval
+  $ cd binaryremoval
+  $ echo a > a
+  $ python -c "file('b', 'wb').write('a\x00b')"
+  $ hg ci -Am addall
+  adding a
+  adding b
+  $ hg rm a
+  $ hg rm b
+  $ hg st
+  R a
+  R b
+  $ hg ci -m remove
+  $ hg export --git . > remove.diff
+  $ cat remove.diff | grep git
+  diff --git a/a b/a
+  diff --git a/b b/b
+  $ hg up -C 0
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg import remove.diff
+  applying remove.diff
+  $ hg manifest
+  $ cd ..
+
+
+test update+rename with common name (issue 927)
+
+  $ hg init t
+  $ cd t
+  $ touch a
+  $ hg ci -Am t
+  adding a
+  $ echo a > a
+
+Here, bfile.startswith(afile)
+
+  $ hg copy a a2
+  $ hg ci -m copya
+  $ hg export --git tip > copy.diff
+  $ hg up -C 0
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg import copy.diff
+  applying copy.diff
+
+a should contain an 'a'
+
+  $ cat a
+  a
+
+and a2 should have duplicated it
+
+  $ cat a2
+  a
+  $ cd ..
+
+
+test -p0
+
+  $ hg init p0
+  $ cd p0
+  $ echo a > a
+  $ hg ci -Am t
+  adding a
+  $ hg import -p0 - << EOF
+  > foobar
+  > --- a	Sat Apr 12 22:43:58 2008 -0400
+  > +++ a	Sat Apr 12 22:44:05 2008 -0400
+  > @@ -1,1 +1,1 @@
+  > -a
+  > +bb
+  > EOF
+  applying patch from stdin
+  $ hg status
+  $ cat a
+  bb
+  $ cd ..
+
+
+test paths outside repo root
+
+  $ mkdir outside
+  $ touch outside/foo
+  $ hg init inside
+  $ cd inside
+  $ hg import - <<EOF
+  > diff --git a/a b/b
+  > rename from ../outside/foo
+  > rename to bar
+  > EOF
+  applying patch from stdin
+  abort: ../outside/foo not under root
+  $ cd ..
+
+
+test import with similarity and git and strip (issue295 et al.)
+
+  $ hg init sim
+  $ cd sim
+  $ echo 'this is a test' > a
+  $ hg ci -Ama
+  adding a
+  $ cat > ../rename.diff <<EOF
+  > diff --git a/foo/a b/foo/a
+  > deleted file mode 100644
+  > --- a/foo/a
+  > +++ /dev/null
+  > @@ -1,1 +0,0 @@
+  > -this is a test
+  > diff --git a/foo/b b/foo/b
+  > new file mode 100644
+  > --- /dev/null
+  > +++ b/foo/b
+  > @@ -0,0 +1,2 @@
+  > +this is a test
+  > +foo
+  > EOF
+  $ hg import --no-commit -v -s 1 ../rename.diff -p2
+  applying ../rename.diff
+  patching file a
+  patching file b
+  removing a
+  adding b
+  recording removal of a as rename to b (88% similar)
+  $ hg st -C
+  A b
+    a
+  R a
+  $ hg revert -a
+  undeleting a
+  forgetting b
+  $ rm b
+  $ hg import --no-commit -v -s 100 ../rename.diff -p2
+  applying ../rename.diff
+  patching file a
+  patching file b
+  removing a
+  adding b
+  $ hg st -C
+  A b
+  R a
+  $ cd ..
+
+
+add empty file from the end of patch (issue 1495)
+
+  $ hg init addemptyend
+  $ cd addemptyend
+  $ touch a
+  $ hg addremove
+  adding a
+  $ hg ci -m "commit"
+  $ cat > a.patch <<EOF
+  > diff --git a/a b/a
+  > --- a/a
+  > +++ b/a
+  > @@ -0,0 +1,1 @@
+  > +a
+  > diff --git a/b b/b
+  > new file mode 100644
+  > EOF
+  $ hg import --no-commit a.patch
+  applying a.patch
+  $ cd ..
+
+
+create file when source is not /dev/null
+
+  $ cat > create.patch <<EOF
+  > diff -Naur proj-orig/foo proj-new/foo
+  > --- proj-orig/foo       1969-12-31 16:00:00.000000000 -0800
+  > +++ proj-new/foo        2009-07-17 16:50:45.801368000 -0700
+  > @@ -0,0 +1,1 @@
+  > +a
+  > EOF
+
+some people have patches like the following too
+
+  $ cat > create2.patch <<EOF
+  > diff -Naur proj-orig/foo proj-new/foo
+  > --- proj-orig/foo.orig  1969-12-31 16:00:00.000000000 -0800
+  > +++ proj-new/foo        2009-07-17 16:50:45.801368000 -0700
+  > @@ -0,0 +1,1 @@
+  > +a
+  > EOF
+  $ hg init oddcreate
+  $ cd oddcreate
+  $ hg import --no-commit ../create.patch
+  applying ../create.patch
+  $ cat foo
+  a
+  $ rm foo
+  $ hg revert foo
+  $ hg import --no-commit ../create2.patch
+  applying ../create2.patch
+  $ cat foo
+  a
+
+
+first line mistaken for email headers (issue 1859)
+
+  $ hg init emailconfusion
+  $ cd emailconfusion
+  $ cat > a.patch <<EOF
+  > module: summary
+  > 
+  > description
+  > 
+  > 
+  > diff -r 000000000000 -r 9b4c1e343b55 test.txt
+  > --- /dev/null
+  > +++ b/a
+  > @@ -0,0 +1,1 @@
+  > +a
+  > EOF
+  $ hg import -d '0 0' a.patch
+  applying a.patch
+  $ hg parents -v
+  changeset:   0:5a681217c0ad
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  files:       a
+  description:
+  module: summary
+  
+  description
+  
+  
+  $ cd ..
+
+
+--- in commit message
+
+  $ hg init commitconfusion
+  $ cd commitconfusion
+  $ cat > a.patch <<EOF
+  > module: summary
+  > 
+  > --- description
+  > 
+  > diff --git a/a b/a
+  > new file mode 100644
+  > --- /dev/null
+  > +++ b/a
+  > @@ -0,0 +1,1 @@
+  > +a
+  > EOF
+  > hg import -d '0 0' a.patch
+  > hg parents -v
+  > cd ..
+  > 
+  > echo '% tricky header splitting'
+  > cat > trickyheaders.patch <<EOF
+  > From: User A <user@a>
+  > Subject: [PATCH] from: tricky!
+  > 
+  > # HG changeset patch
+  > # User User B
+  > # Date 1266264441 18000
+  > # Branch stable
+  > # Node ID f2be6a1170ac83bf31cb4ae0bad00d7678115bc0
+  > # Parent  0000000000000000000000000000000000000000
+  > from: tricky!
+  > 
+  > That is not a header.
+  > 
+  > diff -r 000000000000 -r f2be6a1170ac foo
+  > --- /dev/null
+  > +++ b/foo
+  > @@ -0,0 +1,1 @@
+  > +foo
+  > EOF
+  applying a.patch
+  changeset:   0:f34d9187897d
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  files:       a
+  description:
+  module: summary
+  
+  
+  % tricky header splitting
+
+  $ hg init trickyheaders
+  $ cd trickyheaders
+  $ hg import -d '0 0' ../trickyheaders.patch
+  applying ../trickyheaders.patch
+  $ hg export --git tip
+  # HG changeset patch
+  # User User B
+  # Date 0 0
+  # Node ID eb56ab91903632294ac504838508cb370c0901d2
+  # Parent  0000000000000000000000000000000000000000
+  from: tricky!
+  
+  That is not a header.
+  
+  diff --git a/foo b/foo
+  new file mode 100644
+  --- /dev/null
+  +++ b/foo
+  @@ -0,0 +1,1 @@
+  +foo
+  $ cd ..
+
+
+issue2102
+
+  $ hg init issue2102
+  $ cd issue2102
+  $ mkdir -p src/cmd/gc
+  $ touch src/cmd/gc/mksys.bash
+  $ hg ci -Am init
+  adding src/cmd/gc/mksys.bash
+  $ hg import - <<EOF
+  > # HG changeset patch
+  > # User Rob Pike
+  > # Date 1216685449 25200
+  > # Node ID 03aa2b206f499ad6eb50e6e207b9e710d6409c98
+  > # Parent  93d10138ad8df586827ca90b4ddb5033e21a3a84
+  > help management of empty pkg and lib directories in perforce
+  > 
+  > R=gri
+  > DELTA=4  (4 added, 0 deleted, 0 changed)
+  > OCL=13328
+  > CL=13328
+  > 
+  > diff --git a/lib/place-holder b/lib/place-holder
+  > new file mode 100644
+  > --- /dev/null
+  > +++ b/lib/place-holder
+  > @@ -0,0 +1,2 @@
+  > +perforce does not maintain empty directories.
+  > +this file helps.
+  > diff --git a/pkg/place-holder b/pkg/place-holder
+  > new file mode 100644
+  > --- /dev/null
+  > +++ b/pkg/place-holder
+  > @@ -0,0 +1,2 @@
+  > +perforce does not maintain empty directories.
+  > +this file helps.
+  > diff --git a/src/cmd/gc/mksys.bash b/src/cmd/gc/mksys.bash
+  > old mode 100644
+  > new mode 100755
+  > EOF
+  applying patch from stdin
+  $ hg sum
+  parent: 1:d59915696727 tip
+   help management of empty pkg and lib directories in perforce
+  branch: default
+  commit: (clean)
+  update: (current)
+  $ hg diff --git -c tip
+  diff --git a/lib/place-holder b/lib/place-holder
+  new file mode 100644
+  --- /dev/null
+  +++ b/lib/place-holder
+  @@ -0,0 +1,2 @@
+  +perforce does not maintain empty directories.
+  +this file helps.
+  diff --git a/pkg/place-holder b/pkg/place-holder
+  new file mode 100644
+  --- /dev/null
+  +++ b/pkg/place-holder
+  @@ -0,0 +1,2 @@
+  +perforce does not maintain empty directories.
+  +this file helps.
+  diff --git a/src/cmd/gc/mksys.bash b/src/cmd/gc/mksys.bash
+  old mode 100644
+  new mode 100755
+  $ cd ..
+
+
+diff lines looking like headers
+
+  $ hg init difflineslikeheaders
+  $ cd difflineslikeheaders
+  $ echo a >a
+  $ echo b >b
+  $ echo c >c
+  $ hg ci -Am1
+  adding a
+  adding b
+  adding c
+
+  $ echo "key: value" >>a
+  $ echo "key: value" >>b
+  $ echo "foo" >>c
+  $ hg ci -m2
+
+  $ hg up -C 0
+  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg diff --git -c1 >want
+  $ hg diff -c1 | hg import --no-commit -
+  applying patch from stdin
+  $ hg diff --git >have
+  $ diff want have
+  $ cd ..
+
--- a/tests/test-init	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,89 +0,0 @@
-#!/bin/sh
-
-# This test tries to exercise the ssh functionality with a dummy script
-
-cat <<EOF > dummyssh
-import sys
-import os
-
-os.chdir(os.path.dirname(sys.argv[0]))
-if sys.argv[1] != "user@dummy":
-    sys.exit(-1)
-
-if not os.path.exists("dummyssh"):
-    sys.exit(-1)
-
-log = open("dummylog", "ab")
-log.write("Got arguments")
-for i, arg in enumerate(sys.argv[1:]):
-    log.write(" %d:%s" % (i+1, arg))
-log.write("\n")
-log.close()
-r = os.system(sys.argv[2])
-sys.exit(bool(r))
-EOF
-
-checknewrepo()
-{
-    name=$1
-
-    if [ -d $name/.hg/store ]; then
-	echo store created
-    fi
-
-    if [ -f $name/.hg/00changelog.i ]; then
-	echo 00changelog.i created
-    fi
-
-    cat $name/.hg/requires
-}
-
-echo "# creating 'local'"
-hg init local
-checknewrepo local
-echo this > local/foo
-hg ci --cwd local -A -m "init" -d "1000000 0"
-
-echo "# creating repo with format.usestore=false"
-hg --config format.usestore=false init old
-checknewrepo old
-
-echo "# creating repo with format.usefncache=false"
-hg --config format.usefncache=false init old2
-checknewrepo old2
-
-echo "#test failure"
-hg init local
-
-echo "# init+push to remote2"
-hg init -e "python ./dummyssh" ssh://user@dummy/remote2
-hg incoming -R remote2 local
-hg push -R local -e "python ./dummyssh" ssh://user@dummy/remote2
-
-echo "# clone to remote1"
-hg clone -e "python ./dummyssh" local ssh://user@dummy/remote1
-
-echo "# init to existing repo"
-hg init -e "python ./dummyssh" ssh://user@dummy/remote1
-
-echo "# clone to existing repo"
-hg clone -e "python ./dummyssh" local ssh://user@dummy/remote1
-
-echo "# output of dummyssh"
-cat dummylog
-
-echo "# comparing repositories"
-hg tip -q -R local
-hg tip -q -R remote1
-hg tip -q -R remote2
-
-echo "# check names for repositories (clashes with URL schemes, special chars)"
-for i in bundle file hg http https old-http ssh static-http " " "with space"; do
-  echo "# hg init \"$i\""
-  hg init "$i"
-  test -d "$i" -a -d "$i/.hg" && echo "ok" || echo "failed"
-done
-
-echo "# creating 'local/sub/repo'"
-hg init local/sub/repo
-checknewrepo local/sub/repo
--- a/tests/test-init.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,81 +0,0 @@
-# creating 'local'
-store created
-00changelog.i created
-revlogv1
-store
-fncache
-adding foo
-# creating repo with format.usestore=false
-revlogv1
-# creating repo with format.usefncache=false
-store created
-00changelog.i created
-revlogv1
-store
-#test failure
-abort: repository local already exists!
-# init+push to remote2
-comparing with local
-changeset:   0:c4e059d443be
-tag:         tip
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     init
-
-pushing to ssh://user@dummy/remote2
-searching for changes
-remote: adding changesets
-remote: adding manifests
-remote: adding file changes
-remote: added 1 changesets with 1 changes to 1 files
-# clone to remote1
-searching for changes
-remote: adding changesets
-remote: adding manifests
-remote: adding file changes
-remote: added 1 changesets with 1 changes to 1 files
-# init to existing repo
-abort: repository remote1 already exists!
-abort: could not create remote repo!
-# clone to existing repo
-abort: repository remote1 already exists!
-abort: could not create remote repo!
-# output of dummyssh
-Got arguments 1:user@dummy 2:hg init remote2
-Got arguments 1:user@dummy 2:hg -R remote2 serve --stdio
-Got arguments 1:user@dummy 2:hg -R remote2 serve --stdio
-Got arguments 1:user@dummy 2:hg init remote1
-Got arguments 1:user@dummy 2:hg -R remote1 serve --stdio
-Got arguments 1:user@dummy 2:hg init remote1
-Got arguments 1:user@dummy 2:hg init remote1
-# comparing repositories
-0:c4e059d443be
-0:c4e059d443be
-0:c4e059d443be
-# check names for repositories (clashes with URL schemes, special chars)
-# hg init "bundle"
-ok
-# hg init "file"
-ok
-# hg init "hg"
-ok
-# hg init "http"
-ok
-# hg init "https"
-ok
-# hg init "old-http"
-ok
-# hg init "ssh"
-ok
-# hg init "static-http"
-ok
-# hg init " "
-ok
-# hg init "with space"
-ok
-# creating 'local/sub/repo'
-store created
-00changelog.i created
-revlogv1
-store
-fncache
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-init.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,156 @@
+# This test tries to exercise the ssh functionality with a dummy script
+
+  $ cat <<EOF > dummyssh
+  > import sys
+  > import os
+  > 
+  > os.chdir(os.path.dirname(sys.argv[0]))
+  > if sys.argv[1] != "user@dummy":
+  >     sys.exit(-1)
+  > 
+  > if not os.path.exists("dummyssh"):
+  >     sys.exit(-1)
+  > 
+  > log = open("dummylog", "ab")
+  > log.write("Got arguments")
+  > for i, arg in enumerate(sys.argv[1:]):
+  >     log.write(" %d:%s" % (i+1, arg))
+  > log.write("\n")
+  > log.close()
+  > r = os.system(sys.argv[2])
+  > sys.exit(bool(r))
+  > EOF
+
+  $ checknewrepo()
+  > {
+  >    name=$1
+  >    if [ -d $name/.hg/store ]; then
+  >    echo store created
+  >    fi
+  >    if [ -f $name/.hg/00changelog.i ]; then
+  >    echo 00changelog.i created
+  >    fi
+  >    cat $name/.hg/requires
+  > }
+
+creating 'local'
+
+  $ hg init local
+  $ checknewrepo local
+  store created
+  00changelog.i created
+  revlogv1
+  store
+  fncache
+  $ echo this > local/foo
+  $ hg ci --cwd local -A -m "init" -d "1000000 0"
+  adding foo
+
+creating repo with format.usestore=false
+
+  $ hg --config format.usestore=false init old
+  $ checknewrepo old
+  revlogv1
+
+creating repo with format.usefncache=false
+
+  $ hg --config format.usefncache=false init old2
+  $ checknewrepo old2
+  store created
+  00changelog.i created
+  revlogv1
+  store
+
+test failure
+
+  $ hg init local
+  abort: repository local already exists!
+
+init+push to remote2
+
+  $ hg init -e "python ./dummyssh" ssh://user@dummy/remote2
+  $ hg incoming -R remote2 local
+  comparing with local
+  changeset:   0:c4e059d443be
+  tag:         tip
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     init
+  
+
+  $ hg push -R local -e "python ./dummyssh" ssh://user@dummy/remote2
+  pushing to ssh://user@dummy/remote2
+  searching for changes
+  remote: adding changesets
+  remote: adding manifests
+  remote: adding file changes
+  remote: added 1 changesets with 1 changes to 1 files
+
+clone to remote1
+
+  $ hg clone -e "python ./dummyssh" local ssh://user@dummy/remote1
+  searching for changes
+  remote: adding changesets
+  remote: adding manifests
+  remote: adding file changes
+  remote: added 1 changesets with 1 changes to 1 files
+
+init to existing repo
+
+  $ hg init -e "python ./dummyssh" ssh://user@dummy/remote1
+  abort: repository remote1 already exists!
+  abort: could not create remote repo!
+
+clone to existing repo
+
+  $ hg clone -e "python ./dummyssh" local ssh://user@dummy/remote1
+  abort: repository remote1 already exists!
+  abort: could not create remote repo!
+
+output of dummyssh
+
+  $ cat dummylog
+  Got arguments 1:user@dummy 2:hg init remote2
+  Got arguments 1:user@dummy 2:hg -R remote2 serve --stdio
+  Got arguments 1:user@dummy 2:hg -R remote2 serve --stdio
+  Got arguments 1:user@dummy 2:hg init remote1
+  Got arguments 1:user@dummy 2:hg -R remote1 serve --stdio
+  Got arguments 1:user@dummy 2:hg init remote1
+  Got arguments 1:user@dummy 2:hg init remote1
+
+comparing repositories
+
+  $ hg tip -q -R local
+  0:c4e059d443be
+  $ hg tip -q -R remote1
+  0:c4e059d443be
+  $ hg tip -q -R remote2
+  0:c4e059d443be
+
+check names for repositories (clashes with URL schemes, special chars)
+
+  $ for i in bundle file hg http https old-http ssh static-http " " "with space"; do
+  >   echo -n "hg init \"$i\"... "
+  >   hg init "$i"
+  >   test -d "$i" -a -d "$i/.hg" && echo "ok" || echo "failed"
+  > done
+  hg init "bundle"... ok
+  hg init "file"... ok
+  hg init "hg"... ok
+  hg init "http"... ok
+  hg init "https"... ok
+  hg init "old-http"... ok
+  hg init "ssh"... ok
+  hg init "static-http"... ok
+  hg init " "... ok
+  hg init "with space"... ok
+
+creating 'local/sub/repo'
+
+  $ hg init local/sub/repo
+  $ checknewrepo local/sub/repo
+  store created
+  00changelog.i created
+  revlogv1
+  store
+  fncache
--- a/tests/test-issue660	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-issue660	Sat Aug 14 03:30:35 2010 +0200
@@ -56,7 +56,7 @@
 echo a > a/a
 echo b > b
 
-hg addremove
+hg addremove -s 0
 hg st
 
 echo % commit
--- a/tests/test-log	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-log	Sat Aug 14 03:30:35 2010 +0200
@@ -62,6 +62,11 @@
 echo '% log -p d'
 hg log -pv d
 
+echo '% log --removed file'
+hg log --removed -v a
+echo '% log --removed revrange file'
+hg log --removed -v -r0:2 a
+
 # log --follow tests
 hg init ../follow
 cd ../follow
--- a/tests/test-log.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-log.out	Sat Aug 14 03:30:35 2010 +0200
@@ -196,6 +196,32 @@
 @@ -0,0 +1,1 @@
 +a
 
+% log --removed file
+changeset:   3:7c6c671bb7cc
+user:        test
+date:        Thu Jan 01 00:00:04 1970 +0000
+files:       a b d
+description:
+d
+
+
+changeset:   0:8580ff50825a
+user:        test
+date:        Thu Jan 01 00:00:01 1970 +0000
+files:       a
+description:
+a
+
+
+% log --removed revrange file
+changeset:   0:8580ff50825a
+user:        test
+date:        Thu Jan 01 00:00:01 1970 +0000
+files:       a
+description:
+a
+
+
 adding base
 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
 adding b1
--- a/tests/test-mq-guards	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-guards	Sat Aug 14 03:30:35 2010 +0200
@@ -97,11 +97,16 @@
 
 hg qguard -- a.patch +1 +2 -3
 hg qselect 1 2 3
+
 echo % list patches and guards
 hg qguard -l
+echo % have at least one patch applied to test coloring
+hg qpush
 echo % list patches and guards with color
 hg --config extensions.color= qguard --config color.mode=ansi \
     -l --color=always
+echo % should pop b.patch
+hg qpop
 echo % list series
 hg qseries -v
 echo % list guards
--- a/tests/test-mq-guards.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-guards.out	Sat Aug 14 03:30:35 2010 +0200
@@ -84,10 +84,16 @@
 a.patch: +1 +2 -3
 b.patch: +2
 c.patch: unguarded
+% have at least one patch applied to test coloring
+applying b.patch
+now at: b.patch
 % list patches and guards with color
-a.patch: +1 +2 -3
-b.patch: +2
-c.patch: unguarded
+a.patch: +1 +2 -3
+b.patch: +2
+c.patch: unguarded
+% should pop b.patch
+popping b.patch
+patch queue now empty
 % list series
 0 G a.patch
 1 U b.patch
--- a/tests/test-mq-qimport	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-qimport	Sat Aug 14 03:30:35 2010 +0200
@@ -109,3 +109,19 @@
 hg qimport --push another.diff
 hg qfin -a
 hg qimport -rtip -P
+
+hg qpop -a
+hg qdel -k 2.diff
+echo % qimport -e
+hg qimport -e 2.diff
+hg qdel -k 2.diff
+echo % qimport -e --name newname oldexisitingpatch
+hg qimport -e --name this-name-is-better 2.diff
+hg qser
+echo % qimport -e --name without --force
+cp .hg/patches/this-name-is-better .hg/patches/3.diff
+hg qimport -e --name this-name-is-better 3.diff
+hg qser
+echo % qimport -e --name with --force
+hg qimport --force -e --name this-name-is-better 3.diff
+hg qser
--- a/tests/test-mq-qimport.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-qimport.out	Sat Aug 14 03:30:35 2010 +0200
@@ -52,3 +52,21 @@
 now at: another.diff
 patch b.diff finalized without changeset message
 patch another.diff finalized without changeset message
+popping 2.diff
+patch queue now empty
+% qimport -e
+adding 2.diff to series file
+% qimport -e --name newname oldexisitingpatch
+renaming 2.diff to this-name-is-better
+adding this-name-is-better to series file
+this-name-is-better
+url.diff
+% qimport -e --name without --force
+abort: patch "this-name-is-better" already exists
+this-name-is-better
+url.diff
+% qimport -e --name with --force
+renaming 3.diff to this-name-is-better
+adding this-name-is-better to series file
+this-name-is-better
+url.diff
--- a/tests/test-mq-qnew	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-qnew	Sat Aug 14 03:30:35 2010 +0200
@@ -70,6 +70,10 @@
     HGUSER= hg qnew -u blue red
     catpatch ../.hg/patches/red
 
+    echo '% qnew -e -u with no username configured'
+    HGUSER= hg qnew -e -u chartreuse fucsia
+    catpatch ../.hg/patches/fucsia
+
     echo '% fail when trying to import a merge'
     hg init merge
     cd merge
--- a/tests/test-mq-qnew.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-qnew.out	Sat Aug 14 03:30:35 2010 +0200
@@ -42,6 +42,9 @@
 % qnew -u with no username configured
 From: blue
 
+% qnew -e -u with no username configured
+From: chartreuse
+
 % fail when trying to import a merge
 adding a
 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
@@ -101,6 +104,10 @@
 # HG changeset patch
 # Parent 
 # User blue
+% qnew -e -u with no username configured
+# HG changeset patch
+# Parent 
+# User chartreuse
 % fail when trying to import a merge
 adding a
 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
--- a/tests/test-mq-qqueue	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-qqueue	Sat Aug 14 03:30:35 2010 +0200
@@ -28,6 +28,9 @@
 hg qqueue foo
 hg qqueue
 
+echo %% list queues, quiet
+hg qqueue --quiet
+
 echo %% fail creating queue with already existing name
 hg qqueue --create foo
 hg qqueue
--- a/tests/test-mq-qqueue.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-qqueue.out	Sat Aug 14 03:30:35 2010 +0200
@@ -12,6 +12,9 @@
 %% switch queue
 foo (active)
 patches
+%% list queues, quiet
+foo
+patches
 %% fail creating queue with already existing name
 abort: queue "foo" already exists
 foo (active)
--- a/tests/test-mq-strip	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-strip	Sat Aug 14 03:30:35 2010 +0200
@@ -4,16 +4,20 @@
 
 echo "[extensions]" >> $HGRCPATH
 echo "mq=" >> $HGRCPATH
+echo "graphlog=" >> $HGRCPATH
 
+restore() {
+    hg unbundle -q .hg/strip-backup/*
+    rm .hg/strip-backup/*
+}
 teststrip() {
     hg up -C $1
     echo % before update $1, strip $2
     hg parents
-    hg strip $2 | hidebackup
+    hg --traceback strip $2 | hidebackup
     echo % after update $1, strip $2
     hg parents
-    hg unbundle -q .hg/strip-backup/*
-    rm .hg/strip-backup/*
+    restore
 }
 
 hg init test
@@ -53,6 +57,25 @@
 hg strip 4 2>&1 | hidebackup
 echo % after strip of merge parent
 hg parents
+restore
+
+hg up
+hg glog
+echo % 2 is parent of 3, only one strip should happen
+hg strip 2 3 | hidebackup
+hg glog
+restore
+hg glog
+echo % 2 different branches: 2 strips
+hg strip 2 4 | hidebackup
+hg glog
+restore
+echo % 2 different branches and a common ancestor: 1 strip
+hg strip 1 2 4 | hidebackup
+restore
+
+# remove branchy history for qimport tests
+hg strip 3 | hidebackup
 
 #strip of applied mq should cleanup status file
 hg up -C 3
--- a/tests/test-mq-strip.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq-strip.out	Sat Aug 14 03:30:35 2010 +0200
@@ -166,6 +166,103 @@
 summary:     b
 
 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+@  changeset:   4:264128213d29
+|  tag:         tip
+|  parent:      1:ef3a871183d7
+|  user:        test
+|  date:        Thu Jan 01 00:00:00 1970 +0000
+|  summary:     c
+|
+| o  changeset:   3:443431ffac4f
+| |  user:        test
+| |  date:        Thu Jan 01 00:00:00 1970 +0000
+| |  summary:     e
+| |
+| o  changeset:   2:65bd5f99a4a3
+|/   user:        test
+|    date:        Thu Jan 01 00:00:00 1970 +0000
+|    summary:     d
+|
+o  changeset:   1:ef3a871183d7
+|  user:        test
+|  date:        Thu Jan 01 00:00:00 1970 +0000
+|  summary:     b
+|
+o  changeset:   0:9ab35a2d17cb
+   user:        test
+   date:        Thu Jan 01 00:00:00 1970 +0000
+   summary:     a
+
+% 2 is parent of 3, only one strip should happen
+saved backup bundle to 
+@  changeset:   2:264128213d29
+|  tag:         tip
+|  user:        test
+|  date:        Thu Jan 01 00:00:00 1970 +0000
+|  summary:     c
+|
+o  changeset:   1:ef3a871183d7
+|  user:        test
+|  date:        Thu Jan 01 00:00:00 1970 +0000
+|  summary:     b
+|
+o  changeset:   0:9ab35a2d17cb
+   user:        test
+   date:        Thu Jan 01 00:00:00 1970 +0000
+   summary:     a
+
+o  changeset:   4:443431ffac4f
+|  tag:         tip
+|  user:        test
+|  date:        Thu Jan 01 00:00:00 1970 +0000
+|  summary:     e
+|
+o  changeset:   3:65bd5f99a4a3
+|  parent:      1:ef3a871183d7
+|  user:        test
+|  date:        Thu Jan 01 00:00:00 1970 +0000
+|  summary:     d
+|
+| @  changeset:   2:264128213d29
+|/   user:        test
+|    date:        Thu Jan 01 00:00:00 1970 +0000
+|    summary:     c
+|
+o  changeset:   1:ef3a871183d7
+|  user:        test
+|  date:        Thu Jan 01 00:00:00 1970 +0000
+|  summary:     b
+|
+o  changeset:   0:9ab35a2d17cb
+   user:        test
+   date:        Thu Jan 01 00:00:00 1970 +0000
+   summary:     a
+
+% 2 different branches: 2 strips
+0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+saved backup bundle to 
+saved backup bundle to 
+@  changeset:   2:65bd5f99a4a3
+|  tag:         tip
+|  user:        test
+|  date:        Thu Jan 01 00:00:00 1970 +0000
+|  summary:     d
+|
+o  changeset:   1:ef3a871183d7
+|  user:        test
+|  date:        Thu Jan 01 00:00:00 1970 +0000
+|  summary:     b
+|
+o  changeset:   0:9ab35a2d17cb
+   user:        test
+   date:        Thu Jan 01 00:00:00 1970 +0000
+   summary:     a
+
+% 2 different branches and a common ancestor: 1 strip
+1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+saved backup bundle to 
+saved backup bundle to 
+1 files updated, 0 files merged, 0 files removed, 0 files unresolved
 % applied patches before strip
 2.diff
 3.diff
--- a/tests/test-mq.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-mq.out	Sat Aug 14 03:30:35 2010 +0200
@@ -59,7 +59,7 @@
  qseries      print the entire series file
  qtop         print the name of the current patch
  qunapplied   print the patches not yet applied
- strip        strip a changeset and all its descendants from the repository
+ strip        strip changesets and all their descendants from the repository
 
 use "hg -v help mq" to show aliases and global options
 adding a
--- a/tests/test-parents	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,67 +0,0 @@
-#!/bin/sh
-# test parents command
-
-hg init repo
-cd repo
-echo % no working directory
-hg parents
-
-echo a > a
-echo b > b
-hg ci -Amab -d '0 0'
-echo a >> a
-hg ci -Ama -d '1 0'
-echo b >> b
-hg ci -Amb -d '2 0'
-echo c > c
-hg ci -Amc -d '3 0'
-hg up -C 1
-echo d > c
-hg ci -Amc2 -d '4 0'
-hg up -C 3
-
-echo % hg parents
-hg parents
-
-echo % hg parents a
-hg parents a
-
-echo % hg parents c, single revision
-hg parents c
-
-echo % hg parents -r 3 c
-hg parents -r 3 c
-
-echo % hg parents -r 2
-hg parents -r 2
-
-echo % hg parents -r 2 a
-hg parents -r 2 a
-
-echo % hg parents -r 2 ../a
-hg parents -r 2 ../a
-
-echo '% cd dir; hg parents -r 2 ../a'
-mkdir dir
-cd dir
-hg parents -r 2 ../a
-
-echo '% hg parents -r 2 path:a'
-hg parents -r 2 path:a
-
-echo '% hg parents -r 2 glob:a'
-cd ..
-hg parents -r 2 glob:a
-
-echo % merge working dir with 2 parents, hg parents c
-HGMERGE=true hg merge
-hg parents c
-
-echo % merge working dir with 1 parent, hg parents
-hg up -C 2
-HGMERGE=true hg merge -r 4
-hg parents
-echo % merge working dir with 1 parent, hg parents c
-hg parents c
-
-true
--- a/tests/test-parents.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,96 +0,0 @@
-% no working directory
-adding a
-adding b
-adding c
-1 files updated, 0 files merged, 1 files removed, 0 files unresolved
-adding c
-created new head
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-% hg parents
-changeset:   3:02d851b7e549
-user:        test
-date:        Thu Jan 01 00:00:03 1970 +0000
-summary:     c
-
-% hg parents a
-changeset:   1:d786049f033a
-user:        test
-date:        Thu Jan 01 00:00:01 1970 +0000
-summary:     a
-
-% hg parents c, single revision
-changeset:   3:02d851b7e549
-user:        test
-date:        Thu Jan 01 00:00:03 1970 +0000
-summary:     c
-
-% hg parents -r 3 c
-abort: 'c' not found in manifest!
-% hg parents -r 2
-changeset:   1:d786049f033a
-user:        test
-date:        Thu Jan 01 00:00:01 1970 +0000
-summary:     a
-
-% hg parents -r 2 a
-changeset:   1:d786049f033a
-user:        test
-date:        Thu Jan 01 00:00:01 1970 +0000
-summary:     a
-
-% hg parents -r 2 ../a
-abort: ../a not under root
-% cd dir; hg parents -r 2 ../a
-changeset:   1:d786049f033a
-user:        test
-date:        Thu Jan 01 00:00:01 1970 +0000
-summary:     a
-
-% hg parents -r 2 path:a
-changeset:   1:d786049f033a
-user:        test
-date:        Thu Jan 01 00:00:01 1970 +0000
-summary:     a
-
-% hg parents -r 2 glob:a
-abort: can only specify an explicit filename
-% merge working dir with 2 parents, hg parents c
-merging c
-0 files updated, 1 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-changeset:   3:02d851b7e549
-user:        test
-date:        Thu Jan 01 00:00:03 1970 +0000
-summary:     c
-
-changeset:   4:48cee28d4b4e
-tag:         tip
-parent:      1:d786049f033a
-user:        test
-date:        Thu Jan 01 00:00:04 1970 +0000
-summary:     c2
-
-% merge working dir with 1 parent, hg parents
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-changeset:   2:6cfac479f009
-user:        test
-date:        Thu Jan 01 00:00:02 1970 +0000
-summary:     b
-
-changeset:   4:48cee28d4b4e
-tag:         tip
-parent:      1:d786049f033a
-user:        test
-date:        Thu Jan 01 00:00:04 1970 +0000
-summary:     c2
-
-% merge working dir with 1 parent, hg parents c
-changeset:   4:48cee28d4b4e
-tag:         tip
-parent:      1:d786049f033a
-user:        test
-date:        Thu Jan 01 00:00:04 1970 +0000
-summary:     c2
-
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-parents.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,149 @@
+test parents command
+
+  $ hg init repo
+  $ cd repo
+
+no working directory
+
+  $ hg parents
+
+  $ echo a > a
+  $ echo b > b
+  $ hg ci -Amab -d '0 0'
+  adding a
+  adding b
+  $ echo a >> a
+  $ hg ci -Ama -d '1 0'
+  $ echo b >> b
+  $ hg ci -Amb -d '2 0'
+  $ echo c > c
+  $ hg ci -Amc -d '3 0'
+  adding c
+  $ hg up -C 1
+  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ echo d > c
+  $ hg ci -Amc2 -d '4 0'
+  adding c
+  created new head
+  $ hg up -C 3
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+
+  $ hg parents
+  changeset:   3:02d851b7e549
+  user:        test
+  date:        Thu Jan 01 00:00:03 1970 +0000
+  summary:     c
+  
+
+  $ hg parents a
+  changeset:   1:d786049f033a
+  user:        test
+  date:        Thu Jan 01 00:00:01 1970 +0000
+  summary:     a
+  
+
+hg parents c, single revision
+
+  $ hg parents c
+  changeset:   3:02d851b7e549
+  user:        test
+  date:        Thu Jan 01 00:00:03 1970 +0000
+  summary:     c
+  
+
+  $ hg parents -r 3 c
+  abort: 'c' not found in manifest!
+
+  $ hg parents -r 2
+  changeset:   1:d786049f033a
+  user:        test
+  date:        Thu Jan 01 00:00:01 1970 +0000
+  summary:     a
+  
+
+  $ hg parents -r 2 a
+  changeset:   1:d786049f033a
+  user:        test
+  date:        Thu Jan 01 00:00:01 1970 +0000
+  summary:     a
+  
+
+  $ hg parents -r 2 ../a
+  abort: ../a not under root
+
+
+cd dir; hg parents -r 2 ../a
+
+  $ mkdir dir
+  $ cd dir
+  $ hg parents -r 2 ../a
+  changeset:   1:d786049f033a
+  user:        test
+  date:        Thu Jan 01 00:00:01 1970 +0000
+  summary:     a
+  
+  $ hg parents -r 2 path:a
+  changeset:   1:d786049f033a
+  user:        test
+  date:        Thu Jan 01 00:00:01 1970 +0000
+  summary:     a
+  
+  $ cd ..
+
+  $ hg parents -r 2 glob:a
+  abort: can only specify an explicit filename
+
+
+merge working dir with 2 parents, hg parents c
+
+  $ HGMERGE=true hg merge
+  merging c
+  0 files updated, 1 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg parents c
+  changeset:   3:02d851b7e549
+  user:        test
+  date:        Thu Jan 01 00:00:03 1970 +0000
+  summary:     c
+  
+  changeset:   4:48cee28d4b4e
+  tag:         tip
+  parent:      1:d786049f033a
+  user:        test
+  date:        Thu Jan 01 00:00:04 1970 +0000
+  summary:     c2
+  
+
+
+merge working dir with 1 parent, hg parents
+
+  $ hg up -C 2
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ HGMERGE=true hg merge -r 4
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg parents
+  changeset:   2:6cfac479f009
+  user:        test
+  date:        Thu Jan 01 00:00:02 1970 +0000
+  summary:     b
+  
+  changeset:   4:48cee28d4b4e
+  tag:         tip
+  parent:      1:d786049f033a
+  user:        test
+  date:        Thu Jan 01 00:00:04 1970 +0000
+  summary:     c2
+  
+
+merge working dir with 1 parent, hg parents c
+
+  $ hg parents c
+  changeset:   4:48cee28d4b4e
+  tag:         tip
+  parent:      1:d786049f033a
+  user:        test
+  date:        Thu Jan 01 00:00:04 1970 +0000
+  summary:     c2
+  
--- a/tests/test-patch	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,36 +0,0 @@
-#!/bin/sh
-
-cat > patchtool.py <<EOF
-import sys
-print 'Using custom patch'
-if '--binary' in sys.argv:
-    print '--binary found !'
-EOF
-
-echo "[ui]" >> $HGRCPATH
-echo "patch=python ../patchtool.py" >> $HGRCPATH
-
-hg init a
-cd a
-echo a > a
-hg commit -Ama -d '1 0'
-echo b >> a
-hg commit -Amb -d '2 0'
-cd ..
-
-# This test check that:
-# - custom patch commands with arguments actually works
-# - patch code does not try to add weird arguments like
-# --binary when custom patch commands are used. For instance
-# --binary is added by default under win32.
-
-echo % check custom patch options are honored
-hg --cwd a export -o ../a.diff tip
-hg clone -r 0 a b
-
-hg --cwd b import -v ../a.diff
-
-
-
-
-
--- a/tests/test-patch.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,11 +0,0 @@
-adding a
-% check custom patch options are honored
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying ../a.diff
-Using custom patch
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-patch.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,41 @@
+  $ cat > patchtool.py <<EOF
+  > import sys
+  > print 'Using custom patch'
+  > if '--binary' in sys.argv:
+  >     print '--binary found !'
+  > EOF
+
+  $ echo "[ui]" >> $HGRCPATH
+  $ echo "patch=python ../patchtool.py" >> $HGRCPATH
+
+  $ hg init a
+  $ cd a
+  $ echo a > a
+  $ hg commit -Ama -d '1 0'
+  adding a
+  $ echo b >> a
+  $ hg commit -Amb -d '2 0'
+  $ cd ..
+
+This test checks that:
+ - custom patch commands with arguments actually work
+ - patch code does not try to add weird arguments like
+ --binary when custom patch commands are used. For instance
+ --binary is added by default under win32.
+
+check custom patch options are honored
+
+  $ hg --cwd a export -o ../a.diff tip
+  $ hg clone -r 0 a b
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+  $ hg --cwd b import -v ../a.diff
+  applying ../a.diff
+  Using custom patch
+
--- a/tests/test-paths	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,10 +0,0 @@
-#!/bin/sh
-hg init a
-hg clone a b
-cd a
-echo '[paths]' >> .hg/hgrc
-echo 'dupe = ../b' >> .hg/hgrc
-hg in dupe | fgrep '../'
-cd ..
-hg -R a in dupe | fgrep '../'
-true
--- a/tests/test-paths.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,2 +0,0 @@
-updating to branch default
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-paths.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,15 @@
+  $ hg init a
+  $ hg clone a b
+  updating to branch default
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd a
+  $ echo '[paths]' >> .hg/hgrc
+  $ echo 'dupe = ../b' >> .hg/hgrc
+  $ hg in dupe
+  comparing with .*/test-paths.t/b
+  no changes found
+  $ cd ..
+  $ hg -R a in dupe
+  comparing with .*/test-paths.t/b
+  no changes found
+  $ true
--- a/tests/test-permissions	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-permissions	Sat Aug 14 03:30:35 2010 +0200
@@ -1,27 +1,37 @@
 #!/bin/sh
 
+echo '% hg init t'
 hg init t
 cd t
 echo foo > a
+echo '% hg add a'
 hg add a
+echo '% hg commit'
 hg commit -m "1" -d "1000000 0"
+echo '% hg verify'
 hg verify
 chmod -r .hg/store/data/a.i
+echo '% hg verify'
 hg verify 2>/dev/null || echo verify failed
 chmod +r .hg/store/data/a.i
+echo '% hg verify'
 hg verify 2>/dev/null || echo verify failed
 chmod -w .hg/store/data/a.i
 echo barber > a
+echo '% hg commit'
 hg commit -m "2" -d "1000000 0" 2>/dev/null || echo commit failed
 chmod -w .
+echo '% hg diff'
 hg diff --nodates
 chmod +w .
 
 chmod +w .hg/store/data/a.i
 mkdir dir
 touch dir/a
+echo '% hg status'
 hg status
 chmod -rx dir
+echo '% hg status'
 hg status
 # reenable perm to allow deletion
 chmod +rx dir
--- a/tests/test-permissions.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-permissions.out	Sat Aug 14 03:30:35 2010 +0200
@@ -1,26 +1,36 @@
+% hg init t
+% hg add a
+% hg commit
+% hg verify
 checking changesets
 checking manifests
 crosschecking files in changesets and manifests
 checking files
 1 files, 1 changesets, 1 total revisions
+% hg verify
 checking changesets
 checking manifests
 crosschecking files in changesets and manifests
 checking files
 verify failed
+% hg verify
 checking changesets
 checking manifests
 crosschecking files in changesets and manifests
 checking files
 1 files, 1 changesets, 1 total revisions
+% hg commit
 commit failed
+% hg diff
 diff -r c1fab96507ef a
 --- a/a
 +++ b/a
 @@ -1,1 +1,1 @@
 -foo
 +barber
+% hg status
 M a
 ? dir/a
+% hg status
 dir: Permission denied
 M a
--- a/tests/test-push-warn.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-push-warn.out	Sat Aug 14 03:30:35 2010 +0200
@@ -37,7 +37,7 @@
 searching for changes
 abort: push creates new remote heads on branch 'default'!
 (did you forget to merge? use push -f to force)
-1
+255
 pushing to ../c
 searching for changes
 no changes found
@@ -46,12 +46,12 @@
 searching for changes
 abort: push creates new remote heads on branch 'default'!
 (did you forget to merge? use push -f to force)
-1
+255
 pushing to ../c
 searching for changes
 abort: push creates new remote heads on branch 'default'!
 (did you forget to merge? use push -f to force)
-1
+255
 pushing to ../c
 searching for changes
 adding changesets
@@ -90,29 +90,29 @@
 searching for changes
 abort: push creates new remote branches: c!
 (use 'hg push --new-branch' to create new remote branches)
-1
+255
 pushing to ../f
 searching for changes
 abort: push creates new remote branches: c!
 (use 'hg push --new-branch' to create new remote branches)
-1
+255
 % multiple new branches
 pushing to ../f
 searching for changes
 abort: push creates new remote branches: c, d!
 (use 'hg push --new-branch' to create new remote branches)
-1
+255
 pushing to ../f
 searching for changes
 abort: push creates new remote branches: c, d!
 (use 'hg push --new-branch' to create new remote branches)
-1
+255
 % fail on multiple head push
 pushing to ../f
 searching for changes
 abort: push creates new remote heads on branch 'a'!
 (did you forget to merge? use push -f to force)
-1
+255
 % push replacement head on existing branches
 pushing to ../f
 searching for changes
@@ -149,7 +149,7 @@
 searching for changes
 abort: push creates new remote branches: e!
 (use 'hg push --new-branch' to create new remote branches)
-1
+255
 % using --new-branch to push new named branch
 pushing to ../f
 searching for changes
--- a/tests/test-qrecord.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-qrecord.out	Sat Aug 14 03:30:35 2010 +0200
@@ -81,7 +81,7 @@
  up
 % qrecord a.patch
 diff --git a/1.txt b/1.txt
-2 hunks, 4 lines changed
+2 hunks, 2 lines changed
 examine changes to '1.txt'? [Ynsfdaq?] 
 @@ -1,3 +1,3 @@
  1
@@ -96,7 +96,7 @@
  5
 record change 2/6 to '1.txt'? [Ynsfdaq?] 
 diff --git a/2.txt b/2.txt
-1 hunks, 2 lines changed
+1 hunks, 1 lines changed
 examine changes to '2.txt'? [Ynsfdaq?] 
 @@ -1,5 +1,5 @@
  a
@@ -107,7 +107,7 @@
  e
 record change 4/6 to '2.txt'? [Ynsfdaq?] 
 diff --git a/dir/a.txt b/dir/a.txt
-1 hunks, 2 lines changed
+1 hunks, 1 lines changed
 examine changes to 'dir/a.txt'? [Ynsfdaq?] 
 
 % after qrecord a.patch 'tip'
@@ -164,7 +164,7 @@
  up
 % qrecord b.patch
 diff --git a/1.txt b/1.txt
-1 hunks, 2 lines changed
+1 hunks, 1 lines changed
 examine changes to '1.txt'? [Ynsfdaq?] 
 @@ -1,5 +1,5 @@
  1
@@ -175,7 +175,7 @@
  5
 record change 1/3 to '1.txt'? [Ynsfdaq?] 
 diff --git a/dir/a.txt b/dir/a.txt
-1 hunks, 2 lines changed
+1 hunks, 1 lines changed
 examine changes to 'dir/a.txt'? [Ynsfdaq?] 
 @@ -1,4 +1,4 @@
 -hello world
--- a/tests/test-record.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-record.out	Sat Aug 14 03:30:35 2010 +0200
@@ -222,7 +222,7 @@
 record this change to 'plain'? [Ynsfdaq?] 
 % modify end of plain file, add EOL
 diff --git a/plain b/plain
-1 hunks, 2 lines changed
+1 hunks, 1 lines changed
 examine changes to 'plain'? [Ynsfdaq?] 
 @@ -9,4 +9,4 @@
  9
@@ -234,7 +234,7 @@
 record this change to 'plain'? [Ynsfdaq?] 
 % modify beginning, trim end, record both
 diff --git a/plain b/plain
-2 hunks, 4 lines changed
+2 hunks, 3 lines changed
 examine changes to 'plain'? [Ynsfdaq?] 
 @@ -1,4 +1,4 @@
 -1
@@ -276,7 +276,7 @@
 % trim beginning, modify end
 % record end
 diff --git a/plain b/plain
-2 hunks, 5 lines changed
+2 hunks, 4 lines changed
 examine changes to 'plain'? [Ynsfdaq?] 
 @@ -1,9 +1,6 @@
 -2
--- a/tests/test-rename	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-rename	Sat Aug 14 03:30:35 2010 +0200
@@ -26,7 +26,7 @@
 
 echo '# rename --after a single file when src and tgt already tracked'
 mv d1/d11/a1 d2/c
-hg addrem
+hg addrem -s 0
 hg rename --after d1/d11/a1 d2/c
 hg status -C
 hg update -C
--- a/tests/test-revset	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-revset	Sat Aug 14 03:30:35 2010 +0200
@@ -110,6 +110,7 @@
 log 'keyword(issue)'
 log 'limit(head(), 1)'
 log 'max(contains(a))'
+log 'min(contains(a))'
 log 'merge()'
 log 'modifies(b)'
 log 'p1(merge())'
--- a/tests/test-revset.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-revset.out	Sat Aug 14 03:30:35 2010 +0200
@@ -152,6 +152,8 @@
 0
 % log 'max(contains(a))'
 5
+% log 'min(contains(a))'
+0
 % log 'merge()'
 6
 % log 'modifies(b)'
--- a/tests/test-status	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,117 +0,0 @@
-#!/bin/sh
-
-hg init repo1
-cd repo1
-mkdir a b a/1 b/1 b/2
-touch in_root a/in_a b/in_b a/1/in_a_1 b/1/in_b_1 b/2/in_b_2
-echo "hg status in repo root:"
-hg status
-echo "hg status . in repo root:"
-hg status .
-for dir in a b a/1 b/1 b/2; do
-    echo "hg status in $dir:"
-    hg status --cwd "$dir"
-    echo "hg status . in $dir:"
-    hg status --cwd "$dir" .
-    echo "hg status .. in $dir:"
-    hg status --cwd "$dir" ..
-done
-cd ..
-
-hg init repo2
-cd repo2
-touch modified removed deleted ignored
-echo "^ignored$" > .hgignore
-hg ci -A -m 'initial checkin' -d "1000000 0"
-touch modified added unknown ignored
-hg add added
-hg remove removed
-rm deleted
-echo "hg status:"
-hg status
-echo "hg status modified added removed deleted unknown never-existed ignored:"
-hg status modified added removed deleted unknown never-existed ignored
-hg copy modified copied
-echo "hg status -C:"
-hg status -C
-echo "hg status -A:"
-hg status -A
-echo "^ignoreddir$" > .hgignore
-mkdir ignoreddir
-touch ignoreddir/file
-echo "hg status ignoreddir/file:"
-hg status ignoreddir/file
-echo "hg status -i ignoreddir/file:"
-hg status -i ignoreddir/file
-cd ..
-
-# check 'status -q' and some combinations
-hg init repo3
-cd repo3
-touch modified removed deleted ignored
-echo "^ignored$" > .hgignore
-hg commit -A -m 'initial checkin'
-touch added unknown ignored
-hg add added
-echo "test" >> modified
-hg remove removed
-rm deleted
-hg copy modified copied
-
-# Run status with 2 different flags.
-# Check if result is the same or different.
-# If result is not as expected, raise error
-assert() {
-    hg status $1 > ../a
-    hg status $2 > ../b
-    out=`diff ../a ../b`
-    if [ $? -ne 0 ]; then
-        out=1
-    else
-        out=0
-    fi
-    if [ $3 -eq 0 ]; then
-        df="same"
-    else
-        df="different"
-    fi
-    if [ $out -ne $3 ]; then
-        echo "Error on $1 and $2, should be $df."
-    fi
-}
-
-# assert flag1 flag2 [0-same | 1-different]
-assert "-q" "-mard"      0
-assert "-A" "-marduicC"  0
-assert "-qA" "-mardcC"   0
-assert "-qAui" "-A"      0
-assert "-qAu" "-marducC" 0
-assert "-qAi" "-mardicC" 0
-assert "-qu" "-u"        0
-assert "-q" "-u"         1
-assert "-m" "-a"         1
-assert "-r" "-d"         1
-cd ..
-
-hg init repo4
-cd repo4
-touch modified removed deleted
-hg ci -q -A -m 'initial checkin' -d "1000000 0"
-touch added unknown
-hg add added
-hg remove removed
-rm deleted
-echo x > modified
-hg copy modified copied
-hg ci -m 'test checkin' -d "1000001 0"
-rm *
-touch unrelated
-hg ci -q -A -m 'unrelated checkin' -d "1000002 0"
-echo "hg status --change 1:"
-hg status --change 1
-echo "hg status --change 1 unrelated:"
-hg status --change 1 unrelated
-echo "hg status -C --change 1 added modified copied removed deleted:"
-hg status -C --change 1 added modified copied removed deleted
-echo "hg status -A --change 1"
-hg status -A --change 1
--- a/tests/test-status-color	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,122 +0,0 @@
-#!/bin/sh
-
-echo "[extensions]" >> $HGRCPATH
-echo "color=" >> $HGRCPATH
-echo "[color]" >> $HGRCPATH
-echo "mode=ansi" >> $HGRCPATH
-
-hg init repo1
-cd repo1
-mkdir a b a/1 b/1 b/2
-touch in_root a/in_a b/in_b a/1/in_a_1 b/1/in_b_1 b/2/in_b_2
-echo "hg status in repo root:"
-hg status --color=always
-echo "hg status . in repo root:"
-hg status --color=always .
-for dir in a b a/1 b/1 b/2; do
-    echo "hg status in $dir:"
-    hg status --color=always --cwd "$dir"
-    echo "hg status . in $dir:"
-    hg status --color=always --cwd "$dir" .
-    echo "hg status .. in $dir:"
-    hg status --color=always --cwd "$dir" ..
-done
-cd ..
-
-hg init repo2
-cd repo2
-touch modified removed deleted ignored
-echo "^ignored$" > .hgignore
-hg ci -A -m 'initial checkin' -d "1000000 0"
-touch modified added unknown ignored
-hg add added
-hg remove removed
-rm deleted
-echo "hg status:"
-hg status --color=always
-echo "hg status modified added removed deleted unknown never-existed ignored:"
-hg status --color=always modified added removed deleted unknown never-existed ignored
-hg copy modified copied
-echo "hg status -C:"
-hg status --color=always -C
-echo "hg status -A:"
-hg status --color=always -A
-echo "^ignoreddir$" > .hgignore
-mkdir ignoreddir
-touch ignoreddir/file
-echo "hg status ignoreddir/file:"
-hg status --color=always ignoreddir/file
-echo "hg status -i ignoreddir/file:"
-hg status --color=always -i ignoreddir/file
-cd ..
-
-# check 'status -q' and some combinations
-hg init repo3
-cd repo3
-touch modified removed deleted ignored
-echo "^ignored$" > .hgignore
-hg commit -A -m 'initial checkin'
-touch added unknown ignored
-hg add added
-echo "test" >> modified
-hg remove removed
-rm deleted
-hg copy modified copied
-
-echo "% test unknown color"
-hg --config color.status.modified=periwinkle status --color=always
-
-# Run status with 2 different flags.
-# Check if result is the same or different.
-# If result is not as expected, raise error
-assert() {
-    hg status --color=always $1 > ../a
-    hg status --color=always $2 > ../b
-    out=`diff ../a ../b`
-    if [ $? -ne 0 ]; then
-        out=1
-    else
-        out=0
-    fi
-    if [ $3 -eq 0 ]; then
-        df="same"
-    else
-        df="different"
-    fi
-    if [ $out -ne $3 ]; then
-        echo "Error on $1 and $2, should be $df."
-    fi
-}
-
-# assert flag1 flag2 [0-same | 1-different]
-assert "-q" "-mard"      0
-assert "-A" "-marduicC"  0
-assert "-qA" "-mardcC"   0
-assert "-qAui" "-A"      0
-assert "-qAu" "-marducC" 0
-assert "-qAi" "-mardicC" 0
-assert "-qu" "-u"        0
-assert "-q" "-u"         1
-assert "-m" "-a"         1
-assert "-r" "-d"         1
-
-cd ..
-
-# test 'resolve -l'
-hg init repo4
-cd repo4
-echo "file a" > a
-echo "file b" > b
-hg add a b
-hg commit -m "initial"
-echo "file a change 1" > a
-echo "file b change 1" > b
-hg commit -m "head 1"
-hg update 0
-echo "file a change 2" > a
-echo "file b change 2" > b
-hg commit -m "head 2"
-hg merge
-hg resolve -m b
-echo "hg resolve with one unresolved, one resolved:"
-hg resolve --color=always -l
--- a/tests/test-status-color.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,147 +0,0 @@
-hg status in repo root:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in repo root:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status in a:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in a:
-? 1/in_a_1
-? in_a
-hg status .. in a:
-? 1/in_a_1
-? in_a
-? ../b/1/in_b_1
-? ../b/2/in_b_2
-? ../b/in_b
-? ../in_root
-hg status in b:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in b:
-? 1/in_b_1
-? 2/in_b_2
-? in_b
-hg status .. in b:
-? ../a/1/in_a_1
-? ../a/in_a
-? 1/in_b_1
-? 2/in_b_2
-? in_b
-? ../in_root
-hg status in a/1:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in a/1:
-? in_a_1
-hg status .. in a/1:
-? in_a_1
-? ../in_a
-hg status in b/1:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in b/1:
-? in_b_1
-hg status .. in b/1:
-? in_b_1
-? ../2/in_b_2
-? ../in_b
-hg status in b/2:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in b/2:
-? in_b_2
-hg status .. in b/2:
-? ../1/in_b_1
-? in_b_2
-? ../in_b
-adding .hgignore
-adding deleted
-adding modified
-adding removed
-hg status:
-A added
-R removed
-! deleted
-? unknown
-hg status modified added removed deleted unknown never-existed ignored:
-never-existed: No such file or directory
-A added
-R removed
-! deleted
-? unknown
-hg status -C:
-A added
-A copied
-  modified
-R removed
-! deleted
-? unknown
-hg status -A:
-A added
-A copied
-  modified
-R removed
-! deleted
-? unknown
-I ignored
-C .hgignore
-C modified
-hg status ignoreddir/file:
-hg status -i ignoreddir/file:
-I ignoreddir/file
-adding .hgignore
-adding deleted
-adding modified
-adding removed
-% test unknown color
-ignoring unknown color/effect 'periwinkle' (configured in color.status.modified)
-M modified
-A added
-A copied
-R removed
-! deleted
-? unknown
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-merging a
-warning: conflicts during merge.
-merging a failed!
-merging b
-warning: conflicts during merge.
-merging b failed!
-0 files updated, 0 files merged, 0 files removed, 2 files unresolved
-use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon
-hg resolve with one unresolved, one resolved:
-U a
-R b
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-status-color.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,277 @@
+  $ echo "[extensions]" >> $HGRCPATH
+  $ echo "color=" >> $HGRCPATH
+  $ echo "[color]" >> $HGRCPATH
+  $ echo "mode=ansi" >> $HGRCPATH
+
+  $ hg init repo1
+  $ cd repo1
+  $ mkdir a b a/1 b/1 b/2
+  $ touch in_root a/in_a b/in_b a/1/in_a_1 b/1/in_b_1 b/2/in_b_2
+
+hg status in repo root:
+
+  $ hg status --color=always
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+
+hg status . in repo root:
+
+  $ hg status --color=always .
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+
+  $ hg status --color=always --cwd a
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --color=always --cwd a .
+  ? 1/in_a_1
+  ? in_a
+  $ hg status --color=always --cwd a ..
+  ? 1/in_a_1
+  ? in_a
+  ? ../b/1/in_b_1
+  ? ../b/2/in_b_2
+  ? ../b/in_b
+  ? ../in_root
+
+  $ hg status --color=always --cwd b
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --color=always --cwd b .
+  ? 1/in_b_1
+  ? 2/in_b_2
+  ? in_b
+  $ hg status --color=always --cwd b ..
+  ? ../a/1/in_a_1
+  ? ../a/in_a
+  ? 1/in_b_1
+  ? 2/in_b_2
+  ? in_b
+  ? ../in_root
+
+  $ hg status --color=always --cwd a/1
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --color=always --cwd a/1 .
+  ? in_a_1
+  $ hg status --color=always --cwd a/1 ..
+  ? in_a_1
+  ? ../in_a
+
+  $ hg status --color=always --cwd b/1
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --color=always --cwd b/1 .
+  ? in_b_1
+  $ hg status --color=always --cwd b/1 ..
+  ? in_b_1
+  ? ../2/in_b_2
+  ? ../in_b
+
+  $ hg status --color=always --cwd b/2
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --color=always --cwd b/2 .
+  ? in_b_2
+  $ hg status --color=always --cwd b/2 ..
+  ? ../1/in_b_1
+  ? in_b_2
+  ? ../in_b
+  $ cd ..
+
+  $ hg init repo2
+  $ cd repo2
+  $ touch modified removed deleted ignored
+  $ echo "^ignored$" > .hgignore
+  $ hg ci -A -m 'initial checkin' -d "1000000 0"
+  adding .hgignore
+  adding deleted
+  adding modified
+  adding removed
+  $ touch modified added unknown ignored
+  $ hg add added
+  $ hg remove removed
+  $ rm deleted
+
+hg status:
+
+  $ hg status --color=always
+  A added
+  R removed
+  ! deleted
+  ? unknown
+
+hg status modified added removed deleted unknown never-existed ignored:
+
+  $ hg status --color=always modified added removed deleted unknown never-existed ignored
+  never-existed: No such file or directory
+  A added
+  R removed
+  ! deleted
+  ? unknown
+
+  $ hg copy modified copied
+
+hg status -C:
+
+  $ hg status --color=always -C
+  A added
+  A copied
+    modified
+  R removed
+  ! deleted
+  ? unknown
+
+hg status -A:
+
+  $ hg status --color=always -A
+  A added
+  A copied
+    modified
+  R removed
+  ! deleted
+  ? unknown
+  I ignored
+  C .hgignore
+  C modified
+
+
+  $ echo "^ignoreddir$" > .hgignore
+  $ mkdir ignoreddir
+  $ touch ignoreddir/file
+
+hg status ignoreddir/file:
+
+  $ hg status --color=always ignoreddir/file
+
+hg status -i ignoreddir/file:
+
+  $ hg status --color=always -i ignoreddir/file
+  I ignoreddir/file
+  $ cd ..
+
+# check 'status -q' and some combinations
+
+  $ hg init repo3
+  $ cd repo3
+  $ touch modified removed deleted ignored
+  $ echo "^ignored$" > .hgignore
+  $ hg commit -A -m 'initial checkin'
+  adding .hgignore
+  adding deleted
+  adding modified
+  adding removed
+  $ touch added unknown ignored
+  $ hg add added
+  $ echo "test" >> modified
+  $ hg remove removed
+  $ rm deleted
+  $ hg copy modified copied
+
+test unknown color
+
+  $ hg --config color.status.modified=periwinkle status --color=always
+  ignoring unknown color/effect 'periwinkle' (configured in color.status.modified)
+  M modified
+  A added
+  A copied
+  R removed
+  ! deleted
+  ? unknown
+
+# Run status with 2 different flags.
+# Check if result is the same or different.
+# If result is not as expected, raise error
+  $ assert() {
+  >     hg status --color=always $1 > ../a
+  >     hg status --color=always $2 > ../b
+  >     out=`diff ../a ../b`
+  >     if [ $? -ne 0 ]; then
+  >         out=1
+  >     else
+  >         out=0
+  >     fi
+  >     if [ $3 -eq 0 ]; then
+  >         df="same"
+  >     else
+  >         df="different"
+  >     fi
+  >     if [ $out -ne $3 ]; then
+  >         echo "Error on $1 and $2, should be $df."
+  >     fi
+  > }
+
+# assert flag1 flag2 [0-same | 1-different]
+
+  $ assert "-q" "-mard"      0
+  $ assert "-A" "-marduicC"  0
+  $ assert "-qA" "-mardcC"   0
+  $ assert "-qAui" "-A"      0
+  $ assert "-qAu" "-marducC" 0
+  $ assert "-qAi" "-mardicC" 0
+  $ assert "-qu" "-u"        0
+  $ assert "-q" "-u"         1
+  $ assert "-m" "-a"         1
+  $ assert "-r" "-d"         1
+  $ cd ..
+
+# test 'resolve -l'
+  $ hg init repo4
+  $ cd repo4
+  $ echo "file a" > a
+  $ echo "file b" > b
+  $ hg add a b
+  $ hg commit -m "initial"
+  $ echo "file a change 1" > a
+  $ echo "file b change 1" > b
+  $ hg commit -m "head 1"
+  $ hg update 0
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo "file a change 2" > a
+  $ echo "file b change 2" > b
+  $ hg commit -m "head 2"
+  created new head
+  $ hg merge
+  merging a
+  warning: conflicts during merge.
+  merging a failed!
+  merging b
+  warning: conflicts during merge.
+  merging b failed!
+  0 files updated, 0 files merged, 0 files removed, 2 files unresolved
+  use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon
+  $ hg resolve -m b
+
+hg resolve with one unresolved, one resolved:
+
+  $ hg resolve --color=always -l
+  U a
+  R b
--- a/tests/test-status.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,145 +0,0 @@
-hg status in repo root:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in repo root:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status in a:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in a:
-? 1/in_a_1
-? in_a
-hg status .. in a:
-? 1/in_a_1
-? in_a
-? ../b/1/in_b_1
-? ../b/2/in_b_2
-? ../b/in_b
-? ../in_root
-hg status in b:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in b:
-? 1/in_b_1
-? 2/in_b_2
-? in_b
-hg status .. in b:
-? ../a/1/in_a_1
-? ../a/in_a
-? 1/in_b_1
-? 2/in_b_2
-? in_b
-? ../in_root
-hg status in a/1:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in a/1:
-? in_a_1
-hg status .. in a/1:
-? in_a_1
-? ../in_a
-hg status in b/1:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in b/1:
-? in_b_1
-hg status .. in b/1:
-? in_b_1
-? ../2/in_b_2
-? ../in_b
-hg status in b/2:
-? a/1/in_a_1
-? a/in_a
-? b/1/in_b_1
-? b/2/in_b_2
-? b/in_b
-? in_root
-hg status . in b/2:
-? in_b_2
-hg status .. in b/2:
-? ../1/in_b_1
-? in_b_2
-? ../in_b
-adding .hgignore
-adding deleted
-adding modified
-adding removed
-hg status:
-A added
-R removed
-! deleted
-? unknown
-hg status modified added removed deleted unknown never-existed ignored:
-never-existed: No such file or directory
-A added
-R removed
-! deleted
-? unknown
-hg status -C:
-A added
-A copied
-  modified
-R removed
-! deleted
-? unknown
-hg status -A:
-A added
-A copied
-  modified
-R removed
-! deleted
-? unknown
-I ignored
-C .hgignore
-C modified
-hg status ignoreddir/file:
-hg status -i ignoreddir/file:
-I ignoreddir/file
-adding .hgignore
-adding deleted
-adding modified
-adding removed
-hg status --change 1:
-M modified
-A added
-A copied
-R removed
-hg status --change 1 unrelated:
-hg status -C --change 1 added modified copied removed deleted:
-M modified
-A added
-A copied
-  modified
-R removed
-hg status -A --change 1
-M modified
-A added
-A copied
-  modified
-R removed
-C deleted
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-status.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,275 @@
+  $ hg init repo1
+  $ cd repo1
+  $ mkdir a b a/1 b/1 b/2
+  $ touch in_root a/in_a b/in_b a/1/in_a_1 b/1/in_b_1 b/2/in_b_2
+
+hg status in repo root:
+
+  $ hg status
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+
+hg status . in repo root:
+
+  $ hg status .
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+
+  $ hg status --cwd a
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --cwd a .
+  ? 1/in_a_1
+  ? in_a
+  $ hg status --cwd a ..
+  ? 1/in_a_1
+  ? in_a
+  ? ../b/1/in_b_1
+  ? ../b/2/in_b_2
+  ? ../b/in_b
+  ? ../in_root
+
+  $ hg status --cwd b
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --cwd b .
+  ? 1/in_b_1
+  ? 2/in_b_2
+  ? in_b
+  $ hg status --cwd b ..
+  ? ../a/1/in_a_1
+  ? ../a/in_a
+  ? 1/in_b_1
+  ? 2/in_b_2
+  ? in_b
+  ? ../in_root
+
+  $ hg status --cwd a/1
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --cwd a/1 .
+  ? in_a_1
+  $ hg status --cwd a/1 ..
+  ? in_a_1
+  ? ../in_a
+
+  $ hg status --cwd b/1
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --cwd b/1 .
+  ? in_b_1
+  $ hg status --cwd b/1 ..
+  ? in_b_1
+  ? ../2/in_b_2
+  ? ../in_b
+
+  $ hg status --cwd b/2
+  ? a/1/in_a_1
+  ? a/in_a
+  ? b/1/in_b_1
+  ? b/2/in_b_2
+  ? b/in_b
+  ? in_root
+  $ hg status --cwd b/2 .
+  ? in_b_2
+  $ hg status --cwd b/2 ..
+  ? ../1/in_b_1
+  ? in_b_2
+  ? ../in_b
+  $ cd ..
+
+  $ hg init repo2
+  $ cd repo2
+  $ touch modified removed deleted ignored
+  $ echo "^ignored$" > .hgignore
+  $ hg ci -A -m 'initial checkin' -d "1000000 0"
+  adding .hgignore
+  adding deleted
+  adding modified
+  adding removed
+  $ touch modified added unknown ignored
+  $ hg add added
+  $ hg remove removed
+  $ rm deleted
+
+hg status:
+
+  $ hg status
+  A added
+  R removed
+  ! deleted
+  ? unknown
+
+hg status modified added removed deleted unknown never-existed ignored:
+
+  $ hg status modified added removed deleted unknown never-existed ignored
+  never-existed: No such file or directory
+  A added
+  R removed
+  ! deleted
+  ? unknown
+
+  $ hg copy modified copied
+
+hg status -C:
+
+  $ hg status -C
+  A added
+  A copied
+    modified
+  R removed
+  ! deleted
+  ? unknown
+
+hg status -A:
+
+  $ hg status -A
+  A added
+  A copied
+    modified
+  R removed
+  ! deleted
+  ? unknown
+  I ignored
+  C .hgignore
+  C modified
+
+
+  $ echo "^ignoreddir$" > .hgignore
+  $ mkdir ignoreddir
+  $ touch ignoreddir/file
+
+hg status ignoreddir/file:
+
+  $ hg status ignoreddir/file
+
+hg status -i ignoreddir/file:
+
+  $ hg status -i ignoreddir/file
+  I ignoreddir/file
+  $ cd ..
+
+# check 'status -q' and some combinations
+
+  $ hg init repo3
+  $ cd repo3
+  $ touch modified removed deleted ignored
+  $ echo "^ignored$" > .hgignore
+  $ hg commit -A -m 'initial checkin'
+  adding .hgignore
+  adding deleted
+  adding modified
+  adding removed
+  $ touch added unknown ignored
+  $ hg add added
+  $ echo "test" >> modified
+  $ hg remove removed
+  $ rm deleted
+  $ hg copy modified copied
+
+# Run status with 2 different flags.
+# Check if result is the same or different.
+# If result is not as expected, raise error
+
+  $ assert() {
+  >    hg status $1 > ../a
+  >    hg status $2 > ../b
+  >     out=`diff ../a ../b`
+  >     if [ $? -ne 0 ]; then
+  >         out=1
+  >     else
+  >         out=0
+  >     fi
+  >     if [ $3 -eq 0 ]; then
+  >         df="same"
+  >     else
+  >         df="different"
+  >     fi
+  >     if [ $out -ne $3 ]; then
+  >         echo "Error on $1 and $2, should be $df."
+  >     fi
+  > }
+
+# assert flag1 flag2 [0-same | 1-different]
+
+  $ assert "-q" "-mard"      0
+  $ assert "-A" "-marduicC"  0
+  $ assert "-qA" "-mardcC"   0
+  $ assert "-qAui" "-A"      0
+  $ assert "-qAu" "-marducC" 0
+  $ assert "-qAi" "-mardicC" 0
+  $ assert "-qu" "-u"        0
+  $ assert "-q" "-u"         1
+  $ assert "-m" "-a"         1
+  $ assert "-r" "-d"         1
+  $ cd ..
+
+  $ hg init repo4
+  $ cd repo4
+  $ touch modified removed deleted
+  $ hg ci -q -A -m 'initial checkin' -d "1000000 0"
+  $ touch added unknown
+  $ hg add added
+  $ hg remove removed
+  $ rm deleted
+  $ echo x > modified
+  $ hg copy modified copied
+  $ hg ci -m 'test checkin' -d "1000001 0"
+  $ rm *
+  $ touch unrelated
+  $ hg ci -q -A -m 'unrelated checkin' -d "1000002 0"
+
+hg status --change 1:
+
+  $ hg status --change 1
+  M modified
+  A added
+  A copied
+  R removed
+
+hg status --change 1 unrelated:
+
+  $ hg status --change 1 unrelated
+
+hg status -C --change 1 added modified copied removed deleted:
+
+  $ hg status -C --change 1 added modified copied removed deleted
+  M modified
+  A added
+  A copied
+    modified
+  R removed
+
+hg status -A --change 1:
+
+  $ hg status -A --change 1
+  M modified
+  A added
+  A copied
+    modified
+  R removed
+  C deleted
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-subrepo-paths	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,27 @@
+#!/bin/sh
+
+hg init outer
+cd outer
+
+echo 'sub = http://example.net/libfoo' > .hgsub
+hg add .hgsub
+
+echo '% hg debugsub with no remapping'
+hg debugsub
+
+cat > .hg/hgrc <<EOF
+[subpaths]
+http://example.net = ssh://localhost
+EOF
+
+echo '% hg debugsub with remapping'
+hg debugsub
+
+echo '% test bad subpaths pattern'
+cat > .hg/hgrc <<EOF
+[subpaths]
+.* = \1
+EOF
+hg debugsub 2>&1 | "$TESTDIR/filtertmp.py"
+
+exit 0
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-subrepo-paths.out	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,10 @@
+% hg debugsub with no remapping
+path sub
+ source   http://example.net/libfoo
+ revision 
+% hg debugsub with remapping
+path sub
+ source   ssh://localhost/libfoo
+ revision 
+% test bad subpaths pattern
+abort: bad subrepository pattern in $HGTMP/test-subrepo-paths/outer/.hg/hgrc:2: invalid group reference
--- a/tests/test-subrepo.out	Sat Aug 14 01:31:57 2010 +0200
+++ b/tests/test-subrepo.out	Sat Aug 14 03:30:35 2010 +0200
@@ -183,13 +183,13 @@
 % push -f
 committing subrepository s
 abort: push creates new remote heads on branch 'default'!
+(did you forget to merge? use push -f to force)
 pushing ...sub/t
 pushing ...sub/t/s/ss
 searching for changes
 no changes found
 pushing ...sub/t/s
 searching for changes
-(did you forget to merge? use push -f to force)
 pushing ...sub/t
 pushing ...sub/t/s/ss
 searching for changes
@@ -300,4 +300,5 @@
 created new head
 committing subrepository s
 abort: push creates new remote heads on branch 'default'!
+(did you forget to merge? use push -f to force)
 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
--- a/tests/test-symlink-addremove	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-#!/bin/sh
-
-"$TESTDIR/hghave" symlink || exit 80
-
-hg init a
-cd a
-
-echo '% directory moved and symlinked'
-mkdir foo
-touch foo/a
-hg ci -Ama
-mv foo bar
-ln -s bar foo
-echo '% now addremove should remove old files'
-hg addremove
--- a/tests/test-symlink-addremove.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,6 +0,0 @@
-% directory moved and symlinked
-adding foo/a
-% now addremove should remove old files
-adding bar/a
-adding foo
-removing foo/a
--- a/tests/test-symlink-basic	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,50 +0,0 @@
-#!/bin/sh
-
-"$TESTDIR/hghave" symlink || exit 80
-
-hg init a
-cd a
-ln -s nothing dangling
-hg commit -m 'commit symlink without adding' dangling
-hg add dangling
-hg commit -m 'add symlink'
-
-hg tip -v
-hg manifest --debug
-echo '% rev 0:'
-$TESTDIR/readlink.py dangling
-
-rm dangling
-ln -s void dangling
-hg commit -m 'change symlink'
-echo '% rev 1:'
-$TESTDIR/readlink.py dangling
-
-echo '% modifying link'
-rm dangling
-ln -s empty dangling
-$TESTDIR/readlink.py dangling
-
-echo '% reverting to rev 0:'
-hg revert -r 0 -a
-$TESTDIR/readlink.py dangling
-
-echo '% backups:'
-$TESTDIR/readlink.py *.orig
-
-rm *.orig
-hg up -C
-echo '% copies'
-hg cp -v dangling dangling2
-hg st -Cmard
-$TESTDIR/readlink.py dangling dangling2
-
-echo '% issue995'
-hg up -C
-mkdir dir
-ln -s dir dirlink
-hg ci -qAm 'add dirlink'
-mkdir newdir
-mv dir newdir/dir
-mv dirlink newdir/dirlink
-hg mv -A dirlink newdir/dirlink
--- a/tests/test-symlink-basic.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,31 +0,0 @@
-abort: dangling: file not tracked!
-changeset:   0:cabd88b706fc
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-files:       dangling
-description:
-add symlink
-
-
-2564acbe54bbbedfbf608479340b359f04597f80 644 @ dangling
-% rev 0:
-dangling -> nothing
-% rev 1:
-dangling -> void
-% modifying link
-dangling -> empty
-% reverting to rev 0:
-reverting dangling
-dangling -> nothing
-% backups:
-dangling.orig -> empty
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-% copies
-copying dangling to dangling2
-A dangling2
-  dangling
-dangling -> void
-dangling2 -> void
-% issue995
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
--- a/tests/test-symlink-root	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,10 +0,0 @@
-#!/bin/sh
-
-"$TESTDIR/hghave" symlink || exit 80
-
-hg init a
-ln -s a link
-cd a
-echo foo > foo
-hg status
-hg status ../link
--- a/tests/test-symlink-root.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,2 +0,0 @@
-? foo
-? foo
--- a/tests/test-symlinks	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,84 +0,0 @@
-#!/bin/sh
-#Test bug regarding symlinks that showed up in hg 0.7
-#Author: Matthew Elder <sseses@gmail.com>
-
-"$TESTDIR/hghave" symlink || exit 80
-
-#make and initialize repo
-hg init test; cd test;
-
-#make a file and a symlink
-touch foo; ln -s foo bar;
-
-#import with addremove -- symlink walking should _not_ screwup.
-hg addremove
-
-#commit -- the symlink should _not_ appear added to dir state
-hg commit -m 'initial'
-
-#add a new file so hg will let me commit again
-touch bomb
-
-#again, symlink should _not_ show up on dir state
-hg addremove
-
-#Assert screamed here before, should go by without consequence
-hg commit -m 'is there a bug?'
-
-cd .. ; rm -r test
-hg init test; cd test;
-
-mkdir dir
-touch a.c dir/a.o dir/b.o
-# test what happens if we want to trick hg
-hg commit -A -m 0
-echo "relglob:*.o" > .hgignore
-rm a.c
-rm dir/a.o
-rm dir/b.o
-mkdir dir/a.o
-ln -s nonexist dir/b.o
-mkfifo a.c
-# it should show a.c, dir/a.o and dir/b.o deleted
-hg status
-hg status a.c
-
-echo '# test absolute path through symlink outside repo'
-cd ..
-p=`pwd`
-hg init x
-ln -s x y
-cd x
-touch f
-hg add f
-hg status "$p"/y/f
-
-echo '# try symlink outside repo to file inside'
-ln -s x/f ../z
-# this should fail
-hg status ../z && { echo hg mistakenly exited with status 0; exit 1; } || :
-
-cd .. ; rm -r test
-hg init test; cd test;
-
-echo '# try cloning symlink in a subdir'
-echo '1. commit a symlink'
-mkdir -p a/b/c
-cd a/b/c
-ln -s /path/to/symlink/source demo
-cd ../../..
-hg stat
-hg commit -A -m 'add symlink in a/b/c subdir'
-echo '2. clone it'
-cd ..
-hg clone test testclone
-
-echo '# git symlink diff'
-cd testclone
-hg diff --git -r null:tip
-hg export --git tip > ../sl.diff
-echo '# import git symlink diff'
-hg rm a/b/c/demo
-hg commit -m'remove link'
-hg import ../sl.diff
-hg diff --git -r 1:tip
--- a/tests/test-symlinks.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,40 +0,0 @@
-adding bar
-adding foo
-adding bomb
-adding a.c
-adding dir/a.o
-adding dir/b.o
-M dir/b.o
-! a.c
-! dir/a.o
-? .hgignore
-a.c: unsupported file type (type is fifo)
-! a.c
-# test absolute path through symlink outside repo
-A f
-# try symlink outside repo to file inside
-abort: ../z not under root
-# try cloning symlink in a subdir
-1. commit a symlink
-? a/b/c/demo
-adding a/b/c/demo
-2. clone it
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-# git symlink diff
-diff --git a/a/b/c/demo b/a/b/c/demo
-new file mode 120000
---- /dev/null
-+++ b/a/b/c/demo
-@@ -0,0 +1,1 @@
-+/path/to/symlink/source
-\ No newline at end of file
-# import git symlink diff
-applying ../sl.diff
-diff --git a/a/b/c/demo b/a/b/c/demo
-new file mode 120000
---- /dev/null
-+++ b/a/b/c/demo
-@@ -0,0 +1,1 @@
-+/path/to/symlink/source
-\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-symlinks.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,253 @@
+  $ "$TESTDIR/hghave" symlink || exit 80
+
+== tests added in 0.7 ==
+
+  $ hg init test-symlinks-0.7; cd test-symlinks-0.7;
+  $ touch foo; ln -s foo bar;
+
+import with addremove -- symlink walking should _not_ screwup.
+
+  $ hg addremove
+  adding bar
+  adding foo
+
+commit -- the symlink should _not_ appear added to dir state
+
+  $ hg commit -m 'initial'
+
+  $ touch bomb
+
+again, symlink should _not_ show up on dir state
+
+  $ hg addremove
+  adding bomb
+
+Assert screamed here before, should go by without consequence
+
+  $ hg commit -m 'is there a bug?'
+  $ cd ..
+
+
+== fifo & ignore ==
+
+  $ hg init test; cd test;
+
+  $ mkdir dir
+  $ touch a.c dir/a.o dir/b.o
+
+test what happens if we want to trick hg
+
+  $ hg commit -A -m 0
+  adding a.c
+  adding dir/a.o
+  adding dir/b.o
+  $ echo "relglob:*.o" > .hgignore
+  $ rm a.c
+  $ rm dir/a.o
+  $ rm dir/b.o
+  $ mkdir dir/a.o
+  $ ln -s nonexist dir/b.o
+  $ mkfifo a.c
+
+it should show a.c, dir/a.o and dir/b.o deleted
+
+  $ hg status
+  M dir/b.o
+  ! a.c
+  ! dir/a.o
+  ? .hgignore
+  $ hg status a.c
+  a.c: unsupported file type (type is fifo)
+  ! a.c
+  $ cd ..
+
+
+== symlinks from outside the tree ==
+
+test absolute path through symlink outside repo
+
+  $ p=`pwd`
+  $ hg init x
+  $ ln -s x y
+  $ cd x
+  $ touch f
+  $ hg add f
+  $ hg status "$p"/y/f
+  A f
+
+try symlink outside repo to file inside
+
+  $ ln -s x/f ../z
+
+this should fail
+
+  $ hg status ../z && { echo hg mistakenly exited with status 0; exit 1; } || :
+  abort: ../z not under root
+  $ cd ..
+
+
+== cloning symlinks ==
+  $ hg init clone; cd clone;
+
+try cloning symlink in a subdir
+1. commit a symlink
+
+  $ mkdir -p a/b/c
+  $ cd a/b/c
+  $ ln -s /path/to/symlink/source demo
+  $ cd ../../..
+  $ hg stat
+  ? a/b/c/demo
+  $ hg commit -A -m 'add symlink in a/b/c subdir'
+  adding a/b/c/demo
+
+2. clone it
+
+  $ cd ..
+  $ hg clone clone clonedest
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+
+== symlink and git diffs ==
+
+git symlink diff
+
+  $ cd clonedest
+  $ hg diff --git -r null:tip
+  diff --git a/a/b/c/demo b/a/b/c/demo
+  new file mode 120000
+  --- /dev/null
+  +++ b/a/b/c/demo
+  @@ -0,0 +1,1 @@
+  +/path/to/symlink/source
+  \ No newline at end of file
+  $ hg export --git tip > ../sl.diff
+
+import git symlink diff
+
+  $ hg rm a/b/c/demo
+  $ hg commit -m'remove link'
+  $ hg import ../sl.diff
+  applying ../sl.diff
+  $ hg diff --git -r 1:tip
+  diff --git a/a/b/c/demo b/a/b/c/demo
+  new file mode 120000
+  --- /dev/null
+  +++ b/a/b/c/demo
+  @@ -0,0 +1,1 @@
+  +/path/to/symlink/source
+  \ No newline at end of file
+
+== symlinks and addremove ==
+
+directory moved and symlinked
+
+  $ mkdir foo
+  $ touch foo/a
+  $ hg ci -Ama
+  adding foo/a
+  $ mv foo bar
+  $ ln -s bar foo
+
+now addremove should remove old files
+
+  $ hg addremove
+  adding bar/a
+  adding foo
+  removing foo/a
+  $ cd ..
+
+== root of repository is symlinked ==
+
+  $ hg init root
+  $ ln -s root link
+  $ cd root
+  $ echo foo > foo
+  $ hg status
+  ? foo
+  $ hg status ../link
+  ? foo
+  $ cd ..
+
+
+
+
+  $ hg init b
+  $ cd b
+  $ ln -s nothing dangling
+  $ hg commit -m 'commit symlink without adding' dangling
+  abort: dangling: file not tracked!
+  $ hg add dangling
+  $ hg commit -m 'add symlink'
+
+  $ hg tip -v
+  changeset:   0:cabd88b706fc
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  files:       dangling
+  description:
+  add symlink
+  
+  
+  $ hg manifest --debug
+  2564acbe54bbbedfbf608479340b359f04597f80 644 @ dangling
+  $ $TESTDIR/readlink.py dangling
+  dangling -> nothing
+
+  $ rm dangling
+  $ ln -s void dangling
+  $ hg commit -m 'change symlink'
+  $ $TESTDIR/readlink.py dangling
+  dangling -> void
+
+
+modifying link
+
+  $ rm dangling
+  $ ln -s empty dangling
+  $ $TESTDIR/readlink.py dangling
+  dangling -> empty
+
+
+reverting to rev 0:
+
+  $ hg revert -r 0 -a
+  reverting dangling
+  $ $TESTDIR/readlink.py dangling
+  dangling -> nothing
+
+
+backups:
+
+  $ $TESTDIR/readlink.py *.orig
+  dangling.orig -> empty
+  $ rm *.orig
+  $ hg up -C
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+copies
+
+  $ hg cp -v dangling dangling2
+  copying dangling to dangling2
+  $ hg st -Cmard
+  A dangling2
+    dangling
+  $ $TESTDIR/readlink.py dangling dangling2
+  dangling -> void
+  dangling2 -> void
+
+
+issue995
+
+  $ hg up -C
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ mkdir dir
+  $ ln -s dir dirlink
+  $ hg ci -qAm 'add dirlink'
+  $ mkdir newdir
+  $ mv dir newdir/dir
+  $ mv dirlink newdir/dirlink
+  $ hg mv -A dirlink newdir/dirlink
+
--- a/tests/test-tag	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,88 +0,0 @@
-#!/bin/sh
-
-hg init test
-cd test
-
-echo a > a
-hg add a
-hg commit -m "test" -d "1000000 0"
-hg history
-
-hg tag ' '
-
-hg tag -d "1000000 0" "bleah"
-hg history
-
-echo foo >> .hgtags
-hg tag -d "1000000 0" "bleah2" || echo "failed"
-
-hg revert .hgtags
-hg tag -d "1000000 0" -r 0 x y z y y z || echo "failed"
-hg tag -d "1000000 0" tap nada dot tip null . || echo "failed"
-hg tag -d "1000000 0" "bleah" || echo "failed"
-hg tag -d "1000000 0" "blecch" "bleah" || echo "failed"
-
-hg tag -d "1000000 0" --remove "blecch" || echo "failed"
-hg tag -d "1000000 0" --remove "bleah" "blecch" "blough" || echo "failed"
-
-hg tag -d "1000000 0" -r 0 "bleah0"
-hg tag -l -d "1000000 0" -r 1 "bleah1"
-hg tag -d "1000000 0" gack gawk gorp
-hg tag -d "1000000 0" -f gack
-hg tag -d "1000000 0" --remove gack gorp
-
-cat .hgtags
-cat .hg/localtags
-
-hg update 0
-hg tag -d "1000000 0" "foobar"
-cat .hgtags
-cat .hg/localtags
-
-hg tag -l 'xx
-newline'
-hg tag -l 'xx:xx'
-
-echo % cloning local tags
-cd ..
-hg -R test log -r0:5
-hg clone -q -rbleah1 test test1
-hg -R test1 parents --style=compact
-hg clone -q -r5 test#bleah1 test2
-hg -R test2 parents --style=compact
-hg clone -q -U test#bleah1 test3
-hg -R test3 parents --style=compact
-
-cd test
-echo % issue 601
-python << EOF
-f = file('.hg/localtags'); last = f.readlines()[-1][:-1]; f.close()
-f = file('.hg/localtags', 'w'); f.write(last); f.close()
-EOF
-cat .hg/localtags
-hg tag -l localnewline
-cat .hg/localtags
-
-python << EOF
-f = file('.hgtags'); last = f.readlines()[-1][:-1]; f.close()
-f = file('.hgtags', 'w'); f.write(last); f.close()
-EOF
-hg ci -d '1000000 0' -m'broken manual edit of .hgtags'
-cat .hgtags
-hg tag -d '1000000 0' newline
-cat .hgtags
-
-echo % tag and branch using same name
-hg branch tag-and-branch-same-name
-hg ci -m"discouraged"
-hg tag tag-and-branch-same-name
-
-echo '% test custom commit messages'
-cat > $HGTMP/editor <<'__EOF__'
-#!/bin/sh
-echo "custom tag message" > "$1"
-echo "second line" >> "$1"
-__EOF__
-chmod +x "$HGTMP"/editor
-HGEDITOR="'$HGTMP'"/editor hg tag custom-tag -e
-hg log -l1 --template "{desc}\n"
--- a/tests/test-tag.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,103 +0,0 @@
-changeset:   0:0acdaf898367
-tag:         tip
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     test
-
-abort: tag names cannot consist entirely of whitespace
-changeset:   1:3ecf002a1c57
-tag:         tip
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     Added tag bleah for changeset 0acdaf898367
-
-changeset:   0:0acdaf898367
-tag:         bleah
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     test
-
-abort: working copy of .hgtags is changed (please commit .hgtags manually)
-failed
-abort: tag names must be unique
-failed
-abort: the name 'tip' is reserved
-failed
-abort: tag 'bleah' already exists (use -f to force)
-failed
-abort: tag 'bleah' already exists (use -f to force)
-failed
-abort: tag 'blecch' does not exist
-failed
-abort: tag 'blecch' does not exist
-failed
-0acdaf8983679e0aac16e811534eb49d7ee1f2b4 bleah
-0acdaf8983679e0aac16e811534eb49d7ee1f2b4 bleah0
-868cc8fbb43b754ad09fa109885d243fc49adae7 gack
-868cc8fbb43b754ad09fa109885d243fc49adae7 gawk
-868cc8fbb43b754ad09fa109885d243fc49adae7 gorp
-868cc8fbb43b754ad09fa109885d243fc49adae7 gack
-3807bcf62c5614cb6c16436b514d7764ca5f1631 gack
-3807bcf62c5614cb6c16436b514d7764ca5f1631 gack
-0000000000000000000000000000000000000000 gack
-868cc8fbb43b754ad09fa109885d243fc49adae7 gorp
-0000000000000000000000000000000000000000 gorp
-3ecf002a1c572a2f3bb4e665417e60fca65bbd42 bleah1
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-0acdaf8983679e0aac16e811534eb49d7ee1f2b4 foobar
-3ecf002a1c572a2f3bb4e665417e60fca65bbd42 bleah1
-abort: '\n' cannot be used in a tag name
-abort: ':' cannot be used in a tag name
-% cloning local tags
-changeset:   0:0acdaf898367
-tag:         bleah
-tag:         bleah0
-tag:         foobar
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     test
-
-changeset:   1:3ecf002a1c57
-tag:         bleah1
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     Added tag bleah for changeset 0acdaf898367
-
-changeset:   2:868cc8fbb43b
-tag:         gawk
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     Added tag bleah0 for changeset 0acdaf898367
-
-changeset:   3:3807bcf62c56
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     Added tag gack, gawk, gorp for changeset 868cc8fbb43b
-
-changeset:   4:140c6e8597b4
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     Added tag gack for changeset 3807bcf62c56
-
-changeset:   5:470a65fa7cc9
-user:        test
-date:        Mon Jan 12 13:46:40 1970 +0000
-summary:     Removed tag gack, gorp
-
-1[tip]   3ecf002a1c57   1970-01-12 13:46 +0000   test
-  Added tag bleah for changeset 0acdaf898367
-
-5[tip]   470a65fa7cc9   1970-01-12 13:46 +0000   test
-  Removed tag gack, gorp
-
-% issue 601
-3ecf002a1c572a2f3bb4e665417e60fca65bbd42 bleah13ecf002a1c572a2f3bb4e665417e60fca65bbd42 bleah1
-f68b039e72eacbb2e68b0543e1f6e50990aa2bb5 localnewline
-0acdaf8983679e0aac16e811534eb49d7ee1f2b4 foobar0acdaf8983679e0aac16e811534eb49d7ee1f2b4 foobar
-6ae703d793c8b1f097116869275ecd97b2977a2b newline
-% tag and branch using same name
-marked working directory as branch tag-and-branch-same-name
-warning: tag tag-and-branch-same-name conflicts with existing branch name
-% test custom commit messages
-custom tag message
-second line
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-tag.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,194 @@
+  $ hg init test
+  $ cd test
+
+  $ echo a > a
+  $ hg add a
+  $ hg commit -m "test" -d "1000000 0"
+  $ hg history
+  changeset:   0:0acdaf898367
+  tag:         tip
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     test
+  
+
+  $ hg tag ' '
+  abort: tag names cannot consist entirely of whitespace
+
+  $ hg tag -d "1000000 0" "bleah"
+  $ hg history
+  changeset:   1:3ecf002a1c57
+  tag:         tip
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     Added tag bleah for changeset 0acdaf898367
+  
+  changeset:   0:0acdaf898367
+  tag:         bleah
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     test
+  
+
+  $ echo foo >> .hgtags
+  $ hg tag -d "1000000 0" "bleah2" || echo "failed"
+  abort: working copy of .hgtags is changed (please commit .hgtags manually)
+  failed
+
+  $ hg revert .hgtags
+  $ hg tag -d "1000000 0" -r 0 x y z y y z || echo "failed"
+  abort: tag names must be unique
+  failed
+  $ hg tag -d "1000000 0" tap nada dot tip null . || echo "failed"
+  abort: the name 'tip' is reserved
+  failed
+  $ hg tag -d "1000000 0" "bleah" || echo "failed"
+  abort: tag 'bleah' already exists (use -f to force)
+  failed
+  $ hg tag -d "1000000 0" "blecch" "bleah" || echo "failed"
+  abort: tag 'bleah' already exists (use -f to force)
+  failed
+
+  $ hg tag -d "1000000 0" --remove "blecch" || echo "failed"
+  abort: tag 'blecch' does not exist
+  failed
+  $ hg tag -d "1000000 0" --remove "bleah" "blecch" "blough" || echo "failed"
+  abort: tag 'blecch' does not exist
+  failed
+
+  $ hg tag -d "1000000 0" -r 0 "bleah0"
+  $ hg tag -l -d "1000000 0" -r 1 "bleah1"
+  $ hg tag -d "1000000 0" gack gawk gorp
+  $ hg tag -d "1000000 0" -f gack
+  $ hg tag -d "1000000 0" --remove gack gorp
+
+  $ cat .hgtags
+  0acdaf8983679e0aac16e811534eb49d7ee1f2b4 bleah
+  0acdaf8983679e0aac16e811534eb49d7ee1f2b4 bleah0
+  868cc8fbb43b754ad09fa109885d243fc49adae7 gack
+  868cc8fbb43b754ad09fa109885d243fc49adae7 gawk
+  868cc8fbb43b754ad09fa109885d243fc49adae7 gorp
+  868cc8fbb43b754ad09fa109885d243fc49adae7 gack
+  3807bcf62c5614cb6c16436b514d7764ca5f1631 gack
+  3807bcf62c5614cb6c16436b514d7764ca5f1631 gack
+  0000000000000000000000000000000000000000 gack
+  868cc8fbb43b754ad09fa109885d243fc49adae7 gorp
+  0000000000000000000000000000000000000000 gorp
+  $ cat .hg/localtags
+  3ecf002a1c572a2f3bb4e665417e60fca65bbd42 bleah1
+
+  $ hg update 0
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg tag -d "1000000 0" "foobar"
+  $ cat .hgtags
+  0acdaf8983679e0aac16e811534eb49d7ee1f2b4 foobar
+  $ cat .hg/localtags
+  3ecf002a1c572a2f3bb4e665417e60fca65bbd42 bleah1
+
+  $ hg tag -l 'xx
+  > newline'
+  abort: '\n' cannot be used in a tag name
+  $ hg tag -l 'xx:xx'
+  abort: ':' cannot be used in a tag name
+
+cloning local tags
+
+  $ cd ..
+  $ hg -R test log -r0:5
+  changeset:   0:0acdaf898367
+  tag:         bleah
+  tag:         bleah0
+  tag:         foobar
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     test
+  
+  changeset:   1:3ecf002a1c57
+  tag:         bleah1
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     Added tag bleah for changeset 0acdaf898367
+  
+  changeset:   2:868cc8fbb43b
+  tag:         gawk
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     Added tag bleah0 for changeset 0acdaf898367
+  
+  changeset:   3:3807bcf62c56
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     Added tag gack, gawk, gorp for changeset 868cc8fbb43b
+  
+  changeset:   4:140c6e8597b4
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     Added tag gack for changeset 3807bcf62c56
+  
+  changeset:   5:470a65fa7cc9
+  user:        test
+  date:        Mon Jan 12 13:46:40 1970 +0000
+  summary:     Removed tag gack, gorp
+  
+  $ hg clone -q -rbleah1 test test1
+  $ hg -R test1 parents --style=compact
+  1[tip]   3ecf002a1c57   1970-01-12 13:46 +0000   test
+    Added tag bleah for changeset 0acdaf898367
+  
+  $ hg clone -q -r5 test#bleah1 test2
+  $ hg -R test2 parents --style=compact
+  5[tip]   470a65fa7cc9   1970-01-12 13:46 +0000   test
+    Removed tag gack, gorp
+  
+  $ hg clone -q -U test#bleah1 test3
+  $ hg -R test3 parents --style=compact
+
+  $ cd test
+
+issue 601
+
+  $ python << EOF
+  > f = file('.hg/localtags'); last = f.readlines()[-1][:-1]; f.close()
+  > f = file('.hg/localtags', 'w'); f.write(last); f.close()
+  > EOF
+  $ cat .hg/localtags; echo
+  3ecf002a1c572a2f3bb4e665417e60fca65bbd42 bleah1
+  $ hg tag -l localnewline
+  $ cat .hg/localtags; echo
+  3ecf002a1c572a2f3bb4e665417e60fca65bbd42 bleah1
+  f68b039e72eacbb2e68b0543e1f6e50990aa2bb5 localnewline
+  
+
+  $ python << EOF
+  > f = file('.hgtags'); last = f.readlines()[-1][:-1]; f.close()
+  > f = file('.hgtags', 'w'); f.write(last); f.close()
+  > EOF
+  $ hg ci -d '1000000 0' -m'broken manual edit of .hgtags'
+  $ cat .hgtags; echo
+  0acdaf8983679e0aac16e811534eb49d7ee1f2b4 foobar
+  $ hg tag -d '1000000 0' newline
+  $ cat .hgtags; echo
+  0acdaf8983679e0aac16e811534eb49d7ee1f2b4 foobar
+  6ae703d793c8b1f097116869275ecd97b2977a2b newline
+  
+
+tag and branch using same name
+
+  $ hg branch tag-and-branch-same-name
+  marked working directory as branch tag-and-branch-same-name
+  $ hg ci -m"discouraged"
+  $ hg tag tag-and-branch-same-name
+  warning: tag tag-and-branch-same-name conflicts with existing branch name
+
+test custom commit messages
+
+  $ cat > $HGTMP/editor <<'__EOF__'
+  > #!/bin/sh
+  > echo "custom tag message" > "$1"
+  > echo "second line" >> "$1"
+  > __EOF__
+  $ chmod +x "$HGTMP"/editor
+  $ HGEDITOR="'$HGTMP'"/editor hg tag custom-tag -e
+  $ hg log -l1 --template "{desc}\n"
+  custom tag message
+  second line
--- a/tests/test-tags	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,214 +0,0 @@
-#!/bin/sh
-
-cacheexists() {
-    [ -f .hg/tags.cache ] && echo "tag cache exists" || echo "no tag cache"
-}
-
-# XXX need to test that the tag cache works when we strip an old head
-# and add a new one rooted off non-tip: i.e. node and rev of tip are the
-# same, but stuff has changed behind tip.
-
-echo "% setup"
-mkdir t
-cd t
-hg init
-cacheexists
-hg id
-cacheexists
-echo a > a
-hg add a
-hg commit -m "test"
-hg co
-hg identify
-cacheexists
-
-echo "% create local tag with long name"
-T=`hg identify --debug --id`
-hg tag -l "This is a local tag with a really long name!"
-hg tags
-rm .hg/localtags
-
-echo "% create a tag behind hg's back"
-echo "$T first" > .hgtags
-cat .hgtags
-hg add .hgtags
-hg commit -m "add tags"
-hg tags
-hg identify
-
-# repeat with cold tag cache
-echo "% identify with cold cache"
-rm -f .hg/tags.cache
-hg identify
-
-# and again, but now unable to write tag cache
-echo "% identify with unwritable cache"
-rm -f .hg/tags.cache
-chmod 555 .hg
-hg identify
-chmod 755 .hg
-
-echo "% create a branch"
-echo bb > a
-hg status
-hg identify
-hg co first
-hg id
-hg -v id
-hg status
-echo 1 > b
-hg add b
-hg commit -m "branch"
-hg id
-
-echo "% merge the two heads"
-hg merge 1
-hg id
-hg status
-
-hg commit -m "merge"
-
-echo "% create fake head, make sure tag not visible afterwards"
-cp .hgtags tags
-hg tag last
-hg rm .hgtags
-hg commit -m "remove"
-
-mv tags .hgtags
-hg add .hgtags
-hg commit -m "readd"
-
-hg tags
-
-echo "% add invalid tags"
-echo "spam" >> .hgtags
-echo >> .hgtags
-echo "foo bar" >> .hgtags
-echo "$T invalid" | sed "s/..../a5a5/" >> .hg/localtags
-echo "committing .hgtags:"
-cat .hgtags 
-hg commit -m "tags"
-
-echo "% report tag parse error on other head"
-hg up 3
-echo 'x y' >> .hgtags
-hg commit -m "head"
-
-hg tags
-hg tip
-
-echo "% test tag precedence rules"
-cd ..
-hg init t2
-cd t2
-echo foo > foo
-hg add foo
-hg ci -m 'add foo'      # rev 0
-hg tag bar              # rev 1
-echo >> foo
-hg ci -m 'change foo 1' # rev 2
-hg up -C 1
-hg tag -r 1 -f bar      # rev 3
-hg up -C 1
-echo >> foo
-hg ci -m 'change foo 2' # rev 4
-hg tags
-hg tags         # repeat in case of cache effects
-
-dumptags() {
-    rev=$1
-    echo "rev $rev: .hgtags:"
-    hg cat -r$rev .hgtags
-}
-
-echo "% detailed dump of tag info"
-echo "heads:"
-hg heads -q             # expect 4, 3, 2
-dumptags 2
-dumptags 3
-dumptags 4
-echo ".hg/tags.cache:"
-[ -f .hg/tags.cache ] && cat .hg/tags.cache || echo "no such file"
-
-echo "% test tag removal"
-hg tag --remove bar     # rev 5
-hg tip -vp
-hg tags
-hg tags                 # again, try to expose cache bugs
-
-echo '% remove nonexistent tag'
-hg tag --remove foobar
-hg tip
-
-echo "% rollback undoes tag operation"
-hg rollback             # destroy rev 5 (restore bar)
-hg tags
-hg tags
-
-echo "% test tag rank"
-cd ..
-hg init t3
-cd t3
-echo foo > foo
-hg add foo
-hg ci -m 'add foo'       # rev 0
-hg tag -f bar            # rev 1 bar -> 0
-hg tag -f bar            # rev 2 bar -> 1
-hg tag -fr 0 bar         # rev 3 bar -> 0
-hg tag -fr 1 bar         # rev 4 bar -> 1
-hg tag -fr 0 bar         # rev 5 bar -> 0
-hg tags
-hg co 3
-echo barbar > foo
-hg ci -m 'change foo'    # rev 6
-hg tags
-
-echo "% don't allow moving tag without -f"
-hg tag -r 3 bar
-hg tags
-
-echo "% strip 1: expose an old head"
-hg --config extensions.mq= strip 5 > /dev/null 2>&1
-hg tags                  # partly stale cache
-hg tags                  # up-to-date cache
-echo "% strip 2: destroy whole branch, no old head exposed"
-hg --config extensions.mq= strip 4 > /dev/null 2>&1 
-hg tags                  # partly stale
-rm -f .hg/tags.cache
-hg tags                  # cold cache
-
-echo "% test tag rank with 3 heads"
-cd ..
-hg init t4
-cd t4
-echo foo > foo
-hg add
-hg ci -m 'add foo'                 # rev 0
-hg tag bar                         # rev 1 bar -> 0
-hg tag -f bar                      # rev 2 bar -> 1
-hg up -qC 0
-hg tag -fr 2 bar                   # rev 3 bar -> 2
-hg tags
-hg up -qC 0
-hg tag -m 'retag rev 0' -fr 0 bar  # rev 4 bar -> 0, but bar stays at 2
-echo "% bar should still point to rev 2"
-hg tags
-
-
-echo "% remove local as global and global as local"
-# test that removing global/local tags does not get confused when trying
-# to remove a tag of type X which actually only exists as a type Y
-cd ..
-hg init t5
-cd t5
-echo foo > foo
-hg add
-hg ci -m 'add foo'                 # rev 0
-
-hg tag -r 0 -l localtag
-hg tag --remove localtag
-
-hg tag -r 0 globaltag
-hg tag --remove -l globaltag
-hg tags -v
-exit 0
--- a/tests/test-tags.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,153 +0,0 @@
-% setup
-no tag cache
-000000000000 tip
-no tag cache
-0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-acb14030fe0a tip
-tag cache exists
-% create local tag with long name
-tip                                0:acb14030fe0a
-This is a local tag with a really long name!     0:acb14030fe0a
-% create a tag behind hg's back
-acb14030fe0a21b60322c440ad2d20cf7685a376 first
-tip                                1:b9154636be93
-first                              0:acb14030fe0a
-b9154636be93 tip
-% identify with cold cache
-b9154636be93 tip
-% identify with unwritable cache
-b9154636be93 tip
-% create a branch
-M a
-b9154636be93+ tip
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-acb14030fe0a+ first
-acb14030fe0a+ first
-M a
-created new head
-c8edf04160c7 tip
-% merge the two heads
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-(branch merge, don't forget to commit)
-c8edf04160c7+b9154636be93+ tip
-M .hgtags
-% create fake head, make sure tag not visible afterwards
-tip                                6:35ff301afafe
-first                              0:acb14030fe0a
-% add invalid tags
-committing .hgtags:
-acb14030fe0a21b60322c440ad2d20cf7685a376 first
-spam
-
-foo bar
-% report tag parse error on other head
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-.hgtags@75d9f02dfe28, line 2: cannot parse entry
-.hgtags@75d9f02dfe28, line 4: node 'foo' is not well formed
-.hgtags@c4be69a18c11, line 2: node 'x' is not well formed
-tip                                8:c4be69a18c11
-first                              0:acb14030fe0a
-changeset:   8:c4be69a18c11
-tag:         tip
-parent:      3:ac5e980c4dc0
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     head
-
-% test tag precedence rules
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-tip                                4:0c192d7d5e6b
-bar                                1:78391a272241
-tip                                4:0c192d7d5e6b
-bar                                1:78391a272241
-% detailed dump of tag info
-heads:
-4:0c192d7d5e6b
-3:6fa450212aeb
-2:7a94127795a3
-rev 2: .hgtags:
-bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
-rev 3: .hgtags:
-bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
-bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
-78391a272241d70354aa14c874552cad6b51bb42 bar
-rev 4: .hgtags:
-bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
-.hg/tags.cache:
-4 0c192d7d5e6b78a714de54a2e9627952a877e25a 0c04f2a8af31de17fab7422878ee5a2dadbc943d
-3 6fa450212aeb2a21ed616a54aea39a4a27894cd7 7d3b718c964ef37b89e550ebdafd5789e76ce1b0
-2 7a94127795a33c10a370c93f731fd9fea0b79af6 0c04f2a8af31de17fab7422878ee5a2dadbc943d
-
-78391a272241d70354aa14c874552cad6b51bb42 bar
-% test tag removal
-changeset:   5:5f6e8655b1c7
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-files:       .hgtags
-description:
-Removed tag bar
-
-
-diff -r 0c192d7d5e6b -r 5f6e8655b1c7 .hgtags
---- a/.hgtags	Thu Jan 01 00:00:00 1970 +0000
-+++ b/.hgtags	Thu Jan 01 00:00:00 1970 +0000
-@@ -1,1 +1,3 @@
- bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
-+78391a272241d70354aa14c874552cad6b51bb42 bar
-+0000000000000000000000000000000000000000 bar
-
-tip                                5:5f6e8655b1c7
-tip                                5:5f6e8655b1c7
-% remove nonexistent tag
-abort: tag 'foobar' does not exist
-changeset:   5:5f6e8655b1c7
-tag:         tip
-user:        test
-date:        Thu Jan 01 00:00:00 1970 +0000
-summary:     Removed tag bar
-
-% rollback undoes tag operation
-rolling back to revision 4 (undo commit)
-tip                                4:0c192d7d5e6b
-bar                                1:78391a272241
-tip                                4:0c192d7d5e6b
-bar                                1:78391a272241
-% test tag rank
-tip                                5:85f05169d91d
-bar                                0:bbd179dfa0a7
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-tip                                6:735c3ca72986
-bar                                0:bbd179dfa0a7
-% don't allow moving tag without -f
-abort: tag 'bar' already exists (use -f to force)
-tip                                6:735c3ca72986
-bar                                0:bbd179dfa0a7
-% strip 1: expose an old head
-tip                                5:735c3ca72986
-bar                                1:78391a272241
-tip                                5:735c3ca72986
-bar                                1:78391a272241
-% strip 2: destroy whole branch, no old head exposed
-tip                                4:735c3ca72986
-bar                                0:bbd179dfa0a7
-tip                                4:735c3ca72986
-bar                                0:bbd179dfa0a7
-% test tag rank with 3 heads
-adding foo
-tip                                3:197c21bbbf2c
-bar                                2:6fa450212aeb
-% bar should still point to rev 2
-tip                                4:3b4b14ed0202
-bar                                2:6fa450212aeb
-% remove local as global and global as local
-adding foo
-abort: tag 'localtag' is not a global tag
-abort: tag 'globaltag' is not a local tag
-tip                                1:a0b6fe111088
-localtag                           0:bbd179dfa0a7 local
-globaltag                          0:bbd179dfa0a7
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-tags.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,367 @@
+Helper functions:
+
+  $ cacheexists() {
+  >   [ -f .hg/tags.cache ] && echo "tag cache exists" || echo "no tag cache"
+  > }
+
+  $ dumptags() {
+  >     rev=$1
+  >     echo "rev $rev: .hgtags:"
+  >     hg cat -r$rev .hgtags
+  > }
+
+# XXX need to test that the tag cache works when we strip an old head
+# and add a new one rooted off non-tip: i.e. node and rev of tip are the
+# same, but stuff has changed behind tip.
+
+Setup:
+
+  $ hg init t
+  $ cd t
+  $ cacheexists
+  no tag cache
+  $ hg id
+  000000000000 tip
+  $ cacheexists
+  no tag cache
+  $ echo a > a
+  $ hg add a
+  $ hg commit -m "test"
+  $ hg co
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg identify
+  acb14030fe0a tip
+  $ cacheexists
+  tag cache exists
+
+Create local tag with long name:
+
+  $ T=`hg identify --debug --id`
+  $ hg tag -l "This is a local tag with a really long name!"
+  $ hg tags
+  tip                                0:acb14030fe0a
+  This is a local tag with a really long name!     0:acb14030fe0a
+  $ rm .hg/localtags
+
+Create a tag behind hg's back:
+
+  $ echo "$T first" > .hgtags
+  $ cat .hgtags
+  acb14030fe0a21b60322c440ad2d20cf7685a376 first
+  $ hg add .hgtags
+  $ hg commit -m "add tags"
+  $ hg tags
+  tip                                1:b9154636be93
+  first                              0:acb14030fe0a
+  $ hg identify
+  b9154636be93 tip
+
+Repeat with cold tag cache:
+
+  $ rm -f .hg/tags.cache
+  $ hg identify
+  b9154636be93 tip
+
+And again, but now unable to write tag cache:
+
+  $ rm -f .hg/tags.cache
+  $ chmod 555 .hg
+  $ hg identify
+  b9154636be93 tip
+  $ chmod 755 .hg
+
+Create a branch:
+
+  $ echo bb > a
+  $ hg status
+  M a
+  $ hg identify
+  b9154636be93+ tip
+  $ hg co first
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ hg id
+  acb14030fe0a+ first
+  $ hg -v id
+  acb14030fe0a+ first
+  $ hg status
+  M a
+  $ echo 1 > b
+  $ hg add b
+  $ hg commit -m "branch"
+  created new head
+  $ hg id
+  c8edf04160c7 tip
+
+Merge the two heads:
+
+  $ hg merge 1
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg id
+  c8edf04160c7+b9154636be93+ tip
+  $ hg status
+  M .hgtags
+  $ hg commit -m "merge"
+
+Create a fake head, make sure tag not visible afterwards:
+
+  $ cp .hgtags tags
+  $ hg tag last
+  $ hg rm .hgtags
+  $ hg commit -m "remove"
+
+  $ mv tags .hgtags
+  $ hg add .hgtags
+  $ hg commit -m "readd"
+  $ 
+  $ hg tags
+  tip                                6:35ff301afafe
+  first                              0:acb14030fe0a
+
+Add invalid tags:
+
+  $ echo "spam" >> .hgtags
+  $ echo >> .hgtags
+  $ echo "foo bar" >> .hgtags
+  $ echo "$T invalid" | sed "s/..../a5a5/" >> .hg/localtags
+  $ echo "committing .hgtags:"
+  committing .hgtags:
+  $ cat .hgtags 
+  acb14030fe0a21b60322c440ad2d20cf7685a376 first
+  spam
+  
+  foo bar
+  $ hg commit -m "tags"
+
+Report tag parse error on other head:
+
+  $ hg up 3
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo 'x y' >> .hgtags
+  $ hg commit -m "head"
+  created new head
+
+  $ hg tags
+  .hgtags@75d9f02dfe28, line 2: cannot parse entry
+  .hgtags@75d9f02dfe28, line 4: node 'foo' is not well formed
+  .hgtags@c4be69a18c11, line 2: node 'x' is not well formed
+  tip                                8:c4be69a18c11
+  first                              0:acb14030fe0a
+  $ hg tip
+  changeset:   8:c4be69a18c11
+  tag:         tip
+  parent:      3:ac5e980c4dc0
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     head
+  
+
+Test tag precedence rules:
+
+  $ cd ..
+  $ hg init t2
+  $ cd t2
+  $ echo foo > foo
+  $ hg add foo
+  $ hg ci -m 'add foo'      # rev 0
+  $ hg tag bar              # rev 1
+  $ echo >> foo
+  $ hg ci -m 'change foo 1' # rev 2
+  $ hg up -C 1
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg tag -r 1 -f bar      # rev 3
+  $ hg up -C 1
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo >> foo
+  $ hg ci -m 'change foo 2' # rev 4
+  created new head
+  $ hg tags
+  tip                                4:0c192d7d5e6b
+  bar                                1:78391a272241
+
+Repeat in case of cache effects:
+
+  $ hg tags
+  tip                                4:0c192d7d5e6b
+  bar                                1:78391a272241
+
+Detailed dump of tag info:
+
+  $ hg heads -q             # expect 4, 3, 2
+  4:0c192d7d5e6b
+  3:6fa450212aeb
+  2:7a94127795a3
+  $ dumptags 2
+  rev 2: .hgtags:
+  bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
+  $ dumptags 3
+  rev 3: .hgtags:
+  bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
+  bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
+  78391a272241d70354aa14c874552cad6b51bb42 bar
+  $ dumptags 4
+  rev 4: .hgtags:
+  bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
+
+Dump cache:
+
+  $ cat .hg/tags.cache
+  4 0c192d7d5e6b78a714de54a2e9627952a877e25a 0c04f2a8af31de17fab7422878ee5a2dadbc943d
+  3 6fa450212aeb2a21ed616a54aea39a4a27894cd7 7d3b718c964ef37b89e550ebdafd5789e76ce1b0
+  2 7a94127795a33c10a370c93f731fd9fea0b79af6 0c04f2a8af31de17fab7422878ee5a2dadbc943d
+  
+  78391a272241d70354aa14c874552cad6b51bb42 bar
+
+Test tag removal:
+
+  $ hg tag --remove bar     # rev 5
+  $ hg tip -vp
+  changeset:   5:5f6e8655b1c7
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  files:       .hgtags
+  description:
+  Removed tag bar
+  
+  
+  diff -r 0c192d7d5e6b -r 5f6e8655b1c7 .hgtags
+  --- a/.hgtags	Thu Jan 01 00:00:00 1970 +0000
+  +++ b/.hgtags	Thu Jan 01 00:00:00 1970 +0000
+  @@ -1,1 +1,3 @@
+   bbd179dfa0a71671c253b3ae0aa1513b60d199fa bar
+  +78391a272241d70354aa14c874552cad6b51bb42 bar
+  +0000000000000000000000000000000000000000 bar
+  
+  $ hg tags
+  tip                                5:5f6e8655b1c7
+  $ hg tags                 # again, try to expose cache bugs
+  tip                                5:5f6e8655b1c7
+
+Remove nonexistent tag:
+
+  $ hg tag --remove foobar
+  abort: tag 'foobar' does not exist
+  $ hg tip
+  changeset:   5:5f6e8655b1c7
+  tag:         tip
+  user:        test
+  date:        Thu Jan 01 00:00:00 1970 +0000
+  summary:     Removed tag bar
+  
+
+Undo a tag with rollback:
+
+  $ hg rollback             # destroy rev 5 (restore bar)
+  rolling back to revision 4 (undo commit)
+  $ hg tags
+  tip                                4:0c192d7d5e6b
+  bar                                1:78391a272241
+  $ hg tags
+  tip                                4:0c192d7d5e6b
+  bar                                1:78391a272241
+
+Test tag rank:
+
+  $ cd ..
+  $ hg init t3
+  $ cd t3
+  $ echo foo > foo
+  $ hg add foo
+  $ hg ci -m 'add foo'       # rev 0
+  $ hg tag -f bar            # rev 1 bar -> 0
+  $ hg tag -f bar            # rev 2 bar -> 1
+  $ hg tag -fr 0 bar         # rev 3 bar -> 0
+  $ hg tag -fr 1 bar         # rev 4 bar -> 1
+  $ hg tag -fr 0 bar         # rev 5 bar -> 0
+  $ hg tags
+  tip                                5:85f05169d91d
+  bar                                0:bbd179dfa0a7
+  $ hg co 3
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo barbar > foo
+  $ hg ci -m 'change foo'    # rev 6
+  created new head
+  $ hg tags
+  tip                                6:735c3ca72986
+  bar                                0:bbd179dfa0a7
+
+Don't allow moving tag without -f:
+
+  $ hg tag -r 3 bar
+  abort: tag 'bar' already exists (use -f to force)
+  $ hg tags
+  tip                                6:735c3ca72986
+  bar                                0:bbd179dfa0a7
+
+Strip 1: expose an old head:
+
+  $ hg --config extensions.mq= strip 5
+  saved backup bundle to .*
+  $ hg tags                  # partly stale cache
+  tip                                5:735c3ca72986
+  bar                                1:78391a272241
+  $ hg tags                  # up-to-date cache
+  tip                                5:735c3ca72986
+  bar                                1:78391a272241
+
+Strip 2: destroy whole branch, no old head exposed
+
+  $ hg --config extensions.mq= strip 4
+  saved backup bundle to .*
+  $ hg tags                  # partly stale
+  tip                                4:735c3ca72986
+  bar                                0:bbd179dfa0a7
+  $ rm -f .hg/tags.cache
+  $ hg tags                  # cold cache
+  tip                                4:735c3ca72986
+  bar                                0:bbd179dfa0a7
+
+Test tag rank with 3 heads:
+
+  $ cd ..
+  $ hg init t4
+  $ cd t4
+  $ echo foo > foo
+  $ hg add
+  adding foo
+  $ hg ci -m 'add foo'                 # rev 0
+  $ hg tag bar                         # rev 1 bar -> 0
+  $ hg tag -f bar                      # rev 2 bar -> 1
+  $ hg up -qC 0
+  $ hg tag -fr 2 bar                   # rev 3 bar -> 2
+  $ hg tags
+  tip                                3:197c21bbbf2c
+  bar                                2:6fa450212aeb
+  $ hg up -qC 0
+  $ hg tag -m 'retag rev 0' -fr 0 bar  # rev 4 bar -> 0, but bar stays at 2
+
+Bar should still point to rev 2:
+
+  $ hg tags
+  tip                                4:3b4b14ed0202
+  bar                                2:6fa450212aeb
+
+Test that removing global/local tags does not get confused when trying
+to remove a tag of type X which actually only exists as a type Y:
+
+  $ cd ..
+  $ hg init t5
+  $ cd t5
+  $ echo foo > foo
+  $ hg add
+  adding foo
+  $ hg ci -m 'add foo'                 # rev 0
+
+  $ hg tag -r 0 -l localtag
+  $ hg tag --remove localtag
+  abort: tag 'localtag' is not a global tag
+  $ 
+  $ hg tag -r 0 globaltag
+  $ hg tag --remove -l globaltag
+  abort: tag 'globaltag' is not a local tag
+  $ hg tags -v
+  tip                                1:a0b6fe111088
+  localtag                           0:bbd179dfa0a7 local
+  globaltag                          0:bbd179dfa0a7
+  $ exit 0
--- a/tests/test-transplant	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,168 +0,0 @@
-#!/bin/sh
-
-cat <<EOF >> $HGRCPATH
-[extensions]
-transplant=
-EOF
-
-hg init t
-cd t
-echo r1 > r1
-hg ci -Amr1 -d'0 0'
-echo r2 > r2
-hg ci -Amr2 -d'1 0'
-hg up 0
-
-echo b1 > b1
-hg ci -Amb1 -d '0 0'
-echo b2 > b2
-hg ci -Amb2 -d '1 0'
-echo b3 > b3
-hg ci -Amb3 -d '2 0'
-
-hg log --template '{rev} {parents} {desc}\n'
-
-hg clone . ../rebase
-cd ../rebase
-
-hg up -C 1
-echo '% rebase b onto r1'
-hg transplant -a -b tip
-hg log --template '{rev} {parents} {desc}\n'
-
-hg clone ../t ../prune
-cd ../prune
-
-hg up -C 1
-echo '% rebase b onto r1, skipping b2'
-hg transplant -a -b tip -p 3
-hg log --template '{rev} {parents} {desc}\n'
-
-echo '% remote transplant'
-hg clone -r 1 ../t ../remote
-cd ../remote
-hg transplant --log -s ../t 2 4
-hg log --template '{rev} {parents} {desc}\n'
-
-echo '% skip previous transplants'
-hg transplant -s ../t -a -b 4
-hg log --template '{rev} {parents} {desc}\n'
-
-echo '% skip local changes transplanted to the source'
-echo b4 > b4
-hg ci -Amb4 -d '3 0'
-hg clone ../t ../pullback
-cd ../pullback
-hg transplant -s ../remote -a -b tip
-
-echo '% remote transplant with pull'
-hg -R ../t serve -p $HGPORT -d --pid-file=../t.pid
-cat ../t.pid >> $DAEMON_PIDS
-
-hg clone -r 0 ../t ../rp
-cd ../rp
-hg transplant -s http://localhost:$HGPORT/ 2 4
-hg log --template '{rev} {parents} {desc}\n'
-
-echo '% transplant --continue'
-hg init ../tc
-cd ../tc
-cat <<EOF > foo
-foo
-bar
-baz
-EOF
-echo toremove > toremove
-hg ci -Amfoo
-cat <<EOF > foo
-foo2
-bar2
-baz2
-EOF
-rm toremove
-echo added > added
-hg ci -Amfoo2
-echo bar > bar
-hg ci -Ambar
-echo bar2 >> bar
-hg ci -mbar2
-hg up 0
-echo foobar > foo
-hg ci -mfoobar
-hg transplant 1:3
-# transplant -c shouldn't use an old changeset
-hg up -C
-rm added
-hg transplant 1
-hg transplant --continue
-hg transplant 1:3
-hg locate
-cd ..
-
-# Test transplant --merge (issue 1111)
-echo % test transplant merge
-hg init t1111
-cd t1111
-echo a > a
-hg ci -Am adda
-echo b >> a
-hg ci -m appendb
-echo c >> a
-hg ci -m appendc
-hg up -C 0
-echo d >> a
-hg ci -m appendd
-echo % tranplant
-hg transplant -m 1
-cd ..
-
-echo '% test transplant into empty repository'
-hg init empty
-cd empty
-hg transplant -s ../t -b tip -a
-cd ..
-
-echo '% test filter'
-hg init filter
-cd filter
-cat <<'EOF' >test-filter
-#!/bin/sh
-sed 's/r1/r2/' $1 > $1.new
-mv $1.new $1
-EOF
-chmod +x test-filter
-hg transplant -s ../t -b tip -a --filter ./test-filter |\
-    sed 's/filtering.*/filtering/g'
-hg log --template '{rev} {parents} {desc}\n'
-cd ..
-
-echo '% test filter with failed patch'
-cd filter
-hg up 0
-echo foo > b1
-hg ci -d '0 0' -Am foo
-hg transplant 1 --filter ./test-filter |\
-    sed 's/filtering.*/filtering/g'
-cd ..
-
-echo '% test with a win32ext like setup (differing EOLs)'
-hg init twin1
-cd twin1
-echo a > a
-echo b > b
-echo b >> b
-hg ci -Am t
-echo a > b
-echo b >> b
-hg ci -m changeb
-cd ..
-
-hg init twin2
-cd twin2
-echo '[patch]' >> .hg/hgrc
-echo 'eol = crlf' >> .hg/hgrc
-python -c "file('b', 'wb').write('b\r\nb\r\n')"
-hg ci -m addb
-hg transplant -s ../twin1 tip
-python -c "print repr(file('b', 'rb').read())"
-cd ..
--- a/tests/test-transplant.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,179 +0,0 @@
-adding r1
-adding r2
-0 files updated, 0 files merged, 1 files removed, 0 files unresolved
-adding b1
-created new head
-adding b2
-adding b3
-4  b3
-3  b2
-2 0:17ab29e464c6  b1
-1  r2
-0  r1
-updating to branch default
-4 files updated, 0 files merged, 0 files removed, 0 files unresolved
-1 files updated, 0 files merged, 3 files removed, 0 files unresolved
-% rebase b onto r1
-applying 37a1297eb21b
-37a1297eb21b transplanted to e234d668f844
-applying 722f4667af76
-722f4667af76 transplanted to 539f377d78df
-applying a53251cdf717
-a53251cdf717 transplanted to ffd6818a3975
-7  b3
-6  b2
-5 1:d11e3596cc1a  b1
-4  b3
-3  b2
-2 0:17ab29e464c6  b1
-1  r2
-0  r1
-updating to branch default
-4 files updated, 0 files merged, 0 files removed, 0 files unresolved
-1 files updated, 0 files merged, 3 files removed, 0 files unresolved
-% rebase b onto r1, skipping b2
-applying 37a1297eb21b
-37a1297eb21b transplanted to e234d668f844
-applying a53251cdf717
-a53251cdf717 transplanted to 7275fda4d04f
-6  b3
-5 1:d11e3596cc1a  b1
-4  b3
-3  b2
-2 0:17ab29e464c6  b1
-1  r2
-0  r1
-% remote transplant
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 2 changesets with 2 changes to 2 files
-updating to branch default
-2 files updated, 0 files merged, 0 files removed, 0 files unresolved
-searching for changes
-applying 37a1297eb21b
-37a1297eb21b transplanted to c19cf0ccb069
-applying a53251cdf717
-a53251cdf717 transplanted to f7fe5bf98525
-3  b3
-(transplanted from a53251cdf717679d1907b289f991534be05c997a)
-2  b1
-(transplanted from 37a1297eb21b3ef5c5d2ffac22121a0988ed9f21)
-1  r2
-0  r1
-% skip previous transplants
-searching for changes
-applying 722f4667af76
-722f4667af76 transplanted to 47156cd86c0b
-4  b2
-3  b3
-(transplanted from a53251cdf717679d1907b289f991534be05c997a)
-2  b1
-(transplanted from 37a1297eb21b3ef5c5d2ffac22121a0988ed9f21)
-1  r2
-0  r1
-% skip local changes transplanted to the source
-adding b4
-updating to branch default
-4 files updated, 0 files merged, 0 files removed, 0 files unresolved
-searching for changes
-applying 4333daefcb15
-4333daefcb15 transplanted to 5f42c04e07cc
-% remote transplant with pull
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-updating to branch default
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-searching for changes
-searching for changes
-adding changesets
-adding manifests
-adding file changes
-added 1 changesets with 1 changes to 1 files
-applying a53251cdf717
-a53251cdf717 transplanted to 8d9279348abb
-2  b3
-1  b1
-0  r1
-% transplant --continue
-adding foo
-adding toremove
-adding added
-removing toremove
-adding bar
-2 files updated, 0 files merged, 2 files removed, 0 files unresolved
-created new head
-applying a1e30dd1b8e7
-patching file foo
-Hunk #1 FAILED at 0
-1 out of 1 hunks FAILED -- saving rejects to file foo.rej
-patch failed to apply
-abort: Fix up the merge and run hg transplant --continue
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-applying a1e30dd1b8e7
-patching file foo
-Hunk #1 FAILED at 0
-1 out of 1 hunks FAILED -- saving rejects to file foo.rej
-patch failed to apply
-abort: Fix up the merge and run hg transplant --continue
-a1e30dd1b8e7 transplanted as f1563cf27039
-skipping already applied revision 1:a1e30dd1b8e7
-applying 1739ac5f6139
-1739ac5f6139 transplanted to d649c221319f
-applying 0282d5fbbe02
-0282d5fbbe02 transplanted to 77418277ccb3
-added
-bar
-foo
-% test transplant merge
-adding a
-1 files updated, 0 files merged, 0 files removed, 0 files unresolved
-created new head
-% tranplant
-applying 42dc4432fd35
-1:42dc4432fd35 merged at a9f4acbac129
-% test transplant into empty repository
-requesting all changes
-adding changesets
-adding manifests
-adding file changes
-added 4 changesets with 4 changes to 4 files
-% test filter
-filtering
-applying 17ab29e464c6
-17ab29e464c6 transplanted to e9ffc54ea104
-filtering
-applying 37a1297eb21b
-37a1297eb21b transplanted to 348b36d0b6a5
-filtering
-applying 722f4667af76
-722f4667af76 transplanted to 0aa6979afb95
-filtering
-applying a53251cdf717
-a53251cdf717 transplanted to 14f8512272b5
-3  b3
-2  b2
-1  b1
-0  r2
-% test filter with failed patch
-0 files updated, 0 files merged, 3 files removed, 0 files unresolved
-adding b1
-adding test-filter
-created new head
-file b1 already exists
-1 out of 1 hunks FAILED -- saving rejects to file b1.rej
-abort: Fix up the merge and run hg transplant --continue
-filtering
-applying 348b36d0b6a5
-patch failed to apply
-% test with a win32ext like setup (differing EOLs)
-adding a
-adding b
-nothing changed
-applying 2e849d776c17
-2e849d776c17 transplanted to 589cea8ba85b
-'a\r\nb\r\n'
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-transplant.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,353 @@
+  $ cat <<EOF >> $HGRCPATH
+  > [extensions]
+  > transplant=
+  > EOF
+
+  $ hg init t
+  $ cd t
+  $ echo r1 > r1
+  $ hg ci -Amr1 -d'0 0'
+  adding r1
+  $ echo r2 > r2
+  $ hg ci -Amr2 -d'1 0'
+  adding r2
+  $ hg up 0
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+
+  $ echo b1 > b1
+  $ hg ci -Amb1 -d '0 0'
+  adding b1
+  created new head
+  $ echo b2 > b2
+  $ hg ci -Amb2 -d '1 0'
+  adding b2
+  $ echo b3 > b3
+  $ hg ci -Amb3 -d '2 0'
+  adding b3
+
+  $ hg log --template '{rev} {parents} {desc}\n'
+  4  b3
+  3  b2
+  2 0:17ab29e464c6  b1
+  1  r2
+  0  r1
+
+  $ hg clone . ../rebase
+  updating to branch default
+  4 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd ../rebase
+
+  $ hg up -C 1
+  1 files updated, 0 files merged, 3 files removed, 0 files unresolved
+
+rebase b onto r1
+
+  $ hg transplant -a -b tip
+  applying 37a1297eb21b
+  37a1297eb21b transplanted to e234d668f844
+  applying 722f4667af76
+  722f4667af76 transplanted to 539f377d78df
+  applying a53251cdf717
+  a53251cdf717 transplanted to ffd6818a3975
+  $ hg log --template '{rev} {parents} {desc}\n'
+  7  b3
+  6  b2
+  5 1:d11e3596cc1a  b1
+  4  b3
+  3  b2
+  2 0:17ab29e464c6  b1
+  1  r2
+  0  r1
+
+  $ hg clone ../t ../prune
+  updating to branch default
+  4 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd ../prune
+
+  $ hg up -C 1
+  1 files updated, 0 files merged, 3 files removed, 0 files unresolved
+
+rebase b onto r1, skipping b2
+
+  $ hg transplant -a -b tip -p 3
+  applying 37a1297eb21b
+  37a1297eb21b transplanted to e234d668f844
+  applying a53251cdf717
+  a53251cdf717 transplanted to 7275fda4d04f
+  $ hg log --template '{rev} {parents} {desc}\n'
+  6  b3
+  5 1:d11e3596cc1a  b1
+  4  b3
+  3  b2
+  2 0:17ab29e464c6  b1
+  1  r2
+  0  r1
+
+
+remote transplant
+
+  $ hg clone -r 1 ../t ../remote
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 2 changesets with 2 changes to 2 files
+  updating to branch default
+  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd ../remote
+  $ hg transplant --log -s ../t 2 4
+  searching for changes
+  applying 37a1297eb21b
+  37a1297eb21b transplanted to c19cf0ccb069
+  applying a53251cdf717
+  a53251cdf717 transplanted to f7fe5bf98525
+  $ hg log --template '{rev} {parents} {desc}\n'
+  3  b3
+  (transplanted from a53251cdf717679d1907b289f991534be05c997a)
+  2  b1
+  (transplanted from 37a1297eb21b3ef5c5d2ffac22121a0988ed9f21)
+  1  r2
+  0  r1
+
+skip previous transplants
+
+  $ hg transplant -s ../t -a -b 4
+  searching for changes
+  applying 722f4667af76
+  722f4667af76 transplanted to 47156cd86c0b
+  $ hg log --template '{rev} {parents} {desc}\n'
+  4  b2
+  3  b3
+  (transplanted from a53251cdf717679d1907b289f991534be05c997a)
+  2  b1
+  (transplanted from 37a1297eb21b3ef5c5d2ffac22121a0988ed9f21)
+  1  r2
+  0  r1
+
+skip local changes transplanted to the source
+
+  $ echo b4 > b4
+  $ hg ci -Amb4 -d '3 0'
+  adding b4
+  $ hg clone ../t ../pullback
+  updating to branch default
+  4 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd ../pullback
+  $ hg transplant -s ../remote -a -b tip
+  searching for changes
+  applying 4333daefcb15
+  4333daefcb15 transplanted to 5f42c04e07cc
+
+
+remote transplant with pull
+
+  $ hg -R ../t serve -p $HGPORT -d --pid-file=../t.pid
+  $ cat ../t.pid >> $DAEMON_PIDS
+
+  $ hg clone -r 0 ../t ../rp
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd ../rp
+  $ hg transplant -s http://localhost:$HGPORT/ 2 4
+  searching for changes
+  searching for changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  applying a53251cdf717
+  a53251cdf717 transplanted to 8d9279348abb
+  $ hg log --template '{rev} {parents} {desc}\n'
+  2  b3
+  1  b1
+  0  r1
+
+transplant --continue
+
+  $ hg init ../tc
+  $ cd ../tc
+  $ cat <<EOF > foo
+  > foo
+  > bar
+  > baz
+  > EOF
+  $ echo toremove > toremove
+  $ hg ci -Amfoo
+  adding foo
+  adding toremove
+  $ cat <<EOF > foo
+  > foo2
+  > bar2
+  > baz2
+  > EOF
+  $ rm toremove
+  $ echo added > added
+  $ hg ci -Amfoo2
+  adding added
+  removing toremove
+  $ echo bar > bar
+  $ hg ci -Ambar
+  adding bar
+  $ echo bar2 >> bar
+  $ hg ci -mbar2
+  $ hg up 0
+  2 files updated, 0 files merged, 2 files removed, 0 files unresolved
+  $ echo foobar > foo
+  $ hg ci -mfoobar
+  created new head
+  $ hg transplant 1:3
+  applying a1e30dd1b8e7
+  patching file foo
+  Hunk #1 FAILED at 0
+  1 out of 1 hunks FAILED -- saving rejects to file foo.rej
+  patch failed to apply
+  abort: Fix up the merge and run hg transplant --continue
+
+transplant -c shouldn't use an old changeset
+
+  $ hg up -C
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ rm added
+  $ hg transplant 1
+  applying a1e30dd1b8e7
+  patching file foo
+  Hunk #1 FAILED at 0
+  1 out of 1 hunks FAILED -- saving rejects to file foo.rej
+  patch failed to apply
+  abort: Fix up the merge and run hg transplant --continue
+  $ hg transplant --continue
+  a1e30dd1b8e7 transplanted as f1563cf27039
+  $ hg transplant 1:3
+  skipping already applied revision 1:a1e30dd1b8e7
+  applying 1739ac5f6139
+  1739ac5f6139 transplanted to d649c221319f
+  applying 0282d5fbbe02
+  0282d5fbbe02 transplanted to 77418277ccb3
+  $ hg locate
+  added
+  bar
+  foo
+  $ cd ..
+
+Test transplant --merge (issue 1111)
+test transplant merge
+
+  $ hg init t1111
+  $ cd t1111
+  $ echo a > a
+  $ hg ci -Am adda
+  adding a
+  $ echo b >> a
+  $ hg ci -m appendb
+  $ echo c >> a
+  $ hg ci -m appendc
+  $ hg up -C 0
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ echo d >> a
+  $ hg ci -m appendd
+  created new head
+
+tranplant
+
+  $ hg transplant -m 1
+  applying 42dc4432fd35
+  1:42dc4432fd35 merged at a9f4acbac129
+  $ cd ..
+
+test transplant into empty repository
+
+  $ hg init empty
+  $ cd empty
+  $ hg transplant -s ../t -b tip -a
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 4 changesets with 4 changes to 4 files
+  $ cd ..
+
+
+test filter
+
+  $ hg init filter
+  $ cd filter
+  $ cat <<'EOF' >test-filter
+  > #!/bin/sh
+  > sed 's/r1/r2/' $1 > $1.new
+  > mv $1.new $1
+  > EOF
+  $ chmod +x test-filter
+  $ hg transplant -s ../t -b tip -a --filter ./test-filter
+  filtering .*
+  applying 17ab29e464c6
+  17ab29e464c6 transplanted to e9ffc54ea104
+  filtering .*
+  applying 37a1297eb21b
+  37a1297eb21b transplanted to 348b36d0b6a5
+  filtering .*
+  applying 722f4667af76
+  722f4667af76 transplanted to 0aa6979afb95
+  filtering .*
+  applying a53251cdf717
+  a53251cdf717 transplanted to 14f8512272b5
+  $ hg log --template '{rev} {parents} {desc}\n'
+  3  b3
+  2  b2
+  1  b1
+  0  r2
+  $ cd ..
+
+
+test filter with failed patch
+
+  $ cd filter
+  $ hg up 0
+  0 files updated, 0 files merged, 3 files removed, 0 files unresolved
+  $ echo foo > b1
+  $ hg ci -d '0 0' -Am foo
+  adding b1
+  adding test-filter
+  created new head
+  $ hg transplant 1 --filter ./test-filter
+  filtering .*
+  applying 348b36d0b6a5
+  file b1 already exists
+  1 out of 1 hunks FAILED -- saving rejects to file b1.rej
+  patch failed to apply
+  abort: Fix up the merge and run hg transplant --continue
+  $ cd ..
+
+
+test with a win32ext like setup (differing EOLs)
+
+  $ hg init twin1
+  $ cd twin1
+  $ echo a > a
+  $ echo b > b
+  $ echo b >> b
+  $ hg ci -Am t
+  adding a
+  adding b
+  $ echo a > b
+  $ echo b >> b
+  $ hg ci -m changeb
+  $ cd ..
+
+  $ hg init twin2
+  $ cd twin2
+  $ echo '[patch]' >> .hg/hgrc
+  $ echo 'eol = crlf' >> .hg/hgrc
+  $ python -c "file('b', 'wb').write('b\r\nb\r\n')"
+  $ hg ci -m addb
+  nothing changed
+  $ hg transplant -s ../twin1 tip
+  applying 2e849d776c17
+  2e849d776c17 transplanted to 589cea8ba85b
+  $ python -c "print repr(file('b', 'rb').read())"
+  'a\r\nb\r\n'
+  $ cd ..
--- a/tests/test-verify	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,51 +0,0 @@
-#!/bin/sh
-
-echo % prepare repo
-hg init a
-cd a
-echo "some text" > FOO.txt
-echo "another text" > bar.txt
-echo "more text" > QUICK.txt
-hg add
-hg ci -mtest1
-
-echo
-echo % verify
-hg verify
-
-echo
-echo % verify with journal
-touch .hg/store/journal
-hg verify
-rm .hg/store/journal
-
-echo
-echo % introduce some bugs in repo
-cd .hg/store/data
-mv _f_o_o.txt.i X_f_o_o.txt.i
-mv bar.txt.i xbar.txt.i
-rm _q_u_i_c_k.txt.i
-
-echo
-echo % verify
-hg verify
-
-cd ..
-
-echo % test revlog corruption
-hg init b
-cd b
-
-touch a
-hg add a
-hg ci -m a
-
-echo 'corrupted' > b
-dd if=.hg/store/data/a.i of=start bs=1 count=20 2>/dev/null
-cat start b > .hg/store/data/a.i
-
-echo
-echo % verify
-hg verify
-
-exit 0
--- a/tests/test-verify.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,52 +0,0 @@
-% prepare repo
-adding FOO.txt
-adding QUICK.txt
-adding bar.txt
-
-% verify
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-3 files, 1 changesets, 3 total revisions
-
-% verify with journal
-abandoned transaction found - run hg recover
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
-3 files, 1 changesets, 3 total revisions
-
-% introduce some bugs in repo
-
-% verify
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
- data/FOO.txt.i@0: missing revlog!
- 0: empty or missing FOO.txt
- FOO.txt@0: f62022d3d590 in manifests not found
- data/QUICK.txt.i@0: missing revlog!
- 0: empty or missing QUICK.txt
- QUICK.txt@0: 88b857db8eba in manifests not found
- data/bar.txt.i@0: missing revlog!
- 0: empty or missing bar.txt
- bar.txt@0: 256559129457 in manifests not found
-3 files, 1 changesets, 0 total revisions
-9 integrity errors encountered!
-(first damaged changeset appears to be 0)
-% test revlog corruption
-
-% verify
-checking changesets
-checking manifests
-crosschecking files in changesets and manifests
-checking files
- a@0: broken revlog! (index data/a.i is corrupted)
-warning: orphan revlog 'data/a.i'
-1 files, 1 changesets, 0 total revisions
-1 warnings encountered!
-1 integrity errors encountered!
-(first damaged changeset appears to be 0)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-verify.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,87 @@
+prepare repo
+
+  $ hg init a
+  $ cd a
+  $ echo "some text" > FOO.txt
+  $ echo "another text" > bar.txt
+  $ echo "more text" > QUICK.txt
+  $ hg add
+  adding FOO.txt
+  adding QUICK.txt
+  adding bar.txt
+  $ hg ci -mtest1
+
+verify
+
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  3 files, 1 changesets, 3 total revisions
+
+verify with journal
+
+  $ touch .hg/store/journal
+  $ hg verify
+  abandoned transaction found - run hg recover
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+  3 files, 1 changesets, 3 total revisions
+  $ rm .hg/store/journal
+
+introduce some bugs in repo
+
+  $ cd .hg/store/data
+  $ mv _f_o_o.txt.i X_f_o_o.txt.i
+  $ mv bar.txt.i xbar.txt.i
+  $ rm _q_u_i_c_k.txt.i
+
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+   data/FOO.txt.i@0: missing revlog!
+   0: empty or missing FOO.txt
+   FOO.txt@0: f62022d3d590 in manifests not found
+   data/QUICK.txt.i@0: missing revlog!
+   0: empty or missing QUICK.txt
+   QUICK.txt@0: 88b857db8eba in manifests not found
+   data/bar.txt.i@0: missing revlog!
+   0: empty or missing bar.txt
+   bar.txt@0: 256559129457 in manifests not found
+  3 files, 1 changesets, 0 total revisions
+  9 integrity errors encountered!
+  (first damaged changeset appears to be 0)
+
+  $ cd ..
+
+test revlog corruption
+
+  $ hg init b
+  $ cd b
+
+  $ touch a
+  $ hg add a
+  $ hg ci -m a
+
+  $ echo 'corrupted' > b
+  $ dd if=.hg/store/data/a.i of=start bs=1 count=20 2>/dev/null
+  $ cat start b > .hg/store/data/a.i
+
+  $ hg verify
+  checking changesets
+  checking manifests
+  crosschecking files in changesets and manifests
+  checking files
+   a@0: broken revlog! (index data/a.i is corrupted)
+  warning: orphan revlog 'data/a.i'
+  1 files, 1 changesets, 0 total revisions
+  1 warnings encountered!
+  1 integrity errors encountered!
+  (first damaged changeset appears to be 0)
+
+  $ exit 0
--- a/tests/test-walk	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,108 +0,0 @@
-#!/bin/sh
-
-debugwalk()
-{
-    echo "hg debugwalk $@"
-    hg debugwalk "$@"
-    echo
-}
-
-chdir()
-{
-    echo "cd $@"
-    cd "$@"
-    echo
-}
-
-mkdir t
-cd t
-hg init
-mkdir -p beans
-for b in kidney navy turtle borlotti black pinto; do
-    echo $b > beans/$b
-done
-mkdir -p mammals/Procyonidae
-for m in cacomistle coatimundi raccoon; do
-    echo $m > mammals/Procyonidae/$m
-done
-echo skunk > mammals/skunk
-echo fennel > fennel
-echo fenugreek > fenugreek
-echo fiddlehead > fiddlehead
-echo glob:glob > glob:glob
-hg addremove
-hg commit -m "commit #0" -d "1000000 0"
-debugwalk
-debugwalk -I.
-chdir mammals
-debugwalk
-debugwalk -X ../beans
-debugwalk -I '*k'
-debugwalk -I 'glob:*k'
-debugwalk -I 'relglob:*k'
-debugwalk -I 'relglob:*k' .
-debugwalk -I 're:.*k$'
-debugwalk -I 'relre:.*k$'
-debugwalk -I 'path:beans'
-debugwalk -I 'relpath:../beans'
-debugwalk .
-debugwalk -I.
-debugwalk Procyonidae
-chdir Procyonidae
-debugwalk .
-debugwalk ..
-chdir ..
-debugwalk ../beans
-debugwalk .
-debugwalk .hg
-debugwalk ../.hg
-chdir ..
-debugwalk -Ibeans
-debugwalk -I '{*,{b,m}*/*}k'
-debugwalk 'glob:mammals/../beans/b*'
-debugwalk '-X*/Procyonidae' mammals
-debugwalk path:mammals
-debugwalk ..
-debugwalk beans/../..
-debugwalk .hg
-debugwalk beans/../.hg
-debugwalk beans/../.hg/data
-debugwalk beans/.hg
-# Don't know how to test absolute paths without always getting a false
-# error.
-#debugwalk `pwd`/beans
-#debugwalk `pwd`/..
-debugwalk glob:\*
-debugwalk 'glob:**e'
-debugwalk 're:.*[kb]$'
-debugwalk path:beans/black
-debugwalk path:beans//black
-debugwalk relglob:Procyonidae
-debugwalk 'relglob:Procyonidae/**'
-debugwalk 'relglob:Procyonidae/**' fennel
-debugwalk beans 'glob:beans/*'
-debugwalk 'glob:mamm**'
-debugwalk 'glob:mamm**' fennel
-debugwalk 'glob:j*'
-debugwalk NOEXIST
-mkfifo fifo
-debugwalk fifo
-rm fenugreek
-debugwalk fenugreek
-hg rm fenugreek
-debugwalk fenugreek
-touch new
-debugwalk new
-
-mkdir ignored
-touch ignored/file
-echo '^ignored$' > .hgignore
-debugwalk ignored
-debugwalk ignored/file
-
-chdir ..
-debugwalk -R t t/mammals/skunk
-mkdir t2
-chdir t2
-debugwalk -R ../t ../t/mammals/skunk
-debugwalk --cwd ../t mammals/skunk
--- a/tests/test-walk.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,303 +0,0 @@
-adding beans/black
-adding beans/borlotti
-adding beans/kidney
-adding beans/navy
-adding beans/pinto
-adding beans/turtle
-adding fennel
-adding fenugreek
-adding fiddlehead
-adding glob:glob
-adding mammals/Procyonidae/cacomistle
-adding mammals/Procyonidae/coatimundi
-adding mammals/Procyonidae/raccoon
-adding mammals/skunk
-hg debugwalk 
-f  beans/black                     beans/black
-f  beans/borlotti                  beans/borlotti
-f  beans/kidney                    beans/kidney
-f  beans/navy                      beans/navy
-f  beans/pinto                     beans/pinto
-f  beans/turtle                    beans/turtle
-f  fennel                          fennel
-f  fenugreek                       fenugreek
-f  fiddlehead                      fiddlehead
-f  glob:glob                       glob:glob
-f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
-f  mammals/skunk                   mammals/skunk
-
-hg debugwalk -I.
-f  beans/black                     beans/black
-f  beans/borlotti                  beans/borlotti
-f  beans/kidney                    beans/kidney
-f  beans/navy                      beans/navy
-f  beans/pinto                     beans/pinto
-f  beans/turtle                    beans/turtle
-f  fennel                          fennel
-f  fenugreek                       fenugreek
-f  fiddlehead                      fiddlehead
-f  glob:glob                       glob:glob
-f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
-f  mammals/skunk                   mammals/skunk
-
-cd mammals
-
-hg debugwalk 
-f  beans/black                     ../beans/black
-f  beans/borlotti                  ../beans/borlotti
-f  beans/kidney                    ../beans/kidney
-f  beans/navy                      ../beans/navy
-f  beans/pinto                     ../beans/pinto
-f  beans/turtle                    ../beans/turtle
-f  fennel                          ../fennel
-f  fenugreek                       ../fenugreek
-f  fiddlehead                      ../fiddlehead
-f  glob:glob                       ../glob:glob
-f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
-f  mammals/skunk                   skunk
-
-hg debugwalk -X ../beans
-f  fennel                          ../fennel
-f  fenugreek                       ../fenugreek
-f  fiddlehead                      ../fiddlehead
-f  glob:glob                       ../glob:glob
-f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
-f  mammals/skunk                   skunk
-
-hg debugwalk -I *k
-f  mammals/skunk  skunk
-
-hg debugwalk -I glob:*k
-f  mammals/skunk  skunk
-
-hg debugwalk -I relglob:*k
-f  beans/black    ../beans/black
-f  fenugreek      ../fenugreek
-f  mammals/skunk  skunk
-
-hg debugwalk -I relglob:*k .
-f  mammals/skunk  skunk
-
-hg debugwalk -I re:.*k$
-f  beans/black    ../beans/black
-f  fenugreek      ../fenugreek
-f  mammals/skunk  skunk
-
-hg debugwalk -I relre:.*k$
-f  beans/black    ../beans/black
-f  fenugreek      ../fenugreek
-f  mammals/skunk  skunk
-
-hg debugwalk -I path:beans
-f  beans/black     ../beans/black
-f  beans/borlotti  ../beans/borlotti
-f  beans/kidney    ../beans/kidney
-f  beans/navy      ../beans/navy
-f  beans/pinto     ../beans/pinto
-f  beans/turtle    ../beans/turtle
-
-hg debugwalk -I relpath:../beans
-f  beans/black     ../beans/black
-f  beans/borlotti  ../beans/borlotti
-f  beans/kidney    ../beans/kidney
-f  beans/navy      ../beans/navy
-f  beans/pinto     ../beans/pinto
-f  beans/turtle    ../beans/turtle
-
-hg debugwalk .
-f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
-f  mammals/skunk                   skunk
-
-hg debugwalk -I.
-f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
-f  mammals/skunk                   skunk
-
-hg debugwalk Procyonidae
-f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
-
-cd Procyonidae
-
-hg debugwalk .
-f  mammals/Procyonidae/cacomistle  cacomistle
-f  mammals/Procyonidae/coatimundi  coatimundi
-f  mammals/Procyonidae/raccoon     raccoon
-
-hg debugwalk ..
-f  mammals/Procyonidae/cacomistle  cacomistle
-f  mammals/Procyonidae/coatimundi  coatimundi
-f  mammals/Procyonidae/raccoon     raccoon
-f  mammals/skunk                   ../skunk
-
-cd ..
-
-hg debugwalk ../beans
-f  beans/black     ../beans/black
-f  beans/borlotti  ../beans/borlotti
-f  beans/kidney    ../beans/kidney
-f  beans/navy      ../beans/navy
-f  beans/pinto     ../beans/pinto
-f  beans/turtle    ../beans/turtle
-
-hg debugwalk .
-f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
-f  mammals/skunk                   skunk
-
-hg debugwalk .hg
-abort: path 'mammals/.hg' is inside repo 'mammals'
-
-hg debugwalk ../.hg
-abort: path contains illegal component: .hg
-
-cd ..
-
-hg debugwalk -Ibeans
-f  beans/black     beans/black
-f  beans/borlotti  beans/borlotti
-f  beans/kidney    beans/kidney
-f  beans/navy      beans/navy
-f  beans/pinto     beans/pinto
-f  beans/turtle    beans/turtle
-
-hg debugwalk -I {*,{b,m}*/*}k
-f  beans/black    beans/black
-f  fenugreek      fenugreek
-f  mammals/skunk  mammals/skunk
-
-hg debugwalk glob:mammals/../beans/b*
-f  beans/black     beans/black
-f  beans/borlotti  beans/borlotti
-
-hg debugwalk -X*/Procyonidae mammals
-f  mammals/skunk  mammals/skunk
-
-hg debugwalk path:mammals
-f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
-f  mammals/skunk                   mammals/skunk
-
-hg debugwalk ..
-abort: .. not under root
-
-hg debugwalk beans/../..
-abort: beans/../.. not under root
-
-hg debugwalk .hg
-abort: path contains illegal component: .hg
-
-hg debugwalk beans/../.hg
-abort: path contains illegal component: .hg
-
-hg debugwalk beans/../.hg/data
-abort: path contains illegal component: .hg/data
-
-hg debugwalk beans/.hg
-abort: path 'beans/.hg' is inside repo 'beans'
-
-hg debugwalk glob:*
-f  fennel      fennel
-f  fenugreek   fenugreek
-f  fiddlehead  fiddlehead
-f  glob:glob   glob:glob
-
-hg debugwalk glob:**e
-f  beans/turtle                    beans/turtle
-f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
-
-hg debugwalk re:.*[kb]$
-f  beans/black    beans/black
-f  fenugreek      fenugreek
-f  glob:glob      glob:glob
-f  mammals/skunk  mammals/skunk
-
-hg debugwalk path:beans/black
-f  beans/black  beans/black  exact
-
-hg debugwalk path:beans//black
-f  beans/black  beans/black  exact
-
-hg debugwalk relglob:Procyonidae
-
-hg debugwalk relglob:Procyonidae/**
-f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
-
-hg debugwalk relglob:Procyonidae/** fennel
-f  fennel                          fennel                          exact
-f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
-
-hg debugwalk beans glob:beans/*
-f  beans/black     beans/black
-f  beans/borlotti  beans/borlotti
-f  beans/kidney    beans/kidney
-f  beans/navy      beans/navy
-f  beans/pinto     beans/pinto
-f  beans/turtle    beans/turtle
-
-hg debugwalk glob:mamm**
-f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
-f  mammals/skunk                   mammals/skunk
-
-hg debugwalk glob:mamm** fennel
-f  fennel                          fennel                          exact
-f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
-f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
-f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
-f  mammals/skunk                   mammals/skunk
-
-hg debugwalk glob:j*
-
-hg debugwalk NOEXIST
-NOEXIST: No such file or directory
-
-hg debugwalk fifo
-fifo: unsupported file type (type is fifo)
-
-hg debugwalk fenugreek
-f  fenugreek  fenugreek  exact
-
-hg debugwalk fenugreek
-f  fenugreek  fenugreek  exact
-
-hg debugwalk new
-f  new  new  exact
-
-hg debugwalk ignored
-
-hg debugwalk ignored/file
-f  ignored/file  ignored/file  exact
-
-cd ..
-
-hg debugwalk -R t t/mammals/skunk
-f  mammals/skunk  t/mammals/skunk  exact
-
-cd t2
-
-hg debugwalk -R ../t ../t/mammals/skunk
-f  mammals/skunk  ../t/mammals/skunk  exact
-
-hg debugwalk --cwd ../t mammals/skunk
-f  mammals/skunk  mammals/skunk  exact
-
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-walk.t	Sat Aug 14 03:30:35 2010 +0200
@@ -0,0 +1,284 @@
+  $ mkdir t
+  $ cd t
+  $ hg init
+  $ mkdir -p beans
+  $ for b in kidney navy turtle borlotti black pinto; do
+  >     echo $b > beans/$b
+  $ done
+  $ mkdir -p mammals/Procyonidae
+  $ for m in cacomistle coatimundi raccoon; do
+  >     echo $m > mammals/Procyonidae/$m
+  $ done
+  $ echo skunk > mammals/skunk
+  $ echo fennel > fennel
+  $ echo fenugreek > fenugreek
+  $ echo fiddlehead > fiddlehead
+  $ echo glob:glob > glob:glob
+  $ hg addremove
+  adding beans/black
+  adding beans/borlotti
+  adding beans/kidney
+  adding beans/navy
+  adding beans/pinto
+  adding beans/turtle
+  adding fennel
+  adding fenugreek
+  adding fiddlehead
+  adding glob:glob
+  adding mammals/Procyonidae/cacomistle
+  adding mammals/Procyonidae/coatimundi
+  adding mammals/Procyonidae/raccoon
+  adding mammals/skunk
+  $ hg commit -m "commit #0" -d "1000000 0"
+
+  $ hg debugwalk
+  f  beans/black                     beans/black
+  f  beans/borlotti                  beans/borlotti
+  f  beans/kidney                    beans/kidney
+  f  beans/navy                      beans/navy
+  f  beans/pinto                     beans/pinto
+  f  beans/turtle                    beans/turtle
+  f  fennel                          fennel
+  f  fenugreek                       fenugreek
+  f  fiddlehead                      fiddlehead
+  f  glob:glob                       glob:glob
+  f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
+  f  mammals/skunk                   mammals/skunk
+  $ hg debugwalk -I.
+  f  beans/black                     beans/black
+  f  beans/borlotti                  beans/borlotti
+  f  beans/kidney                    beans/kidney
+  f  beans/navy                      beans/navy
+  f  beans/pinto                     beans/pinto
+  f  beans/turtle                    beans/turtle
+  f  fennel                          fennel
+  f  fenugreek                       fenugreek
+  f  fiddlehead                      fiddlehead
+  f  glob:glob                       glob:glob
+  f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
+  f  mammals/skunk                   mammals/skunk
+
+  $ cd mammals
+  $ hg debugwalk
+  f  beans/black                     ../beans/black
+  f  beans/borlotti                  ../beans/borlotti
+  f  beans/kidney                    ../beans/kidney
+  f  beans/navy                      ../beans/navy
+  f  beans/pinto                     ../beans/pinto
+  f  beans/turtle                    ../beans/turtle
+  f  fennel                          ../fennel
+  f  fenugreek                       ../fenugreek
+  f  fiddlehead                      ../fiddlehead
+  f  glob:glob                       ../glob:glob
+  f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
+  f  mammals/skunk                   skunk
+  $ hg debugwalk -X ../beans
+  f  fennel                          ../fennel
+  f  fenugreek                       ../fenugreek
+  f  fiddlehead                      ../fiddlehead
+  f  glob:glob                       ../glob:glob
+  f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
+  f  mammals/skunk                   skunk
+  $ hg debugwalk -I '*k'
+  f  mammals/skunk  skunk
+  $ hg debugwalk -I 'glob:*k'
+  f  mammals/skunk  skunk
+  $ hg debugwalk -I 'relglob:*k'
+  f  beans/black    ../beans/black
+  f  fenugreek      ../fenugreek
+  f  mammals/skunk  skunk
+  $ hg debugwalk -I 'relglob:*k' .
+  f  mammals/skunk  skunk
+  $ hg debugwalk -I 're:.*k$'
+  f  beans/black    ../beans/black
+  f  fenugreek      ../fenugreek
+  f  mammals/skunk  skunk
+  $ hg debugwalk -I 'relre:.*k$'
+  f  beans/black    ../beans/black
+  f  fenugreek      ../fenugreek
+  f  mammals/skunk  skunk
+  $ hg debugwalk -I 'path:beans'
+  f  beans/black     ../beans/black
+  f  beans/borlotti  ../beans/borlotti
+  f  beans/kidney    ../beans/kidney
+  f  beans/navy      ../beans/navy
+  f  beans/pinto     ../beans/pinto
+  f  beans/turtle    ../beans/turtle
+  $ hg debugwalk -I 'relpath:../beans'
+  f  beans/black     ../beans/black
+  f  beans/borlotti  ../beans/borlotti
+  f  beans/kidney    ../beans/kidney
+  f  beans/navy      ../beans/navy
+  f  beans/pinto     ../beans/pinto
+  f  beans/turtle    ../beans/turtle
+  $ hg debugwalk .
+  f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
+  f  mammals/skunk                   skunk
+  $ hg debugwalk -I.
+  f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
+  f  mammals/skunk                   skunk
+  $ hg debugwalk Procyonidae
+  f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
+
+  $ cd Procyonidae
+  $ hg debugwalk .
+  f  mammals/Procyonidae/cacomistle  cacomistle
+  f  mammals/Procyonidae/coatimundi  coatimundi
+  f  mammals/Procyonidae/raccoon     raccoon
+  $ hg debugwalk ..
+  f  mammals/Procyonidae/cacomistle  cacomistle
+  f  mammals/Procyonidae/coatimundi  coatimundi
+  f  mammals/Procyonidae/raccoon     raccoon
+  f  mammals/skunk                   ../skunk
+  $ cd ..
+
+  $ hg debugwalk ../beans
+  f  beans/black     ../beans/black
+  f  beans/borlotti  ../beans/borlotti
+  f  beans/kidney    ../beans/kidney
+  f  beans/navy      ../beans/navy
+  f  beans/pinto     ../beans/pinto
+  f  beans/turtle    ../beans/turtle
+  $ hg debugwalk .
+  f  mammals/Procyonidae/cacomistle  Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     Procyonidae/raccoon
+  f  mammals/skunk                   skunk
+  $ hg debugwalk .hg
+  abort: path 'mammals/.hg' is inside repo 'mammals'
+  $ hg debugwalk ../.hg
+  abort: path contains illegal component: .hg
+  $ cd ..
+
+  $ hg debugwalk -Ibeans
+  f  beans/black     beans/black
+  f  beans/borlotti  beans/borlotti
+  f  beans/kidney    beans/kidney
+  f  beans/navy      beans/navy
+  f  beans/pinto     beans/pinto
+  f  beans/turtle    beans/turtle
+  $ hg debugwalk -I '{*,{b,m}*/*}k'
+  f  beans/black    beans/black
+  f  fenugreek      fenugreek
+  f  mammals/skunk  mammals/skunk
+  $ hg debugwalk 'glob:mammals/../beans/b*'
+  f  beans/black     beans/black
+  f  beans/borlotti  beans/borlotti
+  $ hg debugwalk '-X*/Procyonidae' mammals
+  f  mammals/skunk  mammals/skunk
+  $ hg debugwalk path:mammals
+  f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
+  f  mammals/skunk                   mammals/skunk
+  $ hg debugwalk ..
+  abort: .. not under root
+  $ hg debugwalk beans/../..
+  abort: beans/../.. not under root
+  $ hg debugwalk .hg
+  abort: path contains illegal component: .hg
+  $ hg debugwalk beans/../.hg
+  abort: path contains illegal component: .hg
+  $ hg debugwalk beans/../.hg/data
+  abort: path contains illegal component: .hg/data
+  $ hg debugwalk beans/.hg
+  abort: path 'beans/.hg' is inside repo 'beans'
+
+Don't know how to test absolute paths without always getting a false
+error.
+# hg debugwalk `pwd`/beans
+# hg debugwalk `pwd`/..
+
+  $ hg debugwalk glob:\*
+  f  fennel      fennel
+  f  fenugreek   fenugreek
+  f  fiddlehead  fiddlehead
+  f  glob:glob   glob:glob
+  $ hg debugwalk 'glob:**e'
+  f  beans/turtle                    beans/turtle
+  f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
+  $ hg debugwalk 're:.*[kb]$'
+  f  beans/black    beans/black
+  f  fenugreek      fenugreek
+  f  glob:glob      glob:glob
+  f  mammals/skunk  mammals/skunk
+  $ hg debugwalk path:beans/black
+  f  beans/black  beans/black  exact
+  $ hg debugwalk path:beans//black
+  f  beans/black  beans/black  exact
+  $ hg debugwalk relglob:Procyonidae
+  $ hg debugwalk 'relglob:Procyonidae/**'
+  f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
+  $ hg debugwalk 'relglob:Procyonidae/**' fennel
+  f  fennel                          fennel                          exact
+  f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
+  $ hg debugwalk beans 'glob:beans/*'
+  f  beans/black     beans/black
+  f  beans/borlotti  beans/borlotti
+  f  beans/kidney    beans/kidney
+  f  beans/navy      beans/navy
+  f  beans/pinto     beans/pinto
+  f  beans/turtle    beans/turtle
+  $ hg debugwalk 'glob:mamm**'
+  f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
+  f  mammals/skunk                   mammals/skunk
+  $ hg debugwalk 'glob:mamm**' fennel
+  f  fennel                          fennel                          exact
+  f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
+  f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
+  f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
+  f  mammals/skunk                   mammals/skunk
+  $ hg debugwalk 'glob:j*'
+  $ hg debugwalk NOEXIST
+  NOEXIST: No such file or directory
+
+  $ mkfifo fifo
+  $ hg debugwalk fifo
+  fifo: unsupported file type (type is fifo)
+
+  $ rm fenugreek
+  $ hg debugwalk fenugreek
+  f  fenugreek  fenugreek  exact
+  $ hg rm fenugreek
+  $ hg debugwalk fenugreek
+  f  fenugreek  fenugreek  exact
+  $ touch new
+  $ hg debugwalk new
+  f  new  new  exact
+
+  $ mkdir ignored
+  $ touch ignored/file
+  $ echo '^ignored$' > .hgignore
+  $ hg debugwalk ignored
+  $ hg debugwalk ignored/file
+  f  ignored/file  ignored/file  exact
+
+  $ cd ..
+  $ hg debugwalk -R t t/mammals/skunk
+  f  mammals/skunk  t/mammals/skunk  exact
+  $ mkdir t2
+  $ cd t2
+  $ hg debugwalk -R ../t ../t/mammals/skunk
+  f  mammals/skunk  ../t/mammals/skunk  exact
+  $ hg debugwalk --cwd ../t mammals/skunk
+  f  mammals/skunk  mammals/skunk  exact
--- a/tests/test-webraw	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,23 +0,0 @@
-#!/bin/sh
-
-hg init test
-cd test
-mkdir sub
-cat >'sub/some "text".txt' <<ENDSOME
-This is just some random text
-that will go inside the file and take a few lines.
-It is very boring to read, but computers don't
-care about things like that.
-ENDSOME
-hg add 'sub/some "text".txt'
-hg commit -d "1 0" -m "Just some text"
-hg serve -p $HGPORT -A access.log -E error.log -d --pid-file=hg.pid
-cat hg.pid >> $DAEMON_PIDS
-("$TESTDIR/get-with-headers.py" localhost:$HGPORT '/?f=a23bf1310f6e;file=sub/some%20%22text%22.txt;style=raw' content-type content-length content-disposition) >getoutput.txt &
-
-sleep 5
-kill `cat hg.pid`
-sleep 1 # wait for server to scream and die
-cat getoutput.txt
-cat access.log error.log | \
-  sed 's/^[^ ]*\( [^[]*\[\)[^]]*\(\].*\)$/host\1date\2/'
--- a/tests/test-webraw.out	Sat Aug 14 01:31:57 2010 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,10 +0,0 @@
-200 Script output follows
-content-type: text/plain; charset="ascii"
-content-length: 157
-content-disposition: inline; filename="some \"text\".txt"
-
-This is just some random text
-that will go inside the file and take a few lines.
-It is very boring to read, but computers don't
-care about things like that.
-host - - [date] "GET /?f=a23bf1310f6e;file=sub/some%20%22text%22.txt;style=raw HTTP/1.1" 200 -