##// END OF EJS Templates
upgrade: issue a message when a revlog type has to be upgraded...
marmoute -
r49276:8405c1bf default
parent child Browse files
Show More
@@ -92,7 +92,8 b' def upgraderepo('
92 92
93 93 touched_revlogs = set()
94 94 overwrite_msg = _(b'warning: ignoring %14s, as upgrade is changing: %s\n')
95 msg_issued = False
95 select_msg = _(b'note: selecting %s for processing to change: %s\n')
96 msg_issued = 0
96 97
97 98 FL = upgrade_engine.UPGRADE_FILELOGS
98 99 MN = upgrade_engine.UPGRADE_MANIFEST
@@ -108,24 +109,43 b' def upgraderepo('
108 109 if not specified_revlogs[FL]:
109 110 msg = overwrite_msg % (b'--no-filelogs', action.name)
110 111 ui.warn(msg)
111 msg_issued = True
112 msg_issued = 2
113 else:
114 msg = select_msg % (b'all-filelogs', action.name)
115 ui.status(msg)
116 if not ui.quiet:
117 msg_issued = 1
112 118 touched_revlogs.add(FL)
119
113 120 if action.touches_manifests and MN not in touched_revlogs:
114 121 if MN in specified_revlogs:
115 122 if not specified_revlogs[MN]:
116 123 msg = overwrite_msg % (b'--no-manifest', action.name)
117 124 ui.warn(msg)
118 msg_issued = True
125 msg_issued = 2
126 else:
127 msg = select_msg % (b'all-manifestlogs', action.name)
128 ui.status(msg)
129 if not ui.quiet:
130 msg_issued = 1
119 131 touched_revlogs.add(MN)
132
120 133 if action.touches_changelog and CL not in touched_revlogs:
121 134 if CL in specified_revlogs:
122 135 if not specified_revlogs[CL]:
123 136 msg = overwrite_msg % (b'--no-changelog', action.name)
124 137 ui.warn(msg)
125 138 msg_issued = True
139 else:
140 msg = select_msg % (b'changelog', action.name)
141 ui.status(msg)
142 if not ui.quiet:
143 msg_issued = 1
126 144 touched_revlogs.add(CL)
127 if msg_issued:
145 if msg_issued >= 2:
128 146 ui.warn((b"\n"))
147 elif msg_issued >= 1:
148 ui.status((b"\n"))
129 149
130 150 revlogs = set(upgrade_engine.UPGRADE_ALL_REVLOGS)
131 151 if specified_revlogs:
@@ -401,6 +401,10 b' Various sub-optimal detections work'
401 401 [formatvariant.name.mismatchdefault|compression: ][formatvariant.repo.mismatchdefault| zlib][formatvariant.config.special| zlib][formatvariant.default| zstd] (zstd !)
402 402 [formatvariant.name.uptodate|compression-level: ][formatvariant.repo.uptodate| default][formatvariant.config.default| default][formatvariant.default| default]
403 403 $ hg debugupgraderepo
404 note: selecting all-filelogs for processing to change: dotencode
405 note: selecting all-manifestlogs for processing to change: dotencode
406 note: selecting changelog for processing to change: dotencode
407
404 408 repository lacks features recommended by current config options:
405 409
406 410 fncache
@@ -473,6 +477,10 b' Various sub-optimal detections work'
473 477
474 478
475 479 $ hg --config format.dotencode=false debugupgraderepo
480 note: selecting all-filelogs for processing to change: fncache
481 note: selecting all-manifestlogs for processing to change: fncache
482 note: selecting changelog for processing to change: fncache
483
476 484 repository lacks features recommended by current config options:
477 485
478 486 fncache
@@ -567,6 +575,10 b' make sure we have a .d file'
567 575 .hg/store/data/f2.i
568 576
569 577 $ hg debugupgraderepo --run --config format.sparse-revlog=false
578 note: selecting all-filelogs for processing to change: generaldelta
579 note: selecting all-manifestlogs for processing to change: generaldelta
580 note: selecting changelog for processing to change: generaldelta
581
570 582 upgrade will perform the following actions:
571 583
572 584 requirements
@@ -671,6 +683,10 b' unless --no-backup is passed'
671 683
672 684 $ rm -rf .hg/upgradebackup.*/
673 685 $ hg debugupgraderepo --run --no-backup
686 note: selecting all-filelogs for processing to change: sparserevlog
687 note: selecting all-manifestlogs for processing to change: sparserevlog
688 note: selecting changelog for processing to change: sparserevlog
689
674 690 upgrade will perform the following actions:
675 691
676 692 requirements
@@ -961,6 +977,9 b" Check you can't skip revlog clone during"
961 977 - manifest
962 978
963 979 $ hg debugupgrade --optimize re-delta-parent --run --manifest --no-backup --debug --traceback
980 note: selecting all-filelogs for processing to change: sparserevlog
981 note: selecting changelog for processing to change: sparserevlog
982
964 983 ignoring revlogs selection flags, format requirements change: sparserevlog
965 984 upgrade will perform the following actions:
966 985
@@ -1016,6 +1035,9 b" Check you can't skip revlog clone during"
1016 1035
1017 1036 $ echo "sparse-revlog=yes" >> .hg/hgrc
1018 1037 $ hg debugupgrade --optimize re-delta-parent --run --manifest --no-backup --debug --traceback
1038 note: selecting all-filelogs for processing to change: sparserevlog
1039 note: selecting changelog for processing to change: sparserevlog
1040
1019 1041 ignoring revlogs selection flags, format requirements change: sparserevlog
1020 1042 upgrade will perform the following actions:
1021 1043
General Comments 0
You need to be logged in to leave comments. Login now