- Jul 03, 2021
-
-
Anton Shestakov authored
Previously, the second push in the added test would say "push would publish 2 changesets" because _checkpublish() was considering secret changesets to be "pushable" when push command had a --rev argument. Without --rev argument to push command, we already filter the repo properly. Differential Revision: https://phab.mercurial-scm.org/D10948
-
- Jul 01, 2021
-
-
Simon Sapin authored
Differential Revision: https://phab.mercurial-scm.org/D10919
-
- Jul 02, 2021
-
-
Pierre-Yves David authored
We are about to modify this, so let us document the existing code. Differential Revision: https://phab.mercurial-scm.org/D10935
-
Pierre-Yves David authored
This special case is now directly handled, this clarify the possible value for the other options. Differential Revision: https://phab.mercurial-scm.org/D10933
-
Pierre-Yves David authored
This lets says what we mean instead of using magic value. The lower level can then decide how to express that. Differential Revision: https://phab.mercurial-scm.org/D10932
-
Pierre-Yves David authored
This lets says what we mean instead of using magic value. The lower level can then decide how to express that. Differential Revision: https://phab.mercurial-scm.org/D10931
-
Pierre-Yves David authored
We want to remove the magic value usage from the higher level, so lets stop passing them explicitely when possible. Differential Revision: https://phab.mercurial-scm.org/D10930
-
- Jul 01, 2021
-
-
Pierre-Yves David authored
The goal is to get ready to move these kind of processing at a lower level. We start with move move _rangemask filtering close to where it is sent to the lower level to make the future move trivial. Differential Revision: https://phab.mercurial-scm.org/D10929
-
Pierre-Yves David authored
This is going to be clearer and easier to track than -1. Ultimately I would like to get ride of this special value everywhere but in the lower level, however we need to clarify the API first. This changeset is part of such clarification. Differential Revision: https://phab.mercurial-scm.org/D10928
-
Pierre-Yves David authored
This is going to be clearer and easier to track than -1. Ultimately I would like to get ride of this special value everywhere but in the lower level, however we need to clarify the API first. This changeset is part of such clarification. Differential Revision: https://phab.mercurial-scm.org/D10927
-
Pierre-Yves David authored
This is going to be clearer and easier to track than -2. Ultimately I would like to get ride of this special value everywhere but in the lower level, however we need to clarify the API first. This changeset is part of such clarification. Differential Revision: https://phab.mercurial-scm.org/D10926
-
Pierre-Yves David authored
This is shorter and simpler to read. Differential Revision: https://phab.mercurial-scm.org/D10925
-
Pierre-Yves David authored
This is simpler to read. Differential Revision: https://phab.mercurial-scm.org/D10924
-
Pierre-Yves David authored
This is shorter and simpler to read. Differential Revision: https://phab.mercurial-scm.org/D10923
-
- Jun 28, 2021
-
-
Simon Sapin authored
… and change the `DirstateMap::has_dir` method to be based on this counter being non-zero instead of the mere presence of a node. A node with zero descendent with an entry currently should be removed from the tree, but soon we’ll make the dirstate track additional nodes. (Specifically, for non-ignored directories in order to keep track of their mtime and optimize status by doing fewer `read_dir` calls.) Differential Revision: https://phab.mercurial-scm.org/D10922
-
Simon Sapin authored
… in Rust-backed dirstatemap. The Python class `dirstatemap` had cached properties `_dirs` and `_alldirs` that were not used for `hastrackeddir` and `hasdir` since they were redundant with corresponding fields for the Rust `DirstateMap` struct. `dirfoldmap` is modified to reuse instead the directory iterator introduced in 3b9914b28133. Differential Revision: https://phab.mercurial-scm.org/D10921
-
Simon Sapin authored
This saves 12 bytes per node. (Nodes representing files or directories.) These are offsets to other parts of the file. This would only be a limitation for a `.hg/dirstate` file larger than 4 GiB, which would only happen for a repository with dozens of millions of files and directories. Differential Revision: https://phab.mercurial-scm.org/D10920
-
- Jun 24, 2021
-
-
Simon Sapin authored
See code comments Differential Revision: https://phab.mercurial-scm.org/D10909
-
- Jun 04, 2021
-
-
Simon Sapin authored
Soon we’ll want the status algorithm to be able to skip `std::fs::read_dir` in more cases, notabling when listing unknown files but not ignored files. When ignore patterns change (which we detect by their hash, added to the dirstate-v2 format in a previous changeset), a formerly-ignored file could become unknown without changing its parent directory’s modification time. Therefore we remove any directory mtime from the dirstate, effictively invalidating the existing caches. Differential Revision: https://phab.mercurial-scm.org/D10907
-
- Jun 22, 2021
-
-
Pierre-Yves David authored
We now have a "generic" rewrite function (only able to do censoring for now) and a thin wrapper that implement the `censor` API with it. We are now ready to start incorporating strip specific changes. Differential Revision: https://phab.mercurial-scm.org/D10904
-
Pierre-Yves David authored
Instead of considering a special unique censored revision within the code, we consider a set of revision (currently always of size 1). This make the main code less censor-centric and prepare for the usage of a similar approach for stripping changesets. Differential Revision: https://phab.mercurial-scm.org/D10903
-
Pierre-Yves David authored
Now that the bulk of the code moved to smaller function we are less restricted on line length and we can use more explicite naming. Differential Revision: https://phab.mercurial-scm.org/D10902
-
Pierre-Yves David authored
The v2_censor function is huge, now that its content has settled a bit it is a good time to split individual part inside dedicated function. The last part is the file copying and opening logic. It now have its own function. Differential Revision: https://phab.mercurial-scm.org/D10901
-
Pierre-Yves David authored
The v2_censor function is huge, now that its content has settled a bit it is a good time to split individual part inside dedicated function. It is now the turn of the logic that recompute new delta to replace the one based on the revision that are going away. Differential Revision: https://phab.mercurial-scm.org/D10900
-
Pierre-Yves David authored
The v2_censor function is huge, now that its content has settled a bit it is a good time to split individual part inside dedicated function. We continue with a small function that add a non-censored revision back to the revlog. Differential Revision: https://phab.mercurial-scm.org/D10899
-
Pierre-Yves David authored
The v2_censor function is huge, now that its content has settled a bit it is a good time to split individual part inside dedicated function. We start with a small function that process the censored revision. Differential Revision: https://phab.mercurial-scm.org/D10898
-
Pierre-Yves David authored
This will be simpler to pass these file around in future changesets. Differential Revision: https://phab.mercurial-scm.org/D10897
-
Pierre-Yves David authored
The logic we use for censoring revision will be mostly common with the one we needs for stripping. So we rename the module to `rewrite` to better match its future content. Differential Revision: https://phab.mercurial-scm.org/D10896
-
- Jun 17, 2021
-
-
Simon Sapin authored
Instead of having a callback that opens and closes that file many times, a add and use a context manager method on the `revlog` class that keeps files open for its duration. Differential Revision: https://phab.mercurial-scm.org/D10888
-
- Jun 22, 2021
-
-
Matt Harbison authored
Otherwise, this extension gets highlighted as a 3rd party extension when an exception occurs. Differential Revision: https://phab.mercurial-scm.org/D10895
-
- Jun 21, 2021
-
-
Raphaël Gomès authored
This was introduced a while back while not being imported anywhere in the module system. How pertinent this Facebook module was to the codebase was debatable at the time, nowadays with the Rust VFS layer having laid its foundations, it is clear that we should drop it. Differential Revision: https://phab.mercurial-scm.org/D10890
-
Martin von Zweigbergk authored
Differential Revision: https://phab.mercurial-scm.org/D10892
-
Martin von Zweigbergk authored
This is just another little py3 cleanup. Differential Revision: https://phab.mercurial-scm.org/D10891
-
- Jun 22, 2021
-
-
Martin von Zweigbergk authored
Noticed by pyflakes (which I didn't have installed for Python 3.9 when I sent D10884). Differential Revision: https://phab.mercurial-scm.org/D10894
-
- Jun 07, 2021
-
-
Pierre-Yves David authored
It is a bit verbose and rough, but it works. Most of that logic can be common for `stripping`, so we can expect more refactoring of that code to accommodate both needs. However I wanted to keep this changesets "simple enough" and before moving forward. We also need to properly delete the older index/data/sidedata file, but this has implication for streaming clone and transaction, so this will come later. Differential Revision: https://phab.mercurial-scm.org/D10869
-
- Jun 20, 2021
-
-
Pierre-Yves David authored
Otherwise, recomputing a delta for a revision might result in a delta against a later revision or a full snapshot thinking we are appending a new revision. We will make use of this during censoring (and later, stripping). Differential Revision: https://phab.mercurial-scm.org/D10887
-
- Jun 09, 2021
-
-
Pierre-Yves David authored
These older files will eventually be removed, but we have to take them in account until they are. So we update `files` to keep fncache happy. Differential Revision: https://phab.mercurial-scm.org/D10868
-
- May 28, 2021
-
-
Pierre-Yves David authored
If we want to write content into new files, we need to be able to ask for them. Differential Revision: https://phab.mercurial-scm.org/D10867
-
- May 20, 2021
-
-
Pierre-Yves David authored
When the revlog content is rewritten, we will use new files, to avoid truncating the previous ones. We need some way to keep track of the older files before we clean them up. Differential Revision: https://phab.mercurial-scm.org/D10866
-
- Jun 21, 2021
-
-
Pierre-Yves David authored
This make the logic clearly isolated and documented and it will help use to reuse it during censors/strip. Differential Revision: https://phab.mercurial-scm.org/D10889
-