Show More
@@ -950,9 +950,6 b' def blocksourcerequirements(repo):' | |||||
950 | requirements in the returned set. |
|
950 | requirements in the returned set. | |
951 | """ |
|
951 | """ | |
952 | return { |
|
952 | return { | |
953 | # The upgrade code does not yet support these experimental features. |
|
|||
954 | # This is an artificial limitation. |
|
|||
955 | requirements.TREEMANIFEST_REQUIREMENT, |
|
|||
956 | # This was a precursor to generaldelta and was never enabled by default. |
|
953 | # This was a precursor to generaldelta and was never enabled by default. | |
957 | # It should (hopefully) not exist in the wild. |
|
954 | # It should (hopefully) not exist in the wild. | |
958 | b'parentdelta', |
|
955 | b'parentdelta', | |
@@ -1052,6 +1049,7 b' def supporteddestrequirements(repo):' | |||||
1052 | requirements.SHARESAFE_REQUIREMENT, |
|
1049 | requirements.SHARESAFE_REQUIREMENT, | |
1053 | requirements.SPARSEREVLOG_REQUIREMENT, |
|
1050 | requirements.SPARSEREVLOG_REQUIREMENT, | |
1054 | requirements.STORE_REQUIREMENT, |
|
1051 | requirements.STORE_REQUIREMENT, | |
|
1052 | requirements.TREEMANIFEST_REQUIREMENT, | |||
1055 | requirements.NARROW_REQUIREMENT, |
|
1053 | requirements.NARROW_REQUIREMENT, | |
1056 | } |
|
1054 | } | |
1057 | for name in compression.compengines: |
|
1055 | for name in compression.compengines: |
@@ -73,14 +73,8 b" Names with '.' in them are OK." | |||||
73 |
|
73 | |||
74 | The "narrow" repo requirement is ignored by [debugupgraderepo] |
|
74 | The "narrow" repo requirement is ignored by [debugupgraderepo] | |
75 |
|
75 | |||
76 | #if tree |
|
|||
77 | $ (cd should-work; hg debugupgraderepo) |
|
|||
78 | abort: cannot upgrade repository; unsupported source requirement: treemanifest |
|
|||
79 | [255] |
|
|||
80 | #else |
|
|||
81 |
$ |
|
76 | $ (cd should-work; hg debugupgraderepo | grep 'no format upgrades found in existing repository') | |
82 | (no format upgrades found in existing repository) |
|
77 | (no format upgrades found in existing repository) | |
83 | #endif |
|
|||
84 |
|
|
78 | ||
85 | Test repo with local changes |
|
79 | Test repo with local changes | |
86 | $ hg clone --narrow ssh://user@dummy/master narrow-local-changes --include d0 --include d3 --include d6 |
|
80 | $ hg clone --narrow ssh://user@dummy/master narrow-local-changes --include d0 --include d3 --include d6 |
@@ -853,3 +853,47 b' Committing a empty commit does not dupli' | |||||
853 | 1:678d3574b88c |
|
853 | 1:678d3574b88c | |
854 | 1:678d3574b88c |
|
854 | 1:678d3574b88c | |
855 | $ hg --config extensions.strip= strip -r . -q |
|
855 | $ hg --config extensions.strip= strip -r . -q | |
|
856 | ||||
|
857 | Testing repository upgrade | |||
|
858 | -------------------------- | |||
|
859 | ||||
|
860 | $ for x in 1 2 3 4 5 6 7 8 9; do | |||
|
861 | > echo $x > file-$x # make sure we have interresting compression | |||
|
862 | > echo $x > dir/foo-$x # make sure we have interresting compression | |||
|
863 | > hg add file-$x | |||
|
864 | > hg add dir/foo-$x | |||
|
865 | > done | |||
|
866 | $ hg ci -m 'have some content' | |||
|
867 | $ f -s .hg/store/00manifest.* | |||
|
868 | .hg/store/00manifest.i: size=798 (no-pure !) | |||
|
869 | .hg/store/00manifest.i: size=784 (pure !) | |||
|
870 | $ f -s .hg/store/meta/dir/00manifest* | |||
|
871 | .hg/store/meta/dir/00manifest.i: size=556 (no-pure !) | |||
|
872 | .hg/store/meta/dir/00manifest.i: size=544 (pure !) | |||
|
873 | $ hg debugupgraderepo --config format.revlog-compression=none --config experimental.treemanifest=yes --run --quiet --no-backup | |||
|
874 | upgrade will perform the following actions: | |||
|
875 | ||||
|
876 | requirements | |||
|
877 | preserved: * (glob) | |||
|
878 | removed: revlog-compression-zstd (no-pure !) | |||
|
879 | added: exp-compression-none | |||
|
880 | ||||
|
881 | processed revlogs: | |||
|
882 | - all-filelogs | |||
|
883 | - changelog | |||
|
884 | - manifest | |||
|
885 | ||||
|
886 | $ hg verify | |||
|
887 | checking changesets | |||
|
888 | checking manifests | |||
|
889 | checking directory manifests | |||
|
890 | crosschecking files in changesets and manifests | |||
|
891 | checking files | |||
|
892 | checking dirstate | |||
|
893 | checked 4 changesets with 22 changes to 20 files | |||
|
894 | $ f -s .hg/store/00manifest.* | |||
|
895 | .hg/store/00manifest.i: size=1002 | |||
|
896 | $ f -s .hg/store/meta/dir/00manifest* | |||
|
897 | .hg/store/meta/dir/00manifest.i: size=721 | |||
|
898 | $ hg files --rev tip | wc -l | |||
|
899 | \s*20 (re) |
@@ -192,11 +192,11 b' Unless the action is compatible with sha' | |||||
192 | summary: r7 |
|
192 | summary: r7 | |
193 |
|
193 | |||
194 |
|
194 | |||
195 |
Do not yet support |
|
195 | Do not yet support downgrading treemanifest repos | |
196 |
|
196 | |||
197 | $ hg --config experimental.treemanifest=true init treemanifest |
|
197 | $ hg --config experimental.treemanifest=true init treemanifest | |
198 | $ hg -R treemanifest debugupgraderepo |
|
198 | $ hg -R treemanifest debugupgraderepo | |
199 |
abort: cannot upgrade repository; |
|
199 | abort: cannot upgrade repository; requirement would be removed: treemanifest | |
200 | [255] |
|
200 | [255] | |
201 |
|
201 | |||
202 | Cannot add treemanifest requirement during upgrade |
|
202 | Cannot add treemanifest requirement during upgrade |
General Comments 0
You need to be logged in to leave comments.
Login now