From debbugs-submit-bounces@debbugs.gnu.org Thu May 04 02:47:32 2017 Received: (at submit) by debbugs.gnu.org; 4 May 2017 06:47:32 +0000 Received: from localhost ([127.0.0.1]:53483 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6AY0-0003Xd-0e for submit@debbugs.gnu.org; Thu, 04 May 2017 02:47:32 -0400 Received: from eggs.gnu.org ([208.118.235.92]:38470) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6AXy-0003XQ-E2 for submit@debbugs.gnu.org; Thu, 04 May 2017 02:47:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d6AXs-0004dw-5T for submit@debbugs.gnu.org; Thu, 04 May 2017 02:47:25 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:59583) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1d6AXs-0004dc-2M for submit@debbugs.gnu.org; Thu, 04 May 2017 02:47:24 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57673) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d6AXq-00007k-Pb for guix-patches@gnu.org; Thu, 04 May 2017 02:47:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d6AXn-0004Yo-Mn for guix-patches@gnu.org; Thu, 04 May 2017 02:47:22 -0400 Received: from li622-129.members.linode.com ([212.71.249.129]:51173 helo=mira.cbaines.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d6AXn-0004Xk-HB for guix-patches@gnu.org; Thu, 04 May 2017 02:47:19 -0400 Received: by mira.cbaines.net (Postfix, from userid 113) id 6610713E3CA; Thu, 4 May 2017 07:47:16 +0100 (BST) Received: from localhost (my83-216-89-217.cust.relish.net [83.216.89.217]) by mira.cbaines.net (Postfix) with ESMTPSA id 14DF013E3C9 for ; Thu, 4 May 2017 07:47:16 +0100 (BST) Received: from localhost.localdomain (localhost [127.0.0.1]) by localhost (OpenSMTPD) with ESMTP id 36187a98 for ; Thu, 4 May 2017 06:47:15 +0000 (UTC) From: Christopher Baines To: guix-patches@gnu.org Subject: [PATCH] gnu: tailon: Add missing inputs. Date: Thu, 4 May 2017 07:47:15 +0100 Message-Id: <20170504064715.9779-1-mail@cbaines.net> X-Mailer: git-send-email 2.12.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.0 (----) * gnu/packages/logging.scm (tailon)[inputs]: Add grep, gawk, sed and coreutils as inputs. [arguments]: Wrap bin/tailon to include some inputs in the PATH. --- gnu/packages/logging.scm | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/gnu/packages/logging.scm b/gnu/packages/logging.scm index 2523d65f6..060521eab 100644 --- a/gnu/packages/logging.scm +++ b/gnu/packages/logging.scm @@ -26,6 +26,8 @@ #:use-module (guix build-system gnu) #:use-module (guix build-system python) #:use-module (gnu packages) + #:use-module (gnu packages base) + #:use-module (gnu packages gawk) #:use-module (gnu packages perl) #:use-module (gnu packages python) #:use-module (gnu packages autotools)) @@ -108,7 +110,25 @@ command line.") (inputs `(("python-pyyaml" ,python-pyyaml) ("python-sockjs-tornado" ,python-sockjs-tornado) - ("python-tornado" ,python-tornado))) + ("python-tornado" ,python-tornado) + ("grep" ,grep) + ("gawk" ,gawk) + ("sed" ,sed) + ("tail" ,coreutils))) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'install 'wrap-tailon-path + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (wrap-program (string-append out "/bin/tailon") + `("PATH" ":" prefix ,(map + (lambda (input) + (string-append + (assoc-ref inputs input) + "/bin")) + '("grep" "gawk" "sed" "tail")))) + #t)))))) (home-page "https://tailon.readthedocs.io/") (synopsis "Webapp for looking at and searching through log files") -- 2.12.0 From debbugs-submit-bounces@debbugs.gnu.org Fri May 05 12:33:46 2017 Received: (at 26770) by debbugs.gnu.org; 5 May 2017 16:33:46 +0000 Received: from localhost ([127.0.0.1]:56591 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6gAr-0002Mt-Pi for submit@debbugs.gnu.org; Fri, 05 May 2017 12:33:45 -0400 Received: from out4-smtp.messagingengine.com ([66.111.4.28]:42677) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d6gAp-0002Mk-Lq for 26770@debbugs.gnu.org; Fri, 05 May 2017 12:33:44 -0400 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 1FD7620864; Fri, 5 May 2017 12:33:43 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute5.internal (MEProxy); Fri, 05 May 2017 12:33:43 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.com; h= content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc :x-sasl-enc; s=fm1; bh=rGtnMWkZhHagXd9wy8RVtQ/1IY6Xc6vCk/uvJIlfC 7k=; b=ZuHnGI3ceV9tKgYswoXlkY7zRD2TRQ/d2nhMpERHalZounkAXF2LBCjka WaIq0Y88fM2STdgbI8Fel9sX+vnjsVaJlXwiymGRzaW7X+oO6Hw/sB4nIBODmvGf lwGNp60y1HchcLRBc+xiwnuzC3+USy9IMT5C0C+mc6eZuwmWItznsr8UMb9sMxMk Qa61xqsqUUJ998uqyxCiSvNfPbmrLOUKqN3HLOm8XtpJPOBRlFlRW2vLPD4xropJ NvdeQwVHg9rOHQxMaaJrcwKIAay6HZe35sXTQD5InQObdsBbNPrrvuaR9DhQCR91 Wid9mFL14nw6mIn7zgy93xVmAn13g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc:x-sasl-enc; s=fm1; bh=rGtnMWkZhHagXd9wy8 RVtQ/1IY6Xc6vCk/uvJIlfC7k=; b=qj+SL0KRF/6+lJ96Rvu+uTybzt4XBxltML lt4rNDw0sMsICuvQhNjl8i/5lSynWCoFcD6+VHE/3+K1SPdjIYMSM4NEWNNNTvbQ wdqJ9dwkMCWcP1sujq9o3js5753Djxb/GYYiEBPtrRRtmf0PxYQ7NVfxt1nbfGDC jWnQIE6clEzpm92Sd9eo49XriF+i9G78FZxc+5n9BpEV8Dh0+5Pxr2dvxhPm5eEe gdd+Ti3LYgYPvbNYTF4Er1PFpZLML9CGWFO/xuiLBvtbcnaU2Lm8DMFzqv+m2NJ1 PEhTOVNkNrz5WQKpd6Tqw0JAawnMEK51AAOYvanh9NVTiNIF6MrA== X-ME-Sender: X-Sasl-enc: twEY+zK4A4qLXnQwcAVvd1b8+bh51nel4sHJoJ6CsMF8 1494002022 Received: from localhost (unknown [188.113.81.93]) by mail.messagingengine.com (Postfix) with ESMTPA id 9B3C0240A5; Fri, 5 May 2017 12:33:42 -0400 (EDT) From: Marius Bakke To: Christopher Baines , 26770@debbugs.gnu.org Subject: Re: bug#26770: [PATCH] gnu: tailon: Add missing inputs. In-Reply-To: <20170504064715.9779-1-mail@cbaines.net> References: <20170504064715.9779-1-mail@cbaines.net> User-Agent: Notmuch/0.24.1 (https://notmuchmail.org) Emacs/25.2.1 (x86_64-unknown-linux-gnu) Date: Fri, 05 May 2017 18:33:41 +0200 Message-ID: <877f1v1cwq.fsf@fastmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 26770 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) --=-=-= Content-Type: text/plain Christopher Baines writes: > * gnu/packages/logging.scm (tailon)[inputs]: Add grep, gawk, sed and coreutils > as inputs. > [arguments]: Wrap bin/tailon to include some inputs in the PATH. Generally it's better to fully qualify the paths to these programs in the code. Is that difficult here? I think all of these inputs are already available, so you can do e.g.: (substitute "foo" (("'grep'") (which "grep)) (("'gawk'") (which "gawk"))) ...instead of referencing the inputs explicitly. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAlkMqWUACgkQoqBt8qM6 VPrPyQf9G1aB5JMvAJTn6/fzSPn8BcfY8qQn4ON0oTm5wyMOYm3uAjfUZ7OxuKIm qWR8Le4tE8YRCY1lAwxQZXSR2wAgn4dMhjRhHOXqaXdoZdN1fcjNO5tZf7nR716H V7M2S3jtGEH3JFFtj7c5Snvbbl6sUBQrmShwEnaBl5SfvxpwwrPxgkOaRpJwLNSc BxfmHX5y7ZpN2ZBMwcLT3FhGBBjLAxw84oX0DLvrpP61ym9uNDYkzihamKjJWfWf eig8YduCKb1BoSknk8NpHxNdPoyBlESklZ5T2FxYCq+q2a6r1MnHz8J86vrZE35x hPzkUFNa5gttbij5wa2lg6lyhKshPw== =gmdb -----END PGP SIGNATURE----- --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Mon May 15 02:11:59 2017 Received: (at 26770) by debbugs.gnu.org; 15 May 2017 06:11:59 +0000 Received: from localhost ([127.0.0.1]:45397 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dA9Ed-0002PK-DM for submit@debbugs.gnu.org; Mon, 15 May 2017 02:11:59 -0400 Received: from li622-129.members.linode.com ([212.71.249.129]:41341 helo=mira.cbaines.net) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dA9Ec-0002PD-7y for 26770@debbugs.gnu.org; Mon, 15 May 2017 02:11:58 -0400 Received: by mira.cbaines.net (Postfix, from userid 113) id 21C7D13E3CE; Mon, 15 May 2017 07:11:56 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from localhost (my83-216-88-88.cust.relish.net [83.216.88.88]) by mira.cbaines.net (Postfix) with ESMTPSA id B8AC513E3B4 for <26770@debbugs.gnu.org>; Mon, 15 May 2017 07:11:55 +0100 (BST) Received: from localhost.localdomain (localhost [127.0.0.1]) by localhost (OpenSMTPD) with ESMTP id f3e1dd25 for <26770@debbugs.gnu.org>; Mon, 15 May 2017 06:11:55 +0000 (UTC) From: Christopher Baines To: 26770@debbugs.gnu.org Subject: [PATCH] gnu: tailon: Use absolute paths for commands. Date: Mon, 15 May 2017 07:11:55 +0100 Message-Id: <20170515061155.1380-1-mail@cbaines.net> X-Mailer: git-send-email 2.12.0 X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 26770 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) * gnu/packages/logging.scm (tailon)[arguments]: Patch commands.py to reference grep, awk, sed and tail by absolute paths. --- gnu/packages/logging.scm | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/gnu/packages/logging.scm b/gnu/packages/logging.scm index 2523d65f6..11bbfef52 100644 --- a/gnu/packages/logging.scm +++ b/gnu/packages/logging.scm @@ -109,6 +109,22 @@ command line.") `(("python-pyyaml" ,python-pyyaml) ("python-sockjs-tornado" ,python-sockjs-tornado) ("python-tornado" ,python-tornado))) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'install 'wrap-tailon-path + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (substitute* (find-files out "commands.py") + (("self\\.first_in_path\\('grep'\\)") + (string-append"'" (which "grep") "'")) + (("self\\.first_in_path\\('gawk', 'awk'\\)") + (string-append"'" (which "gawk") "'")) + (("self\\.first_in_path\\('gsed', 'sed'\\)") + (string-append"'" (which "sed") "'")) + (("self\\.first_in_path\\('gtail', 'tail'\\)") + (string-append"'" (which "tail") "'"))) + #t)))))) (home-page "https://tailon.readthedocs.io/") (synopsis "Webapp for looking at and searching through log files") -- 2.12.0 From debbugs-submit-bounces@debbugs.gnu.org Mon May 15 02:25:55 2017 Received: (at 26770) by debbugs.gnu.org; 15 May 2017 06:25:56 +0000 Received: from localhost ([127.0.0.1]:45403 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dA9S7-0002jG-NW for submit@debbugs.gnu.org; Mon, 15 May 2017 02:25:55 -0400 Received: from li622-129.members.linode.com ([212.71.249.129]:41357 helo=mira.cbaines.net) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dA9S6-0002j8-A4 for 26770@debbugs.gnu.org; Mon, 15 May 2017 02:25:54 -0400 Received: by mira.cbaines.net (Postfix, from userid 113) id 6034113E3D2; Mon, 15 May 2017 07:25:51 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from localhost (my83-216-88-88.cust.relish.net [83.216.88.88]) by mira.cbaines.net (Postfix) with ESMTPSA id F046813E3B4; Mon, 15 May 2017 07:25:50 +0100 (BST) Date: Mon, 15 May 2017 07:25:49 +0100 From: Christopher Baines To: Marius Bakke Subject: Re: bug#26770: [PATCH] gnu: tailon: Add missing inputs. Message-ID: <20170515072549.5c933ddc@cbaines.net> In-Reply-To: <877f1v1cwq.fsf@fastmail.com> References: <20170504064715.9779-1-mail@cbaines.net> <877f1v1cwq.fsf@fastmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/aqkiniBR4vcGggWtyKqV586"; protocol="application/pgp-signature" X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 26770 Cc: 26770@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) --Sig_/aqkiniBR4vcGggWtyKqV586 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Fri, 05 May 2017 18:33:41 +0200 Marius Bakke wrote: > Christopher Baines writes: >=20 > > * gnu/packages/logging.scm (tailon)[inputs]: Add grep, gawk, sed > > and coreutils as inputs. > > [arguments]: Wrap bin/tailon to include some inputs in the PATH. =20 >=20 > Generally it's better to fully qualify the paths to these programs in > the code. Is that difficult here? Good point, I've send an updated patch that does this. > I think all of these inputs are already available, so you can do e.g.: > (substitute "foo" > (("'grep'") (which "grep)) > (("'gawk'") (which "gawk"))) >=20 > ...instead of referencing the inputs explicitly. That works, I've changed that in the latest patch also. Thanks for your review :) --Sig_/aqkiniBR4vcGggWtyKqV586 Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEEPonu50WOcg2XVOCyXiijOwuE9XcFAlkZSe1fFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcACgkQXiijOwuE 9Xfl6g//fos/HeQyntt6j1RVDsLZ1SCtfxHPiT2EvpSdS5z488MoXQ9aWPNtd+zV KVuc5ZU70wRz/iCVYcTI6d4iee0nttOhQBkTcY/5KT0rYiYtij62hdPy65ZCduHv +xDFqpmr0Zq3U4WRqhgUJji/UAF1/dZmC9NK7pRmJKGskciCAe0adU4DwJX4e4b7 +dn356FzAqx4WR00IMMH4I+V1PO6lurgWPY45uCfD+gUmuD8+By0QfhGD8n1jfMr QGLeNM2Ce1lABYv+qUvEcrlrm+16Nu6Ut/j9fHh92MaPIlA4Lhl8pXKdAqgfcTvW KecUCXjdPeBXww3CkukXAE5b6E5rVgNQSdvT7CxQfiwImd5gOg4VyOOkE/tKz2iw xi+UtMSmIRe/uNodzLY9ejfxOtzVQNahl38Y9xqhw+uoVb+z3gmydkl6QipthgaJ VXPJ9i28VrfOuqfOcGAmuqd9erZ0MlFdbTSG9Vdw30eSouhjoa5pIzl9txKZurBS bRP4tv0vtpCeqO35BTsnw8bkUyka+cVvSfM6YpOtcIt9QEbPb561zCSHjAyN7UEE nar1cE/W38liZfWWNzr+NRZWxtSpf3vSqywaotO8DRzaqA6vGpFJN5dg2t9o7JHX P1SRq4JbMZEKIjmU7Nb6JxzgU1bL6f+HtNUzo19IZiqojsRLv1g= =yviO -----END PGP SIGNATURE----- --Sig_/aqkiniBR4vcGggWtyKqV586-- From debbugs-submit-bounces@debbugs.gnu.org Mon May 15 11:59:57 2017 Received: (at 26770) by debbugs.gnu.org; 15 May 2017 15:59:57 +0000 Received: from localhost ([127.0.0.1]:46757 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dAIPY-0001JN-UI for submit@debbugs.gnu.org; Mon, 15 May 2017 11:59:57 -0400 Received: from out4-smtp.messagingengine.com ([66.111.4.28]:48861) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dAIPT-0001JB-OK for 26770@debbugs.gnu.org; Mon, 15 May 2017 11:59:52 -0400 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 4F7DD20B42; Mon, 15 May 2017 11:59:44 -0400 (EDT) Received: from frontend1 ([10.202.2.160]) by compute5.internal (MEProxy); Mon, 15 May 2017 11:59:44 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.com; h= content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc :x-sasl-enc; s=fm1; bh=vhk0rGGgEcJhFbnpEDV+HBSJ5irgzI/AAauwkG5FA LI=; b=K254gSW+UBY0Rbd8VGPQ26jQg3syRZ6iM7Pp+gJaN2KA0TV4mcVL3AdBB NVhnS26vA6NJrIpotf9xJSbUFshM3/Q/ezwyUaDha7ZZvhY55wS5WDwNoD1RKpVr 0Ok3pe913kFST0/M259LWaK1+HZPsCBSbIju1diwR+61Q3WY/Oy4j6za6aRgLQSr dUmYGw6Lhu0Pk5bRaDjjl9nFX8NGxVt3jtK2+f8SWkcYVX5jfp7XeA+jjdLw4/5+ NrPJ4QxDIVIAhVvyENGEoQoMuV9ESctl5ab8qLrsqkoI+NiiFgjlKbbYpTeWJtCO lWqOR/8tn+2ZXReq34Ia9cPMErRAA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc:x-sasl-enc; s=fm1; bh=vhk0rGGgEcJhFbnpED V+HBSJ5irgzI/AAauwkG5FALI=; b=QDkY00U9gasVh206Be5uWjwglUv1QBUDhG X912dIgM1xEHha9+a5yXlL2vETKJ2zlAwzHWs8YgX+ufdo8tmr55w/Zru2ZTS8T3 P28cfK0hmg4QjJbfMysoQmH9LH0nG7X12vQR7hUThOe/w6oz/eKLNPZdiBXAAlke Yh4Xs6NJLYTa7DJ58nIRsVEdX+qPfysDueYJqz0BRXY7AYmiKjMkNyTS/thaBPlZ cXYKkjncPDOG1+8D+K6JH/u4qMpNhRB2mTi/U2GoB3vYfk4GJdS0AC4l388JQ+kh FkK3sVyyBPHerFf5dwmZj2ps8vJoSYNXZBfC0V7i+sFcF66TI8ew== X-ME-Sender: X-Sasl-enc: KFLUdhh+WmQ1uSGrG2KbUvfOfXEedQO8N3kJVywOy9Hu 1494863983 Received: from localhost (unknown [188.113.81.93]) by mail.messagingengine.com (Postfix) with ESMTPA id E18EF7E86A; Mon, 15 May 2017 11:59:43 -0400 (EDT) From: Marius Bakke To: Christopher Baines , 26770@debbugs.gnu.org Subject: Re: bug#26770: [PATCH] gnu: tailon: Use absolute paths for commands. In-Reply-To: <20170515061155.1380-1-mail@cbaines.net> References: <20170504064715.9779-1-mail@cbaines.net> <20170515061155.1380-1-mail@cbaines.net> User-Agent: Notmuch/0.24.1 (https://notmuchmail.org) Emacs/25.2.1 (x86_64-unknown-linux-gnu) Date: Mon, 15 May 2017 17:59:42 +0200 Message-ID: <87o9uuf6vl.fsf@fastmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 26770 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) --=-=-= Content-Type: text/plain Christopher Baines writes: > * gnu/packages/logging.scm (tailon)[arguments]: Patch commands.py to reference > grep, awk, sed and tail by absolute paths. Thanks for this! [...] > + (add-after 'install 'wrap-tailon-path > + (lambda* (#:key inputs outputs #:allow-other-keys) > + (let ((out (assoc-ref outputs "out"))) > + (substitute* (find-files out "commands.py") > + (("self\\.first_in_path\\('grep'\\)") > + (string-append"'" (which "grep") "'")) > + (("self\\.first_in_path\\('gawk', 'awk'\\)") > + (string-append"'" (which "gawk") "'")) > + (("self\\.first_in_path\\('gsed', 'sed'\\)") > + (string-append"'" (which "sed") "'")) > + (("self\\.first_in_path\\('gtail', 'tail'\\)") > + (string-append"'" (which "tail") "'"))) > + #t)))))) Is there any particular reason this phase runs after 'install'? I think we should try to avoid modifying files after they have been copied to the store, but if doing this substitution earlier is difficult I guess it's okay with a comment. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAlkZ0G4ACgkQoqBt8qM6 VPrDJwf9FbeXvpaba8qDRjZTl7G1Ko5JngZHMP/ZiD/x2kxZAqrnnDxIqiAWvFd0 YFFMmHmA6NvTGDTI4y8mwStjGHjLZdazEak2GvYQ4+pCsGngNdIFei2Z0+w62a54 jzx+P6hO8w2f0DAJSK/AhDL1tRCJz9h1l/Fq0eygDcWRdJP/sBEOgL3M+ZTGRl9Y qRLwm967p6mtSsm4F2GXFjeYRqRM/wK94jJcsfbLiEuL4LSA+W3wdmxkaBkJpHnt /q6Oh28RcaSouI27Tv0WIGa203V1RwSudA08Y2j/IT910eZGIoUabu7KGlgLhPc/ KrMIlMIOqTJnwM7eQui1Ao/nSMVryA== =LkGr -----END PGP SIGNATURE----- --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Tue May 16 15:40:06 2017 Received: (at 26770) by debbugs.gnu.org; 16 May 2017 19:40:06 +0000 Received: from localhost ([127.0.0.1]:49100 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dAiKE-0000JE-Ge for submit@debbugs.gnu.org; Tue, 16 May 2017 15:40:06 -0400 Received: from li622-129.members.linode.com ([212.71.249.129]:51949 helo=mira.cbaines.net) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dAiKC-0000J4-FX for 26770@debbugs.gnu.org; Tue, 16 May 2017 15:40:05 -0400 Received: by mira.cbaines.net (Postfix, from userid 113) id 9883C13E3B4; Tue, 16 May 2017 20:40:03 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from localhost (my83-216-88-20.cust.relish.net [83.216.88.20]) by mira.cbaines.net (Postfix) with ESMTPSA id BFE2213D066 for <26770@debbugs.gnu.org>; Tue, 16 May 2017 20:40:02 +0100 (BST) Received: from localhost.localdomain (localhost [127.0.0.1]) by localhost (OpenSMTPD) with ESMTP id 2909ce14 for <26770@debbugs.gnu.org>; Tue, 16 May 2017 19:40:01 +0000 (UTC) From: Christopher Baines To: 26770@debbugs.gnu.org Subject: [PATCH] gnu: tailon: Use absolute paths for commands. Date: Tue, 16 May 2017 20:40:01 +0100 Message-Id: <20170516194001.2591-1-mail@cbaines.net> X-Mailer: git-send-email 2.12.0 X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 26770 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) * gnu/packages/logging.scm (tailon)[arguments]: Patch commands.py to reference grep, awk, sed and tail by absolute paths. --- gnu/packages/logging.scm | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/gnu/packages/logging.scm b/gnu/packages/logging.scm index 2523d65f6..203279f33 100644 --- a/gnu/packages/logging.scm +++ b/gnu/packages/logging.scm @@ -109,6 +109,21 @@ command line.") `(("python-pyyaml" ,python-pyyaml) ("python-sockjs-tornado" ,python-sockjs-tornado) ("python-tornado" ,python-tornado))) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'unpack 'patch-commands.py + (lambda args + (substitute* (find-files "." "commands\\.py") + (("self\\.first_in_path\\('grep'\\)") + (string-append"'" (which "grep") "'")) + (("self\\.first_in_path\\('gawk', 'awk'\\)") + (string-append"'" (which "gawk") "'")) + (("self\\.first_in_path\\('gsed', 'sed'\\)") + (string-append"'" (which "sed") "'")) + (("self\\.first_in_path\\('gtail', 'tail'\\)") + (string-append"'" (which "tail") "'"))) + #t))))) (home-page "https://tailon.readthedocs.io/") (synopsis "Webapp for looking at and searching through log files") -- 2.12.0 From debbugs-submit-bounces@debbugs.gnu.org Tue May 16 15:49:38 2017 Received: (at 26770) by debbugs.gnu.org; 16 May 2017 19:49:38 +0000 Received: from localhost ([127.0.0.1]:49121 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dAiTR-0000Xo-U7 for submit@debbugs.gnu.org; Tue, 16 May 2017 15:49:38 -0400 Received: from li622-129.members.linode.com ([212.71.249.129]:51968 helo=mira.cbaines.net) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dAiTP-0000Xg-Sq for 26770@debbugs.gnu.org; Tue, 16 May 2017 15:49:36 -0400 Received: by mira.cbaines.net (Postfix, from userid 113) id 770B413E3B4; Tue, 16 May 2017 20:49:34 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from localhost (my83-216-88-20.cust.relish.net [83.216.88.20]) by mira.cbaines.net (Postfix) with ESMTPSA id B4B8213D066; Tue, 16 May 2017 20:49:33 +0100 (BST) Date: Tue, 16 May 2017 20:49:28 +0100 From: Christopher Baines To: Marius Bakke Subject: Re: bug#26770: [PATCH] gnu: tailon: Use absolute paths for commands. Message-ID: <20170516204928.4edd18b0@cbaines.net> In-Reply-To: <87o9uuf6vl.fsf@fastmail.com> References: <20170504064715.9779-1-mail@cbaines.net> <20170515061155.1380-1-mail@cbaines.net> <87o9uuf6vl.fsf@fastmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/OZV/ZXvZOVoUHmEFbyu.K+B"; protocol="application/pgp-signature" X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 26770 Cc: 26770@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) --Sig_/OZV/ZXvZOVoUHmEFbyu.K+B Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Mon, 15 May 2017 17:59:42 +0200 Marius Bakke wrote: > Christopher Baines writes: > > + (add-after 'install 'wrap-tailon-path > > + (lambda* (#:key inputs outputs > > #:allow-other-keys) > > + (let ((out (assoc-ref outputs "out"))) > > + (substitute* (find-files out "commands.py") > > + (("self\\.first_in_path\\('grep'\\)") > > + (string-append"'" (which "grep") "'")) > > + (("self\\.first_in_path\\('gawk', > > 'awk'\\)") > > + (string-append"'" (which "gawk") "'")) > > + (("self\\.first_in_path\\('gsed', > > 'sed'\\)") > > + (string-append"'" (which "sed") "'")) > > + (("self\\.first_in_path\\('gtail', > > 'tail'\\)") > > + (string-append"'" (which "tail") "'"))) > > + #t)))))) =20 >=20 > Is there any particular reason this phase runs after 'install'? I > think we should try to avoid modifying files after they have been > copied to the store, but if doing this substitution earlier is > difficult I guess it's okay with a comment. No, I just put it there by default, but I can see why doing the substitution earlier would be better. I've sent another patch that moves it to after the unpack phase.=20 --Sig_/OZV/ZXvZOVoUHmEFbyu.K+B Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEEPonu50WOcg2XVOCyXiijOwuE9XcFAlkbV8lfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcACgkQXiijOwuE 9Xc5ww//V2TnDL6epWFX1sj5AgxRl8EqU6J+VftD+t9k59kcJnKZr9dUExSnDxYy hWnfDjcTbTmiVHNfh0PNWHZw7dPwgXO6hj59+LcaSbAcMgjpjCZs0uXNRBPUlBjp SCrCBLKtXAU2A9CusefxYgn3Pyb301jblMCvR3zxykZd65hMoTyGm9oE62cqqiec UYp44F4BiFyG6BZKKWqKTunSLCLFfv2ZYzPnxPwjeMaVFWecTAPUnJFDvfLn4oLg cAlHVvPPHyBY9ZKioqzxwzYSMEz3yTZUAqWH0S7GUPZWoNPXrBViDU/NIYFUmUwm 2y65AdzdmmYgFRcsoKNe/hhNH+5U5gviEZaP/Rv1H2FCEI0FBqeHPQRKeMMJ0Rfm pAmogrgkLztTQjhEAj8XWVkaGYkHQrkvBdOSEdQIaax/dxKzGrZFx8EgBNl6mXpo jDLRaZ3ZKVHYuBsUze00gYhie7Kskdixekg7gsxVU4OMQ57eKX/P2WktK8LJF/HR McQKhrXmqNYT62Y/N6fldWQwBD0xhdeDlZp7NWJbEund5mNK53WezrKxHGQbqu8L GFDpfxrf1MA8OYmqFm+SIIf1KcW1lVDumGvm+bhYFO91ed5zBoDhR0JWcBhpD3xU 3Y3WDlRuIRuoB3iCFcVJ6VdKy2LBZbxJD95vFfzQpLHXhxRFcfQ= =TMdt -----END PGP SIGNATURE----- --Sig_/OZV/ZXvZOVoUHmEFbyu.K+B-- From debbugs-submit-bounces@debbugs.gnu.org Wed May 17 10:53:50 2017 Received: (at 26770-done) by debbugs.gnu.org; 17 May 2017 14:53:50 +0000 Received: from localhost ([127.0.0.1]:51022 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dB0Kj-0007N7-UC for submit@debbugs.gnu.org; Wed, 17 May 2017 10:53:50 -0400 Received: from out3-smtp.messagingengine.com ([66.111.4.27]:47523) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dB0Ki-0007N0-HQ for 26770-done@debbugs.gnu.org; Wed, 17 May 2017 10:53:49 -0400 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 0D0E120894; Wed, 17 May 2017 10:53:48 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute5.internal (MEProxy); Wed, 17 May 2017 10:53:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.com; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc :x-sasl-enc; s=fm1; bh=44Kiq4af1Bhzdm9KwW39ZgXYOQ7ZaubwcSGuv3whQ Bk=; b=KkHyf7IxwR/YX4nUy2Sk1+88+wZAOPlySxxekGnx3xDRI9YLCr74/RKKH 5nHkQmFGmoZD8NxkF/5k5Wi5mWenWJMjjaqCNaV6MRYiPOHiJMmZH0yWp+JGhe8q L1/vKMsx3/uEhhIDrLgQEOMIuECD3h4rSbIkPV6RsJ519z4z6RQ+WyCCot6KcjTV aWvxHYfk42t74/7dWiAc1nmm7WPceDLYo+OpOux52TLBZHs2wuGuZnuHolWCsJDg fRFd3v9PWQRUVeTDAbr94xfhZcTfdO9TTSx0nWRUS33CaT4qpZvUGFPorqV6WBx9 3yGSa492gxorDHA2zdcDExFkC/Scw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc:x-sasl-enc; s=fm1; bh=44Kiq4af1Bhzdm9KwW 39ZgXYOQ7ZaubwcSGuv3whQBk=; b=SB0A7LhLZ96q2ShD5rfpL0DO6gDW2cpcej 5e6BERYn4Rnyc5GW4AWPIYi79L/b8bsD90xaGdOTOP6d+vkK+nJwRTtwqdflJKi1 FlPR+Lq9tgdg/Wm4ULHHiF6crHZzvvk8iM8kfEwYbIJ6iqqWhXNUV9Yl7+xzXCgi 2mJd3I1pHC31mVM6/865ryzRfQ3UBVVsAFjcRgj889xgcaK697Aggt+EwQGjEND6 anyAvOTzTSk0NIXrBgUf3LjRNmRLIlVPqf9MeWq2C+F/gulRsDsWF4P0JUUHhk+F HHe+K7fKhaLiBv6nXUphaoIo2m/OioMUTcbhPMhHayoZUJOZ5KeQ== X-ME-Sender: X-Sasl-enc: Gb2ri1XU0KZF7k2OIoo6SDtLw8hAVNraHsGMypmoMovq 1495032827 Received: from localhost (unknown [188.113.81.93]) by mail.messagingengine.com (Postfix) with ESMTPA id 953902418C; Wed, 17 May 2017 10:53:47 -0400 (EDT) From: Marius Bakke To: Christopher Baines Subject: Re: bug#26770: [PATCH] gnu: tailon: Use absolute paths for commands. In-Reply-To: <20170516204928.4edd18b0@cbaines.net> References: <20170504064715.9779-1-mail@cbaines.net> <20170515061155.1380-1-mail@cbaines.net> <87o9uuf6vl.fsf@fastmail.com> <20170516204928.4edd18b0@cbaines.net> User-Agent: Notmuch/0.24.1 (https://notmuchmail.org) Emacs/25.2.1 (x86_64-unknown-linux-gnu) Date: Wed, 17 May 2017 16:53:45 +0200 Message-ID: <87o9urcz5y.fsf@fastmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 26770-done Cc: 26770-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Christopher Baines writes: > On Mon, 15 May 2017 17:59:42 +0200 > Marius Bakke wrote: > >> Christopher Baines writes: >> > + (add-after 'install 'wrap-tailon-path >> > + (lambda* (#:key inputs outputs >> > #:allow-other-keys) >> > + (let ((out (assoc-ref outputs "out"))) >> > + (substitute* (find-files out "commands.py") >> > + (("self\\.first_in_path\\('grep'\\)") >> > + (string-append"'" (which "grep") "'")) >> > + (("self\\.first_in_path\\('gawk', >> > 'awk'\\)") >> > + (string-append"'" (which "gawk") "'")) >> > + (("self\\.first_in_path\\('gsed', >> > 'sed'\\)") >> > + (string-append"'" (which "sed") "'")) >> > + (("self\\.first_in_path\\('gtail', >> > 'tail'\\)") >> > + (string-append"'" (which "tail") "'"))) >> > + #t))))))=20=20 >>=20 >> Is there any particular reason this phase runs after 'install'? I >> think we should try to avoid modifying files after they have been >> copied to the store, but if doing this substitution earlier is >> difficult I guess it's okay with a comment. > > No, I just put it there by default, but I can see why doing the > substitution earlier would be better. I've sent another patch that > moves it to after the unpack phase.=20 Applied, thank you! My rationale was that the store may be on slow storage (say NFS), whereas the build directory is probably a tmpfs or local storage. Note: I replaced the "find-files" invocation with just the one file path. Hope that was okay! --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAlkcY/oACgkQoqBt8qM6 VPrE5ggAtbFqLbfMa9DfAlwJ9n9TJEcr+Te5BbtbzqS5d56kz4nKKuPjaD14uFYx qi7i+BPLeRZFaYy5vt9WNgrNo7g71rKrNlAGW4P2McG16dmHzOF3JuR+Bakhn1Jo bSwWdopczfa+dEFMDImMD6TZ+pFDCHIJ7eDok/TIVc1A43Blj/1CtZ8fsyMvljcn 6KJV97OgzkXfWTHdx/h5DPhjEMzJBiAt9ISKLsLX8/mFRK7iYvvlpg/DS8xvP6uB xUU7vr6RpupESWPlfd4HFQyG9KChcOj3X5gw0+p2CFW723qdZDMuFQ7O02h9lqUa WknpMgAGbp9dBYaPabY32gzxKS81nA== =txVo -----END PGP SIGNATURE----- --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu May 18 14:50:06 2017 Received: (at 26770-done) by debbugs.gnu.org; 18 May 2017 18:50:06 +0000 Received: from localhost ([127.0.0.1]:53798 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dBQUw-0000AX-JP for submit@debbugs.gnu.org; Thu, 18 May 2017 14:50:06 -0400 Received: from li622-129.members.linode.com ([212.71.249.129]:46467 helo=mira.cbaines.net) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dBQUv-0000AP-6z for 26770-done@debbugs.gnu.org; Thu, 18 May 2017 14:50:05 -0400 Received: by mira.cbaines.net (Postfix, from userid 113) id A89C2140762; Thu, 18 May 2017 19:50:04 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from [192.168.15.219] (my83-216-88-20.cust.relish.net [83.216.88.20]) by mira.cbaines.net (Postfix) with ESMTPSA id 71AF5140760; Thu, 18 May 2017 19:50:03 +0100 (BST) Subject: Re: bug#26770: [PATCH] gnu: tailon: Use absolute paths for commands. To: Marius Bakke References: <20170504064715.9779-1-mail@cbaines.net> <20170515061155.1380-1-mail@cbaines.net> <87o9uuf6vl.fsf@fastmail.com> <20170516204928.4edd18b0@cbaines.net> <87o9urcz5y.fsf@fastmail.com> From: Christopher Baines Message-ID: Date: Thu, 18 May 2017 19:50:02 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <87o9urcz5y.fsf@fastmail.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="l6TCBPeVrQERMOxucjePGpD2PaK6Mw297" X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 26770-done Cc: 26770-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --l6TCBPeVrQERMOxucjePGpD2PaK6Mw297 Content-Type: multipart/mixed; boundary="NjNA1OLtREqhTJtcujtXHQHefkmaQpKP9"; protected-headers="v1" From: Christopher Baines To: Marius Bakke Cc: 26770-done@debbugs.gnu.org Message-ID: Subject: Re: bug#26770: [PATCH] gnu: tailon: Use absolute paths for commands. References: <20170504064715.9779-1-mail@cbaines.net> <20170515061155.1380-1-mail@cbaines.net> <87o9uuf6vl.fsf@fastmail.com> <20170516204928.4edd18b0@cbaines.net> <87o9urcz5y.fsf@fastmail.com> In-Reply-To: <87o9urcz5y.fsf@fastmail.com> --NjNA1OLtREqhTJtcujtXHQHefkmaQpKP9 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 17/05/17 15:53, Marius Bakke wrote: > Christopher Baines writes: >=20 >> On Mon, 15 May 2017 17:59:42 +0200 >> Marius Bakke wrote: >> >>> Christopher Baines writes: >>>> + (add-after 'install 'wrap-tailon-path >>>> + (lambda* (#:key inputs outputs >>>> #:allow-other-keys) >>>> + (let ((out (assoc-ref outputs "out"))) >>>> + (substitute* (find-files out "commands.py")= >>>> + (("self\\.first_in_path\\('grep'\\)") >>>> + (string-append"'" (which "grep") "'")) >>>> + (("self\\.first_in_path\\('gawk', >>>> 'awk'\\)") >>>> + (string-append"'" (which "gawk") "'")) >>>> + (("self\\.first_in_path\\('gsed', >>>> 'sed'\\)") >>>> + (string-append"'" (which "sed") "'")) >>>> + (("self\\.first_in_path\\('gtail', >>>> 'tail'\\)") >>>> + (string-append"'" (which "tail") "'"))) >>>> + #t)))))) =20 >>> >>> Is there any particular reason this phase runs after 'install'? I >>> think we should try to avoid modifying files after they have been >>> copied to the store, but if doing this substitution earlier is >>> difficult I guess it's okay with a comment. >> >> No, I just put it there by default, but I can see why doing the >> substitution earlier would be better. I've sent another patch that >> moves it to after the unpack phase.=20 >=20 > Applied, thank you! My rationale was that the store may be on slow > storage (say NFS), whereas the build directory is probably a tmpfs > or local storage. >=20 > Note: I replaced the "find-files" invocation with just the one file > path. Hope that was okay! Yep, looks good. Thanks for your review :) --NjNA1OLtREqhTJtcujtXHQHefkmaQpKP9-- --l6TCBPeVrQERMOxucjePGpD2PaK6Mw297 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQJFBAEBCAAvFiEEPonu50WOcg2XVOCyXiijOwuE9XcFAlkd7NoRHG1haWxAY2Jh aW5lcy5uZXQACgkQXiijOwuE9XdX9A//crfXkO2ZmF138csKW+Q6kRuIrjIMZ7dV 8VlmpRnfee3ZeIUq6yXVxMihzwe9xbXkfdnx2C/3cFz1e0p/LRxBM5swtBCWKxlY AtPgXVm7hJ6zmodQvDR7IMnOwydJFYIdqsMjlcpFToFEMngxxJXgubSulTdiTXlh ixbDpO5iT96nJ1PnWb6p6RFFQr0zs8FI97SMYDQM3ZoaIyCmGdzo+uousCMo4VD0 Q+NtAPn0q8jtEYSkhvHgYYPfupwEikTP2hxr86KiofHrj+qcy02HBN7uFJhqVgtA Dymma3lLhGLSxKP+6QGBX0pE8SHAlpkR25NwYMy/fdznnXIpsfWzGg3EyHUz7Mk2 7KaxCq294TVOsWkgqceEZksFm44a0KXN27u2BBF3SKb/PQ1dozEuRo1rifozywNm 0tBWg0CMwBZ2mWtpff3Z3PIHO1+F3GmXbCMUxbUI1Cd2rw3bn1RxCaI1SFCAwReT mW90k3VakQQMT9rE4Skhhx9qr55q5/mG3ShXBDf9IW07ugsnLVhSrmn4zTHCkNZy xBvY9sau+Wb+qf1qRiYm1/R4dSDcGYXB1WdLQV8GBcdw3+qM9lKk9rL9eX/+wF7e y6ojlc/GtTTvq3+lCjcFW+71NX2twUOkN+F/MtypLMpHKV11RCvHQPhTLV3dT6EW aEodgzoe+vA= =UgZP -----END PGP SIGNATURE----- --l6TCBPeVrQERMOxucjePGpD2PaK6Mw297-- From unknown Sun Sep 21 00:08:05 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 16 Jun 2017 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator