Show More
@@ -39,7 +39,7 b' class bundlerevlog(revlog.revlog):' | |||
|
39 | 39 | for chunk, start in chunkpositer(): |
|
40 | 40 | size = len(chunk) |
|
41 | 41 | if size < 80: |
|
42 | raise util.Abort("invalid changegroup") | |
|
42 | raise util.Abort(_("invalid changegroup")) | |
|
43 | 43 | start += 80 |
|
44 | 44 | size -= 80 |
|
45 | 45 | node, p1, p2, cs = struct.unpack("20s20s20s20s", chunk[:80]) |
@@ -936,7 +936,7 b' def finddate(ui, repo, date):' | |||
|
936 | 936 | results[rev] = d |
|
937 | 937 | elif st == 'iter': |
|
938 | 938 | if rev in results: |
|
939 | ui.status("Found revision %s from %s\n" % | |
|
939 | ui.status(_("Found revision %s from %s\n") % | |
|
940 | 940 | (rev, util.datestr(results[rev]))) |
|
941 | 941 | return str(rev) |
|
942 | 942 |
@@ -2129,7 +2129,7 b' def push(ui, repo, dest=None, **opts):' | |||
|
2129 | 2129 | cmdutil.setremoteconfig(ui, opts) |
|
2130 | 2130 | |
|
2131 | 2131 | other = hg.repository(ui, dest) |
|
2132 | ui.status('pushing to %s\n' % util.hidepassword(dest)) | |
|
2132 | ui.status(_('pushing to %s\n') % util.hidepassword(dest)) | |
|
2133 | 2133 | if revs: |
|
2134 | 2134 | revs = [repo.lookup(rev) for rev in revs] |
|
2135 | 2135 | r = repo.push(other, opts['force'], revs=revs) |
@@ -259,7 +259,7 b' def create_server(ui, repo):' | |||
|
259 | 259 | from OpenSSL import SSL |
|
260 | 260 | ctx = SSL.Context(SSL.SSLv23_METHOD) |
|
261 | 261 | except ImportError: |
|
262 | raise util.Abort("SSL support is unavailable") | |
|
262 | raise util.Abort(_("SSL support is unavailable")) | |
|
263 | 263 | ctx.use_privatekey_file(ssl_cert) |
|
264 | 264 | ctx.use_certificate_file(ssl_cert) |
|
265 | 265 | sock = socket.socket(self.address_family, self.socket_type) |
@@ -1098,7 +1098,7 b' class localrepository(repo.repository):' | |||
|
1098 | 1098 | wlock = self.wlock() |
|
1099 | 1099 | for f in list: |
|
1100 | 1100 | if self.dirstate[f] != 'r': |
|
1101 | self.ui.warn("%s not removed!\n" % f) | |
|
1101 | self.ui.warn(_("%s not removed!\n") % f) | |
|
1102 | 1102 | else: |
|
1103 | 1103 | m = f in manifests[0] and manifests[0] or manifests[1] |
|
1104 | 1104 | t = self.file(f).read(m[f]) |
@@ -2022,7 +2022,7 b' class localrepository(repo.repository):' | |||
|
2022 | 2022 | except ValueError, TypeError: |
|
2023 | 2023 | raise util.UnexpectedOutput( |
|
2024 | 2024 | _('Unexpected response from remote server:'), l) |
|
2025 | self.ui.debug('adding %s (%s)\n' % (name, util.bytecount(size))) | |
|
2025 | self.ui.debug(_('adding %s (%s)\n') % (name, util.bytecount(size))) | |
|
2026 | 2026 | ofp = self.sopener(name, 'w') |
|
2027 | 2027 | for chunk in util.filechunkiter(fp, limit=size): |
|
2028 | 2028 | ofp.write(chunk) |
@@ -347,7 +347,7 b' def applyupdates(repo, action, wctx, mct' | |||
|
347 | 347 | updated += 1 |
|
348 | 348 | elif m == "dr": # divergent renames |
|
349 | 349 | fl = a[2] |
|
350 | repo.ui.warn("warning: detected divergent renames of %s to:\n" % f) | |
|
350 | repo.ui.warn(_("warning: detected divergent renames of %s to:\n") % f) | |
|
351 | 351 | for nf in fl: |
|
352 | 352 | repo.ui.warn(" %s\n" % nf) |
|
353 | 353 | elif m == "e": # exec |
@@ -229,7 +229,7 b' def patch(patchname, ui, strip=1, cwd=No' | |||
|
229 | 229 | return internalpatch(patchname, ui, strip, cwd, files) |
|
230 | 230 | except NoHunks: |
|
231 | 231 | patcher = util.find_exe('gpatch') or util.find_exe('patch') |
|
232 | ui.debug('no valid hunks found; trying with %r instead\n' % | |
|
232 | ui.debug(_('no valid hunks found; trying with %r instead\n') % | |
|
233 | 233 | patcher) |
|
234 | 234 | if util.needbinarypatch(): |
|
235 | 235 | args.append('--binary') |
@@ -8,6 +8,7 b'' | |||
|
8 | 8 | |
|
9 | 9 | import changegroup, os |
|
10 | 10 | from node import nullrev, short |
|
11 | from i18n import _ | |
|
11 | 12 | |
|
12 | 13 | def _bundle(repo, bases, heads, node, suffix, extranodes=None): |
|
13 | 14 | """create a bundle with the specified revisions as a backup""" |
@@ -16,7 +17,7 b' def _bundle(repo, bases, heads, node, su' | |||
|
16 | 17 | if not os.path.isdir(backupdir): |
|
17 | 18 | os.mkdir(backupdir) |
|
18 | 19 | name = os.path.join(backupdir, "%s-%s" % (short(node), suffix)) |
|
19 | repo.ui.warn("saving bundle to %s\n" % name) | |
|
20 | repo.ui.warn(_("saving bundle to %s\n") % name) | |
|
20 | 21 | return changegroup.writebundle(cg, name, "HG10BZ") |
|
21 | 22 | |
|
22 | 23 | def _collectfiles(repo, striprev): |
@@ -125,7 +126,7 b' def strip(ui, repo, node, backup="all"):' | |||
|
125 | 126 | f.strip(striprev) |
|
126 | 127 | |
|
127 | 128 | if saveheads or extranodes: |
|
128 | ui.status("adding branch\n") | |
|
129 | ui.status(_("adding branch\n")) | |
|
129 | 130 | f = open(chgrpfile, "rb") |
|
130 | 131 | gen = changegroup.readbundle(f, chgrpfile) |
|
131 | 132 | repo.addchangegroup(gen, 'strip', 'bundle:' + chgrpfile, True) |
@@ -42,7 +42,7 b' class sshrepository(repo.repository):' | |||
|
42 | 42 | cmd = '%s %s "%s init %s"' |
|
43 | 43 | cmd = cmd % (sshcmd, args, remotecmd, self.path) |
|
44 | 44 | |
|
45 | ui.note('running %s\n' % cmd) | |
|
45 | ui.note(_('running %s\n') % cmd) | |
|
46 | 46 | res = util.system(cmd) |
|
47 | 47 | if res != 0: |
|
48 | 48 | self.raise_(repo.RepoError(_("could not create remote repo"))) |
@@ -60,7 +60,7 b' class sshrepository(repo.repository):' | |||
|
60 | 60 | cmd = cmd % (sshcmd, args, remotecmd, self.path) |
|
61 | 61 | |
|
62 | 62 | cmd = util.quotecommand(cmd) |
|
63 | ui.note('running %s\n' % cmd) | |
|
63 | ui.note(_('running %s\n') % cmd) | |
|
64 | 64 | self.pipeo, self.pipei, self.pipee = os.popen3(cmd, 'b') |
|
65 | 65 | |
|
66 | 66 | # skip any noise generated by remote shell |
@@ -6,6 +6,7 b'' | |||
|
6 | 6 | # of the GNU General Public License, incorporated herein by reference. |
|
7 | 7 | |
|
8 | 8 | import util, lock |
|
9 | from i18n import _ | |
|
9 | 10 | |
|
10 | 11 | class StreamException(Exception): |
|
11 | 12 | def __init__(self, code): |
@@ -42,7 +43,7 b' def stream_out(repo, untrusted=False):' | |||
|
42 | 43 | try: |
|
43 | 44 | l = None |
|
44 | 45 | try: |
|
45 | repo.ui.debug('scanning\n') | |
|
46 | repo.ui.debug(_('scanning\n')) | |
|
46 | 47 | # get consistent snapshot of repo, lock during scan |
|
47 | 48 | l = repo.lock() |
|
48 | 49 | for name, ename, size in repo.store.walk(): |
@@ -54,11 +55,11 b' def stream_out(repo, untrusted=False):' | |||
|
54 | 55 | raise StreamException(2) |
|
55 | 56 | |
|
56 | 57 | yield '0\n' |
|
57 | repo.ui.debug('%d files, %d bytes to transfer\n' % | |
|
58 | repo.ui.debug(_('%d files, %d bytes to transfer\n') % | |
|
58 | 59 | (len(entries), total_bytes)) |
|
59 | 60 | yield '%d %d\n' % (len(entries), total_bytes) |
|
60 | 61 | for name, size in entries: |
|
61 | repo.ui.debug('sending %s (%d bytes)\n' % (name, size)) | |
|
62 | repo.ui.debug(_('sending %s (%d bytes)\n') % (name, size)) | |
|
62 | 63 | yield '%s\0%d\n' % (name, size) |
|
63 | 64 | for chunk in util.filechunkiter(repo.sopener(name), limit=size): |
|
64 | 65 | yield chunk |
General Comments 0
You need to be logged in to leave comments.
Login now