# HG changeset patch # User Pierre-Yves David # Date 2021-06-22 09:09:25 # Node ID bc8536e09a20dab065e30640f0b3f00558b10dfd # Parent 5fa083a5ff0429016bb7e035f9c7bbee6c777c95 revlog: rewrite `censors.py` to `rewrite.py` The logic we use for censoring revision will be mostly common with the one we needs for stripping. So we rename the module to `rewrite` to better match its future content. Differential Revision: https://phab.mercurial-scm.org/D10896 diff --git a/mercurial/revlog.py b/mercurial/revlog.py --- a/mercurial/revlog.py +++ b/mercurial/revlog.py @@ -81,13 +81,13 @@ from .interfaces import ( util as interfaceutil, ) from .revlogutils import ( - censor, deltas as deltautil, docket as docketutil, flagutil, nodemap as nodemaputil, randomaccessfile, revlogv0, + rewrite, sidedata as sidedatautil, ) from .utils import ( @@ -3075,9 +3075,9 @@ class revlog(object): % self._format_version ) elif self._format_version == REVLOGV1: - censor.v1_censor(self, tr, censornode, tombstone) + rewrite.v1_censor(self, tr, censornode, tombstone) else: - censor.v2_censor(self, tr, censornode, tombstone) + rewrite.v2_censor(self, tr, censornode, tombstone) def verifyintegrity(self, state): """Verifies the integrity of the revlog. diff --git a/mercurial/revlogutils/censor.py b/mercurial/revlogutils/rewrite.py rename from mercurial/revlogutils/censor.py rename to mercurial/revlogutils/rewrite.py