Mercurial > public > mercurial-scm > hg-stable
diff hgext/transplant.py @ 14260:00a881581400
patch: make patch()/internalpatch() always update the dirstate
author | Patrick Mezard <pmezard@gmail.com> |
---|---|
date | Sun, 08 May 2011 17:48:31 +0200 |
parents | df9ccd39828c |
children | e7ea3e38fea8 |
line wrap: on
line diff
--- a/hgext/transplant.py Sun May 08 17:48:30 2011 +0200 +++ b/hgext/transplant.py Sun May 08 17:48:31 2011 +0200 @@ -224,15 +224,12 @@ if patchfile: try: files = {} - try: - patch.patch(patchfile, self.ui, cwd=repo.root, - files=files, eolmode=None) - if not files: - self.ui.warn(_('%s: empty changeset') - % revlog.hex(node)) - return None - finally: - files = patch.updatedir(self.ui, repo, files) + patch.patch(self.ui, repo, patchfile, cwd=repo.root, + files=files, eolmode=None) + files = list(files) + if not files: + self.ui.warn(_('%s: empty changeset') % revlog.hex(node)) + return None except Exception, inst: seriespath = os.path.join(self.path, 'series') if os.path.exists(seriespath):