- Apr 14, 2021
-
-
Pierre-Yves David authored
We want to deprecate `ui.expandpath` and simplify the code before adding more complexity in the form of `[paths]` entry pointing to multiple url. So we inline the relevant bits. Differential Revision: https://phab.mercurial-scm.org/D10429
-
Pierre-Yves David authored
This is the last known user of `ui.expandpath` outside of `urlutil`. Hooray. Differential Revision: https://phab.mercurial-scm.org/D10428
-
Pierre-Yves David authored
Let's move this code to the new API. Differential Revision: https://phab.mercurial-scm.org/D10427
-
Pierre-Yves David authored
Lets move this code to the new API. Differential Revision: https://phab.mercurial-scm.org/D10426
-
Pierre-Yves David authored
Given we are talking about the path to an output file, I am fairly certain that the initial author meant to expand `~` and the like and not to resolve entry from `[paths]`. Differential Revision: https://phab.mercurial-scm.org/D10425
-
Pierre-Yves David authored
An even weirder feature of Mercurial is the ability to use `[paths]` alias as value of `--repository`. The weird feature now use the new APIs. Differential Revision: https://phab.mercurial-scm.org/D10424
-
Pierre-Yves David authored
This one is also resolving path. For now we restrict the feature to a single destination. This might change in the future. Differential Revision: https://phab.mercurial-scm.org/D10422
-
Pierre-Yves David authored
Another command moved to the new API, hooray. Differential Revision: https://phab.mercurial-scm.org/D10421
-
Pierre-Yves David authored
Summary can perform some incoming/outgoing queries (that should be common to the other command with the same needs, but that is another story). We now use the new APIs to do so. The current code behavior is a bit fishy, relying to the fact "default" will be picked as the destination in last resort. I did not altered that, but left various comment to highlight the issue. Differential Revision: https://phab.mercurial-scm.org/D10420
-
Pierre-Yves David authored
Since `hg share` is mostly like clone, do the same changes there. Differential Revision: https://phab.mercurial-scm.org/D10419
-
Pierre-Yves David authored
`hg init` has this weird feature were you can refer to `[paths]` entry select the path to initialize. We move that code to the new APIs. Differential Revision: https://phab.mercurial-scm.org/D10418
-
Pierre-Yves David authored
"Surprisingly", the new API is well suited for `hg clone` too. Differential Revision: https://phab.mercurial-scm.org/D10417
-
Pierre-Yves David authored
We do the same as for `hg outgoing`, instead of relying on implicit passing value by monkey punching them onto the repo object, we pass equivalent information by argument to the proper function. This is way cleaner. Differential Revision: https://phab.mercurial-scm.org/D10416
-
Pierre-Yves David authored
The command only support a single destination. We use the associated API. Differential Revision: https://phab.mercurial-scm.org/D10415
-
Pierre-Yves David authored
`hg outgoing` and `hg push` now support multiple destination. We do the same for `hg bundle`. Various other commands needs this kind of behavior and it would be create to factor this code out for their usage. However this is an adventure for another time. They are some minor change to the tests (in addition to the new test for the feature): * one because I updated a message to plurals, * another one because the error changed, and I actually find it clearer. Differential Revision: https://phab.mercurial-scm.org/D10414
-
Pierre-Yves David authored
The part of the lfs store that requires a destination cannot operate on multiple destination (yet). So we move them to the dedicated APIs. Differential Revision: https://phab.mercurial-scm.org/D10413
-
Pierre-Yves David authored
The code does not support multiple destination yet, so lets move it to the dedicated API. Differential Revision: https://phab.mercurial-scm.org/D10412
-
Pierre-Yves David authored
Given the context where path is most likely a file system path, I suspect that the initial author confused ui.expandpath and util.expandpath (a proxy for os.path.expanduser and co) Differential Revision: https://phab.mercurial-scm.org/D10411
-
- Apr 16, 2021
-
-
Pierre-Yves David authored
The command does not support multiple destination (yet). Differential Revision: https://phab.mercurial-scm.org/D10410
-
Pierre-Yves David authored
The extension does not support multiple destination (yet). Differential Revision: https://phab.mercurial-scm.org/D10456
-
- Apr 14, 2021
-
-
Pierre-Yves David authored
The code does not support multiple destination and will probably never do so. So lets use the dedicated API for this case. Differential Revision: https://phab.mercurial-scm.org/D10409
-
Pierre-Yves David authored
Same as for `pathbomb`, this code does not support multiple destinations yet. It might in the future, probably with code put in common with patchwork, but for now lets use the dedicated API. Differential Revision: https://phab.mercurial-scm.org/D10408
-
Pierre-Yves David authored
This function is dedicated to call that needs a single destination. Currently most caller actually need that since few actually support multiple destinations (the most importants `hg push` and `hg outgoing` do). So having a clear API point for that will be important when the time comes to have a single `[paths]` alias resolving to multiple urls. Differential Revision: https://phab.mercurial-scm.org/D10407
-
Pierre-Yves David authored
The fetch command does not support multiple destination, so we use the new dedicated API for that. Differential Revision: https://phab.mercurial-scm.org/D10406
-
Pierre-Yves David authored
The patchbomb code does not support multiple destinations yet. It would not be too hard to implemented since `hg outgoing` does. However that is a bit too much of a detour right now. In addition that kind of "select outgoing changesets for processing" code exist for various commands so the best would be to factor it out later. Let us use the dedicated API until this is solved. This comes with a small output change in the test that I find more accurate. So I kept it. Differential Revision: https://phab.mercurial-scm.org/D10405
-
Pierre-Yves David authored
The narrow's `tracked` command does not support multiple destination, lets use the dedicated API then. Differential Revision: https://phab.mercurial-scm.org/D10404
-
Pierre-Yves David authored
This function is dedicated to call that needs a single destination. Currently most caller actually need that since few actually support multiple destinations (the most importants `hg push` and `hg outgoing` do). So having a clear API point for that will be important when the time comes to have a single `[paths]` alias resolving to multiple urls. Differential Revision: https://phab.mercurial-scm.org/D10403
-
Pierre-Yves David authored
We stop using `ui.expandpath` to use a function with a more defined semantic. This will help us to make it an option to point [paths] entry to multiple destination. Differential Revision: https://phab.mercurial-scm.org/D10402
-
Pierre-Yves David authored
We add a new function with a semantic focussed on `clone` operation (so without an existing repository). I am not certain the return type is the best, but this is what we need for now. Once all caller are migrated we might start thinking about that the API should be. For now that will do. Differential Revision: https://phab.mercurial-scm.org/D10401
-
- Apr 11, 2021
-
-
Pierre-Yves David authored
The revsets now use the same code as everyone and is ready for entry in `[paths]` pointing to multiple entries. Differential Revision: https://phab.mercurial-scm.org/D10393
-
- Apr 14, 2021
-
-
Pierre-Yves David authored
Lets use the new method to increase code reuse. However I did not implement support for multiple source yet. It would be possible create multiple temporary bundle, but that is a bit too much work outside of my current route to make the detour. Differential Revision: https://phab.mercurial-scm.org/D10392
-
- Apr 13, 2021
-
-
Pierre-Yves David authored
This align the behavior of `hg outgoing` with the one of `hg incoming`. In addition this prepare the introduction of having simple `path` resolve to multiple destination in practice (eg: `default`) Differential Revision: https://phab.mercurial-scm.org/D10391
-
- Apr 15, 2021
-
-
Pierre-Yves David authored
This is clearer, remove the needs for the `repo._subtoppath` hack and will make our live easier when making `outgoing` accept multiple destinations. Differential Revision: https://phab.mercurial-scm.org/D10390
-
Pierre-Yves David authored
The `subrepoutil` module has various function to compute the path of a sub-repository compared to the root of the top repository. However, they was no function available to compute the relative path of the repository "source". And we need this information for exchange operation (in our case, `hg outgoing`). The information is currently build using the `repo._subtoppath` hack. We reuse the same logic but in a dedicated function independent of the `repo._subtoppath` hack. Differential Revision: https://phab.mercurial-scm.org/D10434
-
Matt Harbison authored
Caught by pytype. Also fix a minor grammar issue in the second message. Differential Revision: https://phab.mercurial-scm.org/D10433
-
- Apr 08, 2021
-
-
Raphaël Gomès authored
Gratuitous fix, I stumbled upon this comment while reading code. Differential Revision: https://phab.mercurial-scm.org/D10339
-
- Apr 13, 2021
-
-
Matt Harbison authored
Pytype flagged the exception handler where these are used as `[name-error]`, and PyCharm complained they may be used before assignment. Differential Revision: https://phab.mercurial-scm.org/D10376
-
- Mar 13, 2021
-
-
Simon Sapin authored
When the current directory is outside of the repository we need to turn everything into absolute filesystem paths in order to compute correct relative paths. This was previously done unconditionally, but is not necessary when the current directory is inside the repository. With this change `rhg files > /dev/null` at the root of a mozilla-central snapshot goes from ~150 ms to ~70 ms. My repository is located at a somewhat long path though (93 bytes). The effect may not be as pronounced at a shorter path. Differential Revision: https://phab.mercurial-scm.org/D10200
-
- Apr 13, 2021
-
-
Kyle Lippincott authored
Differential Revision: https://phab.mercurial-scm.org/D10389
-
Kyle Lippincott authored
Differential Revision: https://phab.mercurial-scm.org/D10388
-