From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id yEYkMeCJ5Wa6WwAA62LTzQ:P1 (envelope-from ) for ; Sat, 14 Sep 2024 13:04:32 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1.migadu.com with LMTPS id yEYkMeCJ5Wa6WwAA62LTzQ (envelope-from ) for ; Sat, 14 Sep 2024 15:04:32 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=S39ljnNY; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20230601 header.b=Br9qGJ5F; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=gmail.com (policy=none) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1726319036; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-to: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=uwzbkPnuyxWERprgrYzzCDqQ3lc6K+kXm6q7RGtFaWc=; b=PkRgex6TOMpdnYFabMnpxdrgK5v6W2R5KfJx08yk+HgKt2th5yVFGm7pci5AvW+asEhx/c JKCIn+wI6fsJxAv+YVxuIqBtZXPu7Un81hPKvNDOuDMG3/9+xAMJtnr6Gx80/tqQT05SpC 7+/sE56byLzHWikmGva9U6sxdgcGrHE1qkBFqThK3Ws66/qeMk/nRqppGR0zwow94MYRpR CCLzWua5wDPxznN79JA+/HUuGK5w5kh5UR2c9eQomDZh6dU97DZ5AufkQtjxlDze9QriBR 8V0mTuU+8B6X2QeYppvAdbFT72SG/bXUtnY1LAQabz71+G8f6XNMz0/ug2IQXQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=S39ljnNY; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20230601 header.b=Br9qGJ5F; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=gmail.com (policy=none) ARC-Seal: i=1; s=key1; d=yhetil.org; t=1726319036; a=rsa-sha256; cv=none; b=ijYFQjTWp09DHkXPxb99csGONQIzslmc3lLoYICCKD13crahBZXSSavHClN2bTh/dOj+Wu f9zc0A+EgZIEbbLIa9/x+FZjdTHjm1rwNJnHvG56EuaqVecENZLggg9h7Ki2uy+IZftuv/ q7+W1FCZ2hTaia0NYmWDeVf2UA7e+O8iHMGVxmJL+770js0FSEo4nEz/CVPXv+7UbkoyvM nz4zGO67DR+LREosPymcS307zDn/FgWEJI+rKRQGAaV+7EgAskaYmJgHMVRAP2suICrAsP s9YoASBYOUiS6mwn3s72d4VqYb3qDg9Tqrxj+Qf5vMwXEZk+1ms6i8KCO+17KA== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 849527F034 for ; Sat, 14 Sep 2024 15:03:56 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1spSQT-0007lb-1Y; Sat, 14 Sep 2024 09:02:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1spSQR-0007jd-4W for guix-patches@gnu.org; Sat, 14 Sep 2024 09:02:55 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1spSQP-0008O0-Ae for guix-patches@gnu.org; Sat, 14 Sep 2024 09:02:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=uwzbkPnuyxWERprgrYzzCDqQ3lc6K+kXm6q7RGtFaWc=; b=S39ljnNYoZvj24tQc61cXTycK3tFsDTrIyBz58UKWxj4bBVyVXEpqzwFHvc/YMQK1V5ucLMUitCp3NlPVD9KGJt5thOXhMbmsv2rhlyxlfXmAy0wFdnrBmrKISpayHUQlwPMnU1ZA6KgV0YHsCkvQu+RJkXVy2plzYj0oYHzhk9pHwPK/jeIbCWjuEQqZUnrsaYeONxFgesTYUvO0Iix79e7XkjAK8ei9lpCYYiXn7u5aYBIbvYLnXGgm+2AF3LOyJZ145cceAgLW+NI/Ab9TcvQT7rGS4OSP950Iq/GbeACXqTYBeAB8fSptBiPDVZ9hPl7nLnrYWK54zdVUelu6g==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1spSQY-0004TJ-Pg; Sat, 14 Sep 2024 09:03:02 -0400 Subject: bug#66704: [PATCH v2] gnu: patman: Wrap program with git. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-To: guix-patches@gnu.org, Steve George Resent-Date: Sat, 14 Sep 2024 13:03:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 66704 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Simon Tournier Cc: 66704-done@debbugs.gnu.org, Vagrant Cascadian , Efraim Flashner Mail-Followup-To: 66704@debbugs.gnu.org, maxim.cournoyer@gmail.com, zimon.toutoune@gmail.com Received: via spool by 66704-done@debbugs.gnu.org id=D66704.172631897517168 (code D ref 66704); Sat, 14 Sep 2024 13:03:02 +0000 Received: (at 66704-done) by debbugs.gnu.org; 14 Sep 2024 13:02:55 +0000 Received: from localhost ([127.0.0.1]:45069 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1spSQR-0004Sp-8u for submit@debbugs.gnu.org; Sat, 14 Sep 2024 09:02:55 -0400 Received: from mail-pf1-f179.google.com ([209.85.210.179]:42259) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1spSQP-0004Sa-FO for 66704-done@debbugs.gnu.org; Sat, 14 Sep 2024 09:02:54 -0400 Received: by mail-pf1-f179.google.com with SMTP id d2e1a72fcca58-718d91eef2eso1949573b3a.1 for <66704-done@debbugs.gnu.org>; Sat, 14 Sep 2024 06:02:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1726318897; x=1726923697; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=uwzbkPnuyxWERprgrYzzCDqQ3lc6K+kXm6q7RGtFaWc=; b=Br9qGJ5FloAi1FQ5bBOXSg/0CrBHnpANN4pUSW5E7YlbunWaavaa88Md2ZyMaSnyea rZeXyLiROeLF1La5vaDnQfyIKIOT6m7OOXP1lhQXoYaMA/x86MGgMfeJmGBnGisN7Br7 APznzl0AA39+D18b0o7khE4GWngX8e/QFkA4SqlDL5WGWGSB+l/XcakoCCDl5iMocbkV KVGFwbmvKenE4UO5BfVphQTrIEceGC44qP+JY16Y5D4SiTu4S0iF244f42LS1PWt6KT6 UiynlSELGBjwLns7FeT4JHStHT/f3kwkFvYWinpP8OQW0QNF0VYwr5DMjOtxNWNJaLqJ nJxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1726318897; x=1726923697; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=uwzbkPnuyxWERprgrYzzCDqQ3lc6K+kXm6q7RGtFaWc=; b=EM9cWf86L4mHyhoL1lc6PhveUxFjetIAB9d8vrPYsL4abCW7+6+eBxyhLiQcbzUPT2 WHrrF23dQPrInyKHky9QBgHRrhtToKVCB23Ok1DO/IOCfzPXm1drmu0VPqWZaELpAaCO tQn4/hR/Ohk6UsrbA+krZ4HCZd52AzjTMw0BVnfmrjKSctol6Bi0NwkYLpB8qmLQJx/K fqn+xIpYOpEQlhSwejk1p7E5O4gZz25qjQRGE37QAoU57zFHgj8PV94h1xAoKHMMNJt4 EAwnfEDdSi8wyOcrZ7/0CLGQKfQ2Yeta95FbDfgSRF6A1GVenKVT3wSZJmoj7vNCEvx5 eO+A== X-Gm-Message-State: AOJu0YzzHYz5gbNEDkhxF6UOMYskR0lbybPTx1cTbwvvK9Pt5JD5jgWG hFj1OYotPXNYfq3BotD6ZyuIIbHjI+dN63BDfabmIedpB4wtccXq X-Google-Smtp-Source: AGHT+IHF7nC+ITI1FeWlYsOlw4L/xwvLyNl7av5mlcx1vwmVMYznXcwwO6NNVXlzEc6RtpbQYYCnSQ== X-Received: by 2002:a05:6a21:6e41:b0:1cf:3338:a475 with SMTP id adf61e73a8af0-1cf755c7824mr16816215637.9.1726318896496; Sat, 14 Sep 2024 06:01:36 -0700 (PDT) Received: from hurd ([2405:6586:be0:0:c8ff:1707:9b9:af89]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-71944b97608sm955959b3a.153.2024.09.14.06.01.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 14 Sep 2024 06:01:35 -0700 (PDT) From: Maxim Cournoyer In-Reply-To: <3b43a54f344bbe0824d351915fdb4db979b10a00.1721757000.git.zimon.toutoune@gmail.com> (Simon Tournier's message of "Tue, 23 Jul 2024 19:59:18 +0200") References: <3b43a54f344bbe0824d351915fdb4db979b10a00.1721757000.git.zimon.toutoune@gmail.com> Date: Sat, 14 Sep 2024 22:01:33 +0900 Message-ID: <87bk0qtmmq.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Queue-Id: 849527F034 X-Migadu-Scanner: mx11.migadu.com X-Spam-Score: -8.93 X-Migadu-Spam-Score: -8.93 X-TUID: 2jcSWqjmxtL9 Hi Simon, Simon Tournier writes: > * gnu/packages/bootloaders.scm (patman): Replace by 'package/inherit'. I don't think package/inherit is appropriate here; patman is not a variant of u-boot (doesn't share any of its inputs) -- it jut happens to have its source part of the u-boot sources. I've dropped it. > [arguments]: Add 'wrap-program' that uses git dependency. > [inputs]: Add git and git:send-email. > > Change-Id: Id4ebadd518f271baa087161b10455ec03d6f959b > --- > gnu/packages/bootloaders.scm | 22 ++++++++++++++++++---- > 1 file changed, 18 insertions(+), 4 deletions(-) > > Hi, > > On Mon, 23 Oct 2023 at 21:05, Maxim Cournoyer = wrote: > >> I see 'git send-email' in the above > > Good catch! Added. However, I am not happy with the mix of =E2=80=9Csty= les=E2=80=9D. And I > suspect a =E2=80=9Cbug=E2=80=9D or something lacking for packages with mu= ltiple outputs; I am > going to open a report about that. Another story and not blocking, IMHO. > > >> Did you test that this suffices to get a fully >> self-contained working patman? Maybe you can send a v2 with patman. [...] > (substitute* "pyproject.toml" > (("patman.__main__:run_patman") > - "patman.__main__"))))))) > - (inputs (list python-pygit2 python-requests python-u-boot-pylib)) > + "patman.__main__")))) > + (add-after 'install 'wrap-program > + (lambda* (#:key inputs #:allow-other-keys) > + (let ((git:send-email (assoc-ref inputs "git:send-email"))) > + (wrap-program (string-append #$output "/bin/patman") > + `("PATH" ":" prefix > + (,(string-append #$(this-package-input "git") "/bin"= ))) > + `("GIT_EXEC_PATH" ":" prefix > + (,(string-append #$(this-package-input "git") "/libe= xec/git-core") > + ,(string-append git:send-email "/libexec/git-core")= ))))))))) I think 'search-input-file' would be better here. It should be preferred to gexps in general, as it is more lazy and works better with inheritance. > + (inputs `(("git" ,git) > + ("git:send-email" ,git "send-email") > + ("python-pygit2" ,python-pygit2) > + ("python-requests" ,python-requests) > + ("python-u-boot-pylib" ,python-u-boot-pylib))) > (synopsis "Patch automation tool") > (description "Patman is a patch automation script which: > @itemize I modified this to avoid adding labels, which was not necessary. I've also used wrap-script, which inserts the wrapping in the Python script directly instead of creating a .patman-real wrapper, which uglifies the process name in top, for example. You'll find the result in commit 4c99ef43f0. Thanks for kicking the ball. --=20 Thanks, Maxim