changeset 10941:2067532d95e7

Merge with stable
author Martin Geisler <mg@lazybytes.net>
date Mon, 19 Apr 2010 20:49:09 +0200
parents a9d5943d2a30 (current diff) 898d68468df2 (diff)
children 15aaa3637f19
files tests/test-convert.out
diffstat 12 files changed, 48 insertions(+), 38 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/convert/bzr.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/bzr.py	Mon Apr 19 20:49:09 2010 +0200
@@ -37,13 +37,14 @@
         super(bzr_source, self).__init__(ui, path, rev=rev)
 
         if not os.path.exists(os.path.join(path, '.bzr')):
-            raise NoRepo('%s does not look like a Bazaar repo' % path)
+            raise NoRepo(_('%s does not look like a Bazaar repository')
+                         % path)
 
         try:
             # access bzrlib stuff
             branch
         except NameError:
-            raise NoRepo('Bazaar modules could not be loaded')
+            raise NoRepo(_('Bazaar modules could not be loaded'))
 
         path = os.path.abspath(path)
         self._checkrepotype(path)
--- a/hgext/convert/cvs.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/cvs.py	Mon Apr 19 20:49:09 2010 +0200
@@ -19,7 +19,7 @@
 
         cvs = os.path.join(path, "CVS")
         if not os.path.exists(cvs):
-            raise NoRepo("%s does not look like a CVS checkout" % path)
+            raise NoRepo(_("%s does not look like a CVS checkout") % path)
 
         checktool('cvs')
 
--- a/hgext/convert/cvsps.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/cvsps.py	Mon Apr 19 20:49:09 2010 +0200
@@ -129,7 +129,7 @@
             if prefix == ".":
                 prefix = ""
         except IOError:
-            raise logerror('Not a CVS sandbox')
+            raise logerror(_('not a CVS sandbox'))
 
         if prefix and not prefix.endswith(os.sep):
             prefix += os.sep
@@ -435,8 +435,8 @@
             log.sort(key=lambda x: x.date)
 
             if oldlog and oldlog[-1].date >= log[0].date:
-                raise logerror('Log cache overlaps with new log entries,'
-                               ' re-run without cache.')
+                raise logerror(_('log cache overlaps with new log entries,'
+                                 ' re-run without cache.'))
 
             log = oldlog + log
 
--- a/hgext/convert/darcs.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/darcs.py	Mon Apr 19 20:49:09 2010 +0200
@@ -34,10 +34,10 @@
         # check for _darcs, ElementTree, _darcs/inventory so that we can
         # easily skip test-convert-darcs if ElementTree is not around
         if not os.path.exists(os.path.join(path, '_darcs', 'inventories')):
-            raise NoRepo("%s does not look like a darcs repo" % path)
+            raise NoRepo(_("%s does not look like a darcs repository") % path)
 
         if not os.path.exists(os.path.join(path, '_darcs')):
-            raise NoRepo("%s does not look like a darcs repo" % path)
+            raise NoRepo(_("%s does not look like a darcs repository") % path)
 
         checktool('darcs')
         version = self.run0('--version').splitlines()[0].strip()
--- a/hgext/convert/git.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/git.py	Mon Apr 19 20:49:09 2010 +0200
@@ -7,6 +7,7 @@
 
 import os
 from mercurial import util
+from mercurial.i18n import _
 
 from common import NoRepo, commit, converter_source, checktool
 
@@ -35,7 +36,7 @@
         if os.path.isdir(path + "/.git"):
             path += "/.git"
         if not os.path.exists(path + "/objects"):
-            raise NoRepo("%s does not look like a Git repo" % path)
+            raise NoRepo(_("%s does not look like a Git repository") % path)
 
         checktool('git', 'git')
 
--- a/hgext/convert/gnuarch.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/gnuarch.py	Mon Apr 19 20:49:09 2010 +0200
@@ -31,7 +31,8 @@
         super(gnuarch_source, self).__init__(ui, path, rev=rev)
 
         if not os.path.exists(os.path.join(path, '{arch}')):
-            raise NoRepo(_("%s does not look like a GNU Arch repo") % path)
+            raise NoRepo(_("%s does not look like a GNU Arch repository")
+                         % path)
 
         # Could use checktool, but we want to check for baz or tla.
         self.execmd = None
--- a/hgext/convert/hg.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/hg.py	Mon Apr 19 20:49:09 2010 +0200
@@ -36,7 +36,8 @@
             try:
                 self.repo = hg.repository(self.ui, path)
                 if not self.repo.local():
-                    raise NoRepo(_('%s is not a local Mercurial repo') % path)
+                    raise NoRepo(_('%s is not a local Mercurial repository')
+                                 % path)
             except error.RepoError, err:
                 ui.traceback()
                 raise NoRepo(err.args[0])
@@ -45,11 +46,13 @@
                 ui.status(_('initializing destination %s repository\n') % path)
                 self.repo = hg.repository(self.ui, path, create=True)
                 if not self.repo.local():
-                    raise NoRepo(_('%s is not a local Mercurial repo') % path)
+                    raise NoRepo(_('%s is not a local Mercurial repository')
+                                 % path)
                 self.created.append(path)
             except error.RepoError:
                 ui.traceback()
-                raise NoRepo("could not create hg repo %s as sink" % path)
+                raise NoRepo(_("could not create hg repository %s as sink")
+                             % path)
         self.lock = None
         self.wlock = None
         self.filemapmode = False
@@ -224,7 +227,7 @@
                 raise error.RepoError()
         except error.RepoError:
             ui.traceback()
-            raise NoRepo("%s is not a local Mercurial repo" % path)
+            raise NoRepo(_("%s is not a local Mercurial repository") % path)
         self.lastrev = None
         self.lastctx = None
         self._changescache = None
--- a/hgext/convert/monotone.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/monotone.py	Mon Apr 19 20:49:09 2010 +0200
@@ -20,7 +20,8 @@
         self.ui = ui
         self.path = path
 
-        norepo = NoRepo (_("%s does not look like a monotone repo") % path)
+        norepo = NoRepo(_("%s does not look like a monotone repository")
+                        % path)
         if not os.path.exists(os.path.join(path, '_MTN')):
             # Could be a monotone repository (SQLite db file)
             try:
--- a/hgext/convert/p4.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/p4.py	Mon Apr 19 20:49:09 2010 +0200
@@ -28,7 +28,7 @@
         super(p4_source, self).__init__(ui, path, rev=rev)
 
         if "/" in path and not path.startswith('//'):
-            raise NoRepo('%s does not look like a P4 repo' % path)
+            raise NoRepo(_('%s does not look like a P4 repository') % path)
 
         checktool('p4', abort=False)
 
--- a/hgext/convert/subversion.py	Sun Apr 18 15:47:49 2010 +0200
+++ b/hgext/convert/subversion.py	Mon Apr 19 20:49:09 2010 +0200
@@ -207,7 +207,8 @@
                 (os.path.exists(url) and
                  os.path.exists(os.path.join(url, '.svn'))) or
                 issvnurl(ui, url)):
-            raise NoRepo("%s does not look like a Subversion repo" % url)
+            raise NoRepo(_("%s does not look like a Subversion repository")
+                         % url)
 
         try:
             SubversionException
@@ -252,7 +253,8 @@
             self.uuid = svn.ra.get_uuid(self.ra)
         except SubversionException:
             ui.traceback()
-            raise NoRepo("%s does not look like a Subversion repo" % self.url)
+            raise NoRepo(_("%s does not look like a Subversion repository")
+                         % self.url)
 
         if rev:
             try:
@@ -984,7 +986,7 @@
 
             if os.path.isdir(os.path.dirname(path)):
                 if not os.path.exists(os.path.join(path, 'db', 'fs-type')):
-                    ui.status(_('initializing svn repo %r\n') %
+                    ui.status(_('initializing svn repository %r\n') %
                               os.path.basename(path))
                     commandline(ui, 'svnadmin').run0('create', path)
                     created = path
@@ -993,7 +995,8 @@
                     path = '/' + path
                 path = 'file://' + path
 
-            ui.status(_('initializing svn wc %r\n') % os.path.basename(wcpath))
+            ui.status(_('initializing svn working copy %r\n')
+                      % os.path.basename(wcpath))
             self.run0('checkout', path, wcpath)
 
             self.wc = wcpath
--- a/tests/test-convert-svn-sink.out	Sun Apr 18 15:47:49 2010 +0200
+++ b/tests/test-convert-svn-sink.out	Mon Apr 19 20:49:09 2010 +0200
@@ -4,8 +4,8 @@
 % modify
 1:e0e2b8a9156b
 assuming destination a-hg
-initializing svn repo 'a-hg'
-initializing svn wc 'a-hg-wc'
+initializing svn repository 'a-hg'
+initializing svn working copy 'a-hg-wc'
 scanning source...
 sorting...
 converting...
@@ -57,7 +57,7 @@
 % rename
 2:eb5169441d43
 assuming destination a-hg
-initializing svn wc 'a-hg-wc'
+initializing svn working copy 'a-hg-wc'
 scanning source...
 sorting...
 converting...
@@ -95,7 +95,7 @@
 % copy
 3:60effef6ab48
 assuming destination a-hg
-initializing svn wc 'a-hg-wc'
+initializing svn working copy 'a-hg-wc'
 scanning source...
 sorting...
 converting...
@@ -134,7 +134,7 @@
 % remove
 4:87bbe3013fb6
 assuming destination a-hg
-initializing svn wc 'a-hg-wc'
+initializing svn working copy 'a-hg-wc'
 scanning source...
 sorting...
 converting...
@@ -168,7 +168,7 @@
 % executable
 5:ff42e473c340
 assuming destination a-hg
-initializing svn wc 'a-hg-wc'
+initializing svn working copy 'a-hg-wc'
 scanning source...
 sorting...
 converting...
@@ -196,8 +196,8 @@
 % executable in new directory
 adding d1/a
 assuming destination a-hg
-initializing svn repo 'a-hg'
-initializing svn wc 'a-hg-wc'
+initializing svn repository 'a-hg'
+initializing svn working copy 'a-hg-wc'
 scanning source...
 sorting...
 converting...
@@ -224,7 +224,7 @@
 executable
 % copy to new directory
 assuming destination a-hg
-initializing svn wc 'a-hg-wc'
+initializing svn working copy 'a-hg-wc'
 scanning source...
 sorting...
 converting...
@@ -267,8 +267,8 @@
 2 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
 assuming destination b-hg
-initializing svn repo 'b-hg'
-initializing svn wc 'b-hg-wc'
+initializing svn repository 'b-hg'
+initializing svn working copy 'b-hg-wc'
 scanning source...
 sorting...
 converting...
--- a/tests/test-convert.out	Sun Apr 18 15:47:49 2010 +0200
+++ b/tests/test-convert.out	Mon Apr 19 20:49:09 2010 +0200
@@ -270,13 +270,13 @@
 assuming destination emptydir-hg
 initializing destination emptydir-hg repository
 emptydir does not look like a CVS checkout
-emptydir does not look like a Git repo
-emptydir does not look like a Subversion repo
-emptydir is not a local Mercurial repo
-emptydir does not look like a darcs repo
-emptydir does not look like a monotone repo
-emptydir does not look like a GNU Arch repo
-emptydir does not look like a Bazaar repo
+emptydir does not look like a Git repository
+emptydir does not look like a Subversion repository
+emptydir is not a local Mercurial repository
+emptydir does not look like a darcs repository
+emptydir does not look like a monotone repository
+emptydir does not look like a GNU Arch repository
+emptydir does not look like a Bazaar repository
 cannot find required "p4" tool
 abort: emptydir: missing or unsupported repository
 % convert with imaginary source type