From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:5f26::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id UXAjHUVrkmUREgEAkFu2QA (envelope-from ) for ; Mon, 01 Jan 2024 08:35:33 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id eJVLFUVrkmVdkgAAqHPOHw (envelope-from ) for ; Mon, 01 Jan 2024 08:35:33 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=trop.in header.s=key1 header.b=ADsYEDmG; 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=pass (policy=none) header.from=gnu.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1704094533; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc: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=cAnq/7DQRltLCZk/3EIEZ4BQZugXydUFCsxbd7oqARU=; b=HiJ7K8P/GqOkIzYt94Pbsyr5ItjHbQOwuL4vK/gEXn7V3zGhmY26CeUVpUHUayBiug3O5J c7NwHv0UiIPMels9GJdnroC2gtVowZvLs+8DbXEMmrOpMsvUJyQpwrK2xm+DLcybjpBe6b dING0QqCooBIgaxghHnMyUowaQz4B8mIbKnNgb2QHJHWbt135LzghhPjTN20ZG7DYvPvUu klsV8IBx616D/WJ2RDs2P1pZSvvIJabrTmOPLodVeoZAbMDOFGZpLgRuaUapOVbwp3lHt5 aurj7Te5x/T/qg2v8tx1kuNACwy3RSqF5i5LcOB8E76yERyFzkXsMeRCwe2x3Q== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=trop.in header.s=key1 header.b=ADsYEDmG; 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=pass (policy=none) header.from=gnu.org ARC-Seal: i=1; s=key1; d=yhetil.org; t=1704094533; a=rsa-sha256; cv=none; b=r/ZDkqVhWXgnEud0kV/iq3GOTqD2CaWBzkq33wAID2oryCb40N+u8x/knIT0IGjW1cfJ/z wm+FXcLrBSpoOBr3Hl1EBrV8EDscVwQAUPt124eL9+AiRHXJs5XW/rZODiyvJObSmEiJUd S9tQJQhKjrttBTw+zXxWqNxo/G7xZQuyCYYI4qJ7kR6vYMIRS5aiydmHfvKiw9XPHCMgML 0gTrTlwBQtersScEowpzJxXqxd3tnSOVC5ojMS9FBlfQigcmV8O3g2776unnFYifOch/6L 1SLx43tB2gzrQ/AM+LYcuFnM/kT54nU/RB4r/QEaf1Krd8f7oBb3++30KJGH2w== 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 D3A4541115 for ; Mon, 1 Jan 2024 08:35:32 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rKCpC-0003AW-Ce; Mon, 01 Jan 2024 02:35:02 -0500 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 1rKCpA-00039q-Eu for guix-patches@gnu.org; Mon, 01 Jan 2024 02:35:00 -0500 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 1rKCpA-0004mu-73 for guix-patches@gnu.org; Mon, 01 Jan 2024 02:35:00 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rKCpB-0007yl-QB for guix-patches@gnu.org; Mon, 01 Jan 2024 02:35:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#68180] [PATCH 1/4] gnu: emacs: Add awk, find, sed and sh to PATH wrapper. Resent-From: Andrew Tropin Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 01 Jan 2024 07:35:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68180 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxim Cournoyer , Liliana Marie Prikler Cc: 68180@debbugs.gnu.org, Katherine Cox-Buday Received: via spool by 68180-submit@debbugs.gnu.org id=B68180.170409445030604 (code B ref 68180); Mon, 01 Jan 2024 07:35:01 +0000 Received: (at 68180) by debbugs.gnu.org; 1 Jan 2024 07:34:10 +0000 Received: from localhost ([127.0.0.1]:47300 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rKCoL-0007xY-Qt for submit@debbugs.gnu.org; Mon, 01 Jan 2024 02:34:10 -0500 Received: from out-180.mta1.migadu.com ([95.215.58.180]:56329) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rKCoI-0007xL-Lg for 68180@debbugs.gnu.org; Mon, 01 Jan 2024 02:34:08 -0500 X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=trop.in; s=key1; t=1704094443; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=cAnq/7DQRltLCZk/3EIEZ4BQZugXydUFCsxbd7oqARU=; b=ADsYEDmGGCagmGMV0AfO4tli4mPNRwHcCGLSq+rFD6Ao888FfZDwjH39Rxmx5+npxsIaIc 6WkM3Ep5gJszZw6KxTer6kyw4cGF/scTuLBtTAKcAiVzy6rpdNCJzHaQroYwEiSKq8Oa2y ap7HzxdQGD3pZTzopEE3oA0FTjFaMPXxu32A4x1CbZ4PdrDyKviAmDAICIhG9GpUT8tyqY RDgCnPd7c+RIsNPwF0e+QYJYYBxIMV3fDT0Q9qMaj5kOyg2lJrYsBYn9Uo4Y5QdLZrlbIf HL4UbpTAoMy131NIb2rEo7FtolRhvVxP4wBA62X84ZtEVnFOy2JPKmek0s9q3w== In-Reply-To: <874jfyoz84.fsf@gmail.com> References: <6b33be06b0ea3a9aa4e29b8c8a958150cc05a7e9.camel@gmail.com> <874jfyoz84.fsf@gmail.com> Date: Mon, 01 Jan 2024 10:33:58 +0300 Message-ID: <87plyl4ie1.fsf@trop.in> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" 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: , Reply-to: Andrew Tropin X-ACL-Warn: , Andrew Tropin via Guix-patches From: Andrew Tropin via Guix-patches via Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Scanner: mx13.migadu.com X-Migadu-Spam-Score: -8.85 X-Spam-Score: -8.85 X-Migadu-Queue-Id: D3A4541115 X-TUID: ElADTgueuBNT --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 2023-12-31 16:10, Maxim Cournoyer wrote: > Hi Liliana, > > Liliana Marie Prikler writes: > >> Am Sonntag, dem 31.12.2023 um 11:59 -0500 schrieb Maxim Cournoyer: >>> Before this change, using Emacs in a pure environment, e.g. 'guix >>> shell --pure emacs', would cause problems such as: >>>=20 >>> =C2=A0 jka-compr-insert-file-contents: Uncompression program =E2=80=98s= h=E2=80=99 not >>> found >>>=20 >>> And other problems were found requiring the other tools.=C2=A0 While the >>> above could be patched in place for 'sh', it seems more robust and >>> universally useful to have the commands appear on PATH, should other >>> Elisp modules want to call to these directly as well. >>>=20 >>> * gnu/packages/emacs.scm (emacs-minimal) [arguments] : Adjust >>> the >>> wrap-emacs-paths phase to wrap additional inputs. >>> [inputs]: Add findutils, gawk and sed. >>> (%emacs-modules): Add (srfi srfi-26). >>>=20 >>> Change-Id: Ifb4fe2fc12ddc9eae387adb3da3f7821fab78e65 >>> --- >> We already have a phase to patch in the real path of /bin/sh where it's >> used. This appears to be an odd case that's missed. > > I appreciate exactness, but it seems fragile to rely on nobody adding > new references or someone catching them as new Emacs modules get added > or changed :-). > > My reasoning was that since Emacs already depends on bash, why not > ensure it'll always be found on PATH, by wrapping instead of > substituting. > > Does it make sense? Yep, make sense to me. I also find cases from time to time, when some binary or another isn't found by some elisp code. However, providing those binaries via PATH can make some code or programs to work, when executed from inside Emacs and not to work in the environment outside, which can be really confusing in some cases. A simple example, imaging we have a script: 1.sh, which contains: sh --version This one will work: guix shell emacs-with-bash --pure -- emacs --eval '(shell-command "./1.sh")' This one will not: guix shell emacs-with-bash --pure -- ./1.sh That said, the idea of patching all the pathes to binaries seems better to me. =2D-=20 Best regards, Andrew Tropin --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEKEGaxlA4dEDH6S/6IgjSCVjB3rAFAmWSauYACgkQIgjSCVjB 3rCcfg//Q21CIfl/c/5SO3P1TUmBa/vBGs0WRMpUKTjhAeRpyAfTBiTE2IbWWuT/ +CJ7oZCdkl9TsjGBwhs5EtOfJ+l5hlQPMJ1KP835kM41GJcVbZZv1atWyLiXfwtU 4tVpcW8b0wto6r2Nh7kGEjsSNmlVdUIvozJuqPl9upWNE2IEQA32XUfyjRspPv89 zv8/pvhelHmbf2V84kK1KGfPdI11b/9fYQ5hV+TyCYjsjCuBUA/lM8kIeImHlihl JJrU6mveMGgc/FFXn/EIEsBTT048NxJ/a2QfzTk9mOYQCqFlwoyNoUndinR1tScD AxK4u3p4cNQp2HmickXBikLceHkUfKlbaYoA6rUQ4fPjWWKvgEIi4Eyb5lNVKBIe PkObCAt9v/GXHp3FXd1fb6mnmG6PPi5tqyT4OKNwZJxQWGKX0svrmMh1t04vE8o3 xGBM8rpvP6Ubzr676l9lvqkomnxEQmPQZd2TFf88DSM48i9YgODdE/RDETVDN/Jl TbKgeW4TX8/xj4KA9KtWdtNBzo26gD7cI8xH0rmOA1nkLLoEE4K+0HmDqsUZoVJm NpsZLMn26yXm5CM4lz3FeKtP3JPLh/yIxJlaAwD4549nC5MpTUATjuj5Yy2VVfoF e0ee8lkEw+HtlcPdk9sOIculKNKeUQbERogV/htz6tA3I3yz6Mk= =4YS0 -----END PGP SIGNATURE----- --=-=-=--