D5857: merge: migrate to scmutil.backuppath()

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Wed Feb 6 21:03:59 EST 2019


This revision was automatically updated to reflect the committed changes.
Closed by commit rHG8c8121c3dfcc: merge: migrate to scmutil.backuppath() (authored by martinvonz, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D5857?vs=13862&id=13879

REVISION DETAIL
  https://phab.mercurial-scm.org/D5857

AFFECTED FILES
  mercurial/merge.py

CHANGE DETAILS

diff --git a/mercurial/merge.py b/mercurial/merge.py
--- a/mercurial/merge.py
+++ b/mercurial/merge.py
@@ -1506,9 +1506,8 @@
                             conflicting = p
                             break
                 if repo.wvfs.lexists(conflicting):
-                    absf = repo.wjoin(conflicting)
-                    orig = scmutil.origpath(ui, repo, absf)
-                    util.rename(absf, orig)
+                    orig = scmutil.backuppath(ui, repo, conflicting)
+                    util.rename(repo.wjoin(conflicting), orig)
             wctx[f].clearunknown()
             atomictemp = ui.configbool("experimental", "update.atomic-file")
             wctx[f].write(fctx(f).data(), flags, backgroundclose=True,



To: martinvonz, #hg-reviewers
Cc: mercurial-devel


More information about the Mercurial-devel mailing list