Raphaël Gomès <rgomes@octobus.net> [Wed, 24 Jun 2020 17:20:39 +0200] rev 45112
rust-status: improve documentation and readability
This patch is 2/3 in the series to improve the dirstate status code. It adds a
number of common type aliases to add more obvious semantics to function
signatures, improves/adds documentation where necessary and improves one or two
patterns to be more idiomatic.
Differential Revision: https://phab.mercurial-scm.org/D8662
Raphaël Gomès <rgomes@octobus.net> [Wed, 24 Jun 2020 16:12:45 +0200] rev 45111
rust-status: refactor status into a struct
The code for `dirstate/status` has grown too large for comfort, this is the
first of three patches that try to improve maintainability.
In this patch, refactoring dirstate's status into a struct allows for slimming
down function signatures drastically, keeping the mental (and maintenance)
burden lower, since pretty much all of them shared a few common arguments.
This had the pleasant side-effect of simplifying lifetimes a little. This has
no observable impact on performance.
The next patch will add/improve documentation and refactor some types. I tried
to keep new code down to a minimum in this patch because it's already pretty
big.
Differential Revision: https://phab.mercurial-scm.org/D8661
Martin von Zweigbergk <martinvonz@google.com> [Fri, 13 Dec 2019 22:20:03 -0800] rev 45110
tests: avoid "magic" nodeids in test-rebase-legacy.t
This helps with readability.
Differential Revision: https://phab.mercurial-scm.org/D8735
Martin von Zweigbergk <martinvonz@google.com> [Fri, 13 Dec 2019 22:08:18 -0800] rev 45109
tests: avoid a "magic" nodeid in test-wireproto-command-lookup.t
This helps with readability.
Differential Revision: https://phab.mercurial-scm.org/D8734
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 22 Jun 2020 13:51:48 +0530] rev 45108
run-tests: replace '#' with '-' in temp path of repos created for tests
If we have multiple cases in a test, that leads us to a temp path of
format "<temp-path>-<case1>#<case2>".
This leads to hg.parseurl() parsing the path and take part
after `#` as a branch name.
I encountered this bug while adding support for share-safe case in next patch.
Differential Revision: https://phab.mercurial-scm.org/D8647
Pulkit Goyal <7895pulkit@gmail.com> [Tue, 14 Apr 2020 17:06:11 +0530] rev 45107
debugcommands: introduce new debugrequirements command
This for now just prints out the list of current requirements. In future this
will be helpful in reading requirements from couple of sources, and checking
which requirement comes from where.
Differential Revision: https://phab.mercurial-scm.org/D8632
Pulkit Goyal <7895pulkit@gmail.com> [Tue, 14 Apr 2020 16:43:54 +0530] rev 45106
scmutil: add writereporequirements() and route requires writing through it
In upcoming patches, to implement Share Safe plan we will be introducing
requires file in store. We need to route all callers to a single function
to check for a share-safe requirement and if present, write requirements to
.hg/store/requires instead.
After this patch, callers directly calling scmutil.writerequires() are only
those where we don't have the repo object, for example when initializing
the repository object itself.
Differential Revision: https://phab.mercurial-scm.org/D8631
Martin von Zweigbergk <martinvonz@google.com> [Tue, 14 Jul 2020 11:28:06 -0700] rev 45105
extensions: make `hg nonexistent` not crash with PyOxidizer
When running `hg nonexistent`, we try to look for extensions that
provide that command. We do that by looking for files in the
`hgext.__file__` directory. However, PyOxidizer doesn't provide a
`__file__`, so we crash when running with PyOxidizer.
We should be able to look for the command in built-in extensions, but
we seem to already have code for skipping the scan when running in a
frozen binary, so I just modified that code instead.
By the way, it also seems like we should be able to search for
extensions in the `hgext3rd` module, but we don't do that yet either
(before or after this patch).
Differential Revision: https://phab.mercurial-scm.org/D8750