From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id OPZwLugBcGItWQAAbAwnHQ (envelope-from ) for ; Mon, 02 May 2022 18:08:08 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id uJiKLugBcGKKRgEA9RJhRA (envelope-from ) for ; Mon, 02 May 2022 18:08:08 +0200 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 5B426BD22 for ; Mon, 2 May 2022 18:08:08 +0200 (CEST) Received: from localhost ([::1]:53102 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nlYal-0002zK-8V for larch@yhetil.org; Mon, 02 May 2022 12:08:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41018) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nlYVy-00069f-3W for help-guix@gnu.org; Mon, 02 May 2022 12:03:10 -0400 Received: from smtp.polymtl.ca ([132.207.4.11]:40337) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nlYVv-0006DT-I2 for help-guix@gnu.org; Mon, 02 May 2022 12:03:08 -0400 Received: from localhost (modemcable094.169-200-24.mc.videotron.ca [24.200.169.94]) by smtp.polymtl.ca (8.14.7/8.14.7) with ESMTP id 242G31B8023959 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 2 May 2022 12:03:05 -0400 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp.polymtl.ca 242G31B8023959 To: help-guix@gnu.org Subject: Patch '/usr/bin/env -S' shebangs Date: Mon, 02 May 2022 12:03:01 -0400 Message-ID: <87mtfz2a8a.fsf@laura> MIME-Version: 1.0 Content-Type: text/plain X-Poly-FromMTA: (modemcable094.169-200-24.mc.videotron.ca [24.200.169.94]) at Mon, 2 May 2022 16:03:01 +0000 Received-SPF: pass client-ip=132.207.4.11; envelope-from=olivier.dion@polymtl.ca; helo=smtp.polymtl.ca X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: "Help-Guix" Reply-to: Olivier Dion From: Olivier Dion via X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1651507688; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=3jOq8Gkz3IzsmMwM9KbW0IywVxNIysdKSFl+wYSrEIk=; b=gTiuzhWceDhMyaoOu332+dTzWNT8DfWx1+E0agr8Ng4EIfpqhWHieN6SDaKsaf6CnYdAvT m6CPTr5fIw1WlN0wl8Q32bIrMrviseRZdUPbC2KyUdHTBtQMERdHyijaf/q57C1tmdybvx wuGuUmXZLKIQEfMGKQUQLdk+1qLVtQD07lDUqT4B1yG1v179QDoldHUsRqFDojErhKWbj7 oDyd12RKoLa/HNs/QJ3lOMY25iNpILc3Va4gaXJ/g/WI1H0+uHPDjR9ScFtlydZ0xXhqU6 j12plAsAImax3ZHoE003xcYJFag8sMTKT87lal/uvW/oPjLdBZw4kiCinuMstA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1651507688; a=rsa-sha256; cv=none; b=Li6SDNTOQAZ4DSjiZPY1W1DzACKvuJo11//3Q46R+GXrX7WmVH/WrzH/GmTgdbVcL6C3+N 9zPFMSi/0ojszcrS2BrRtjIIv/irMN0wImQO0aJ0N2Z1lHAulbReyM0r2AIoVPhroy5WlL ypnRhOlG+Unzg/3oIFx5i9/buM7Fgw6RVZEOUo9g2ev2gHUi4wmDgrzbOtHHCdOvuK0st9 cZ9a3yjQlGDOW6BcqguNyat/xugXcG+qxkQhPamQfNTvsyemDrZYbaQ8T5u2r0sB+LypFA L0a/Hi3je52prsUA6D858C3nsUtxhDOWlSSXdckpCQmX4vxIPBvXfmY2ZfjR/g== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -2.38 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 5B426BD22 X-Spam-Score: -2.38 X-Migadu-Scanner: scn0.migadu.com X-TUID: 334UBrv1KkiX Hi all, I have a couple of scripts -- that are not to be installed -- in my project. These scripts all have the following shebang: --8<---------------cut here---------------start------------->8--- #!/usr/bin/env -S guile --no-auto-compile -e main -s --8<---------------cut here---------------end--------------->8--- Apparently, Guix can not patch these shebangs on its own, so I added the following phase to my package's definition: --8<---------------cut here---------------start------------->8--- (add-after 'unpack 'more-patch-source-shebangs (lambda _ (substitute* '("pre-inst-env" "tools/run-tests" "tools/test-driver" "tools/compile-scheme") (("/usr/bin/env") (which "env"))))) --8<---------------cut here---------------end--------------->8--- I'm wondering if this is the good thing to do? Or maybe there's a more clean alternative? FYI, I added this phase before 'patch-source-shebangs to avoid errors. Regards, old -- Olivier Dion oldiob.dev