Mercurial > hg
changeset 16828:8abee656e14c
merge with stable
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Fri, 01 Jun 2012 15:14:29 -0500 |
parents | b6ef1395d77f (current diff) 85a358df5bbb (diff) |
children | 6403fdd716fe |
files | mercurial/localrepo.py mercurial/patch.py mercurial/scmutil.py |
diffstat | 5 files changed, 65 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/i18n/pt_BR.po Fri Jun 01 15:13:05 2012 -0500 +++ b/i18n/pt_BR.po Fri Jun 01 15:14:29 2012 -0500 @@ -22581,6 +22581,9 @@ msgid "could not symlink to %r: %s" msgstr "impossível criar link simbólico para %r: %s" +msgid "empty revision range" +msgstr "faixa de revisões vazia" + #, python-format msgid "recording removal of %s as rename to %s (%d%% similar)\n" msgstr "gravando remoção de %s como renomeação para %s (%d%% de similaridade)\n"
--- a/mercurial/localrepo.py Fri Jun 01 15:13:05 2012 -0500 +++ b/mercurial/localrepo.py Fri Jun 01 15:14:29 2012 -0500 @@ -838,6 +838,9 @@ self.sjoin('phaseroots')) self.invalidate() + # Discard all cache entries to force reloading everything. + self._filecache.clear() + parentgone = (parents[0] not in self.changelog.nodemap or parents[1] not in self.changelog.nodemap) if parentgone: @@ -1320,9 +1323,6 @@ # tag cache retrieval" case to work. self.invalidatecaches() - # Discard all cache entries to force reloading everything. - self._filecache.clear() - def walk(self, match, node=None): ''' walk recursively through the directory tree or a given
--- a/mercurial/patch.py Fri Jun 01 15:13:05 2012 -0500 +++ b/mercurial/patch.py Fri Jun 01 15:14:29 2012 -0500 @@ -1345,8 +1345,17 @@ elif state == 'git': for gp in values: path = pstrip(gp.oldpath) - data, mode = backend.getfile(path) - store.setfile(path, data, mode) + try: + data, mode = backend.getfile(path) + except IOError, e: + if e.errno != errno.ENOENT: + raise + # The error ignored here will trigger a getfile() + # error in a place more appropriate for error + # handling, and will not interrupt the patching + # process. + else: + store.setfile(path, data, mode) else: raise util.Abort(_('unsupported parser state: %s') % state)
--- a/mercurial/scmutil.py Fri Jun 01 15:13:05 2012 -0500 +++ b/mercurial/scmutil.py Fri Jun 01 15:14:29 2012 -0500 @@ -569,7 +569,7 @@ newrevs = set(xrange(start, end + step, step)) if seen: newrevs.difference_update(seen) - seen.union(newrevs) + seen.update(newrevs) else: seen = newrevs l.extend(sorted(newrevs, reverse=start > end))
--- a/tests/test-mq-missingfiles.t Fri Jun 01 15:13:05 2012 -0500 +++ b/tests/test-mq-missingfiles.t Fri Jun 01 15:14:29 2012 -0500 @@ -73,6 +73,53 @@ +c +c +Test missing renamed file + + $ hg qpop + popping changeb + patch queue now empty + $ hg up -qC 0 + $ echo a > a + $ hg mv b bb + $ python ../writelines.py bb 2 'b\n' 10 'a\n' 2 'c\n' + $ echo c > c + $ hg add a c + $ hg qnew changebb + $ hg qpop + popping changebb + patch queue now empty + $ hg up -qC 1 + $ hg qpush + applying changebb + patching file bb + Hunk #1 FAILED at 0 + Hunk #2 FAILED at 7 + 2 out of 2 hunks FAILED -- saving rejects to file bb.rej + b not tracked! + patch failed, unable to continue (try -v) + patch failed, rejects left in working dir + errors during apply, please fix and refresh changebb + [2] + $ cat a + a + $ cat c + c + $ cat bb.rej + --- bb + +++ bb + @@ -1,3 +1,5 @@ + +b + +b + a + a + a + @@ -8,3 +10,5 @@ + a + a + a + +c + +c + $ cd ..