Show More
@@ -1,81 +1,90 b'' | |||||
|
1 | TRANSITIONAL CONFIG | |||
|
2 | $ cat << EOF >> $HGRCPATH | |||
|
3 | > [format] | |||
|
4 | > sparse-revlog = yes | |||
|
5 | > EOF | |||
|
6 | ||||
1 | A new repository uses zlib storage, which doesn't need a requirement |
|
7 | A new repository uses zlib storage, which doesn't need a requirement | |
2 |
|
8 | |||
3 | $ hg init default |
|
9 | $ hg init default | |
4 | $ cd default |
|
10 | $ cd default | |
5 | $ cat .hg/requires |
|
11 | $ cat .hg/requires | |
6 | dotencode |
|
12 | dotencode | |
7 | fncache |
|
13 | fncache | |
8 | generaldelta |
|
14 | generaldelta | |
9 | revlogv1 |
|
15 | revlogv1 | |
|
16 | sparserevlog | |||
10 | store |
|
17 | store | |
11 | testonly-simplestore (reposimplestore !) |
|
18 | testonly-simplestore (reposimplestore !) | |
12 |
|
19 | |||
13 | $ touch foo |
|
20 | $ touch foo | |
14 | $ hg -q commit -A -m 'initial commit with a lot of repeated repeated repeated text to trigger compression' |
|
21 | $ hg -q commit -A -m 'initial commit with a lot of repeated repeated repeated text to trigger compression' | |
15 | $ hg debugrevlog -c | grep 0x78 |
|
22 | $ hg debugrevlog -c | grep 0x78 | |
16 | 0x78 (x) : 1 (100.00%) |
|
23 | 0x78 (x) : 1 (100.00%) | |
17 | 0x78 (x) : 110 (100.00%) |
|
24 | 0x78 (x) : 110 (100.00%) | |
18 |
|
25 | |||
19 | $ cd .. |
|
26 | $ cd .. | |
20 |
|
27 | |||
21 | Unknown compression engine to format.compression aborts |
|
28 | Unknown compression engine to format.compression aborts | |
22 |
|
29 | |||
23 | $ hg --config experimental.format.compression=unknown init unknown |
|
30 | $ hg --config experimental.format.compression=unknown init unknown | |
24 | abort: compression engine unknown defined by experimental.format.compression not available |
|
31 | abort: compression engine unknown defined by experimental.format.compression not available | |
25 | (run "hg debuginstall" to list available compression engines) |
|
32 | (run "hg debuginstall" to list available compression engines) | |
26 | [255] |
|
33 | [255] | |
27 |
|
34 | |||
28 | A requirement specifying an unknown compression engine results in bail |
|
35 | A requirement specifying an unknown compression engine results in bail | |
29 |
|
36 | |||
30 | $ hg init unknownrequirement |
|
37 | $ hg init unknownrequirement | |
31 | $ cd unknownrequirement |
|
38 | $ cd unknownrequirement | |
32 | $ echo exp-compression-unknown >> .hg/requires |
|
39 | $ echo exp-compression-unknown >> .hg/requires | |
33 | $ hg log |
|
40 | $ hg log | |
34 | abort: repository requires features unknown to this Mercurial: exp-compression-unknown! |
|
41 | abort: repository requires features unknown to this Mercurial: exp-compression-unknown! | |
35 | (see https://mercurial-scm.org/wiki/MissingRequirement for more information) |
|
42 | (see https://mercurial-scm.org/wiki/MissingRequirement for more information) | |
36 | [255] |
|
43 | [255] | |
37 |
|
44 | |||
38 | $ cd .. |
|
45 | $ cd .. | |
39 |
|
46 | |||
40 | #if zstd |
|
47 | #if zstd | |
41 |
|
48 | |||
42 | $ hg --config experimental.format.compression=zstd init zstd |
|
49 | $ hg --config experimental.format.compression=zstd init zstd | |
43 | $ cd zstd |
|
50 | $ cd zstd | |
44 | $ cat .hg/requires |
|
51 | $ cat .hg/requires | |
45 | dotencode |
|
52 | dotencode | |
46 | exp-compression-zstd |
|
53 | exp-compression-zstd | |
47 | fncache |
|
54 | fncache | |
48 | generaldelta |
|
55 | generaldelta | |
49 | revlogv1 |
|
56 | revlogv1 | |
|
57 | sparserevlog | |||
50 | store |
|
58 | store | |
51 | testonly-simplestore (reposimplestore !) |
|
59 | testonly-simplestore (reposimplestore !) | |
52 |
|
60 | |||
53 | $ touch foo |
|
61 | $ touch foo | |
54 | $ hg -q commit -A -m 'initial commit with a lot of repeated repeated repeated text' |
|
62 | $ hg -q commit -A -m 'initial commit with a lot of repeated repeated repeated text' | |
55 |
|
63 | |||
56 | $ hg debugrevlog -c | grep 0x28 |
|
64 | $ hg debugrevlog -c | grep 0x28 | |
57 | 0x28 : 1 (100.00%) |
|
65 | 0x28 : 1 (100.00%) | |
58 | 0x28 : 98 (100.00%) |
|
66 | 0x28 : 98 (100.00%) | |
59 |
|
67 | |||
60 | $ cd .. |
|
68 | $ cd .. | |
61 |
|
69 | |||
62 | Specifying a new format.compression on an existing repo won't introduce data |
|
70 | Specifying a new format.compression on an existing repo won't introduce data | |
63 | with that engine or a requirement |
|
71 | with that engine or a requirement | |
64 |
|
72 | |||
65 | $ cd default |
|
73 | $ cd default | |
66 | $ touch bar |
|
74 | $ touch bar | |
67 | $ hg --config experimental.format.compression=zstd -q commit -A -m 'add bar with a lot of repeated repeated repeated text' |
|
75 | $ hg --config experimental.format.compression=zstd -q commit -A -m 'add bar with a lot of repeated repeated repeated text' | |
68 |
|
76 | |||
69 | $ cat .hg/requires |
|
77 | $ cat .hg/requires | |
70 | dotencode |
|
78 | dotencode | |
71 | fncache |
|
79 | fncache | |
72 | generaldelta |
|
80 | generaldelta | |
73 | revlogv1 |
|
81 | revlogv1 | |
|
82 | sparserevlog | |||
74 | store |
|
83 | store | |
75 | testonly-simplestore (reposimplestore !) |
|
84 | testonly-simplestore (reposimplestore !) | |
76 |
|
85 | |||
77 | $ hg debugrevlog -c | grep 0x78 |
|
86 | $ hg debugrevlog -c | grep 0x78 | |
78 | 0x78 (x) : 2 (100.00%) |
|
87 | 0x78 (x) : 2 (100.00%) | |
79 | 0x78 (x) : 199 (100.00%) |
|
88 | 0x78 (x) : 199 (100.00%) | |
80 |
|
89 | |||
81 | #endif |
|
90 | #endif |
General Comments 0
You need to be logged in to leave comments.
Login now