D11152: sparse: use `update_file` instead of `normal` in `refreshwdir`

marmoute (Pierre-Yves David) phabricator at mercurial-scm.org
Mon Jul 19 10:44:09 UTC 2021


marmoute created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.

REVISION SUMMARY
  This is the newer, more semantic API.

REPOSITORY
  rHG Mercurial

BRANCH
  default

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

AFFECTED FILES
  mercurial/sparse.py

CHANGE DETAILS

diff --git a/mercurial/sparse.py b/mercurial/sparse.py
--- a/mercurial/sparse.py
+++ b/mercurial/sparse.py
@@ -565,7 +565,7 @@
 
     # Fix dirstate
     for file in added:
-        dirstate.normal(file)
+        dirstate.update_file(file, p1_tracked=True, wc_tracked=True)
 
     for file in dropped:
         dirstate.drop(file)



To: marmoute, #hg-reviewers
Cc: mercurial-patches, mercurial-devel


More information about the Mercurial-devel mailing list