[PATCH 1 of 7] hglib: make sure configs can be passed to clone command
Mathias De Maré
mathias.demare at gmail.com
Tue Mar 14 11:57:01 UTC 2023
On Tue, Mar 14, 2023 at 9:27 AM Mathias De Mare <mathias.de_mare at nokia.com>
wrote:
> # HG changeset patch
> # User Mathias De Mare <mathias.de_mare at nokia.com>
> # Date 1646834891 -3600
> # Wed Mar 09 15:08:11 2022 +0100
> # Node ID 2876df3b730bb565d4f64764dd900b2ddb47a19c
> # Parent 68588c652ac6949c2e21531488aa138ecaab2442
> hglib: make sure configs can be passed to clone command
>
As Raphaël has created a python-hglib repository on heptapod, I've sent
these patches as a merge request:
https://foss.heptapod.net/mercurial/python-hglib/-/merge_requests/1
> Differential Revision: https://phab.mercurial-scm.org/D12360
>
> diff --git a/hglib/__init__.py b/hglib/__init__.py
> --- a/hglib/__init__.py
> +++ b/hglib/__init__.py
> @@ -31,6 +31,13 @@ def clone(source=None, dest=None, noupda
> pull=pull, uncompressed=uncompressed,
> e=ssh, remotecmd=remotecmd, insecure=insecure)
>
> + # insert configs at the front so they don't interfere with positional
> args
> + if configs:
> + cmdconfigs = []
> + for config in configs:
> + cmdconfigs.extend(["--config", config])
> + args = cmdconfigs + args
> +
> args.insert(0, HGPATH)
> proc = util.popen(args)
> out, err = proc.communicate()
>
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel at lists.mercurial-scm.org
> https://lists.mercurial-scm.org/mailman/listinfo/mercurial-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-devel/attachments/20230314/8c1ddcc6/attachment.html>
More information about the Mercurial-devel
mailing list