Mathiasdm created this revision. Herald added a reviewer: hg-reviewers. Herald added a subscriber: mercurial-patches.
REVISION SUMMARY This makes it possible to start using soft strip on an existing repository, if the following is set in the configuration: [format] internal-phase=yes REPOSITORY rHG Mercurial BRANCH default REVISION DETAIL https://phab.mercurial-scm.org/D10915 AFFECTED FILES mercurial/upgrade_utils/actions.py CHANGE DETAILS diff --git a/mercurial/upgrade_utils/actions.py b/mercurial/upgrade_utils/actions.py --- a/mercurial/upgrade_utils/actions.py +++ b/mercurial/upgrade_utils/actions.py @@ -235,6 +235,27 @@ b'faster' ) +@registerformatvariant +class internalphases(requirementformatvariant): + name = b'internalphases' + + _requirement = requirements.INTERNAL_PHASE_REQUIREMENT + + default = False + description = _( + b'older repositories do not support ' + b'internal phases, which makes it impossible to ' + b'use features like "soft strip"' + ) + upgrademessage = _( + b'repository will be able to use internal phases, ' + b'making features like "soft strip" possible' + ) + + touches_filelogs = False + touches_manifests = False + touches_changelog = False + touches_requirements = True @registerformatvariant class sharesafe(requirementformatvariant): @@ -979,6 +1000,7 @@ requirements.REVLOGV2_REQUIREMENT, requirements.CHANGELOGV2_REQUIREMENT, requirements.DIRSTATE_V2_REQUIREMENT, + requirements.INTERNAL_PHASE_REQUIREMENT, } for name in compression.compengines: engine = compression.compengines[name] @@ -1011,6 +1033,7 @@ requirements.REVLOGV2_REQUIREMENT, requirements.CHANGELOGV2_REQUIREMENT, requirements.DIRSTATE_V2_REQUIREMENT, + requirements.INTERNAL_PHASE_REQUIREMENT, } for name in compression.compengines: engine = compression.compengines[name] To: Mathiasdm, #hg-reviewers Cc: mercurial-patches, mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel