author | Arseniy Alekseyev <aalekseyev@janestreet.com> |
Fri, 12 Apr 2024 14:21:14 +0100 | |
branch | stable |
changeset 51568 | 2a89d2f6336f |
parent 51181 | dcaa2df1f688 |
permissions | -rw-r--r-- |
50724
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
1 |
#require rust |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
2 |
|
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
3 |
$ cat >> $HGRCPATH << EOF |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
4 |
> [format] |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
5 |
> use-dirstate-v2=1 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
6 |
> [storage] |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
7 |
> dirstate-v2.slow-path=allow |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
8 |
> EOF |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
9 |
|
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
10 |
$ hg init t |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
11 |
$ cd t |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
12 |
|
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
13 |
$ for i in 1 2 3 4 5 6 7 8 9 10; do touch foobar$i; done |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
14 |
$ hg add . |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
15 |
adding foobar1 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
16 |
adding foobar10 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
17 |
adding foobar2 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
18 |
adding foobar3 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
19 |
adding foobar4 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
20 |
adding foobar5 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
21 |
adding foobar6 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
22 |
adding foobar7 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
23 |
adding foobar8 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
24 |
adding foobar9 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
25 |
$ hg commit -m "1" |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
26 |
|
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
27 |
Check that there's no space leak on debugrebuilddirstate |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
28 |
|
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
29 |
$ f --size .hg/dirstate* |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
30 |
.hg/dirstate: size=133 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
31 |
.hg/dirstate.88698448: size=511 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
32 |
$ hg debugrebuilddirstate |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
33 |
$ f --size .hg/dirstate* |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
34 |
.hg/dirstate: size=133 |
a10d823a8e3d
dirstate: avoid leaking disk space in `hg debugrebuilddirstate`
Arseniy Alekseyev <aalekseyev@janestreet.com>
parents:
diff
changeset
|
35 |
.hg/dirstate.6b8ab34b: size=511 |
51181
dcaa2df1f688
changelog: never inline changelog
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50724
diff
changeset
|
36 |
$ hg debugrebuilddirstate |
dcaa2df1f688
changelog: never inline changelog
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50724
diff
changeset
|
37 |
$ f --size .hg/dirstate* |
dcaa2df1f688
changelog: never inline changelog
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50724
diff
changeset
|
38 |
.hg/dirstate: size=133 |
dcaa2df1f688
changelog: never inline changelog
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50724
diff
changeset
|
39 |
.hg/dirstate.b875dfc5: size=511 |