From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id 8KsUHVBRPGPJIwAAbAwnHQ (envelope-from ) for ; Tue, 04 Oct 2022 17:29:20 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id 2GA2HVBRPGMjWAAA9RJhRA (envelope-from ) for ; Tue, 04 Oct 2022 17:29:20 +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 2A089328B6 for ; Tue, 4 Oct 2022 17:29:20 +0200 (CEST) Received: from localhost ([::1]:60436 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ofjrD-00061Y-AO for larch@yhetil.org; Tue, 04 Oct 2022 11:29:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36824) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ofj4A-0003TT-So for help-guix@gnu.org; Tue, 04 Oct 2022 10:38:38 -0400 Received: from smtp.polymtl.ca ([132.207.4.11]:60996) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ofj48-0006Ks-3z for help-guix@gnu.org; Tue, 04 Oct 2022 10:38:37 -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 294EcNLI028198; Tue, 4 Oct 2022 10:38:27 -0400 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp.polymtl.ca 294EcNLI028198 To: jordi , help-guix@gnu.org Subject: Re: bash scripts in Guix question In-Reply-To: References: Date: Tue, 04 Oct 2022 10:38:23 -0400 Message-ID: <871qrnk61s.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 Tue, 4 Oct 2022 14:38:23 +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 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-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1664897360; 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:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=kOcKofDVaYGDOym2z2+wKLtNrfFRae5DayIUlEv5rw8=; b=CgacHLMeyTMqncPIxo2Hv7skUvhUbTVEPduBNTVRbUVbBVZP4oPcQKu2wGkLFWmiRPqf6K WOOx7LRR4YLjUyblDRpC+L/NQSGTNoyMqH+Npjz0RC9zkwH+OqQb26diEtfq8gQLmtJQhl /E4K9EbBhEllsEKEbRMsZYUxu04vi+Da28uibEv+4XwKWXcr3q6W+yy/+fgTRvMaaEigBf ynEtjRPo9y6+r79JhWNpVpYK9B9Lj9zN+t8oBY2Id5xLusZZxfEmnwdrmFA6yitnXgrHWd A+1rwE1woyc+v5R+gNbVYi36izw/0Og35UvgxFuQYBtuQBJsvzVdYiaVX4WOcQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1664897360; a=rsa-sha256; cv=none; b=FYwMBr14gqlxcrvpjHWedIXda4nUvy/VyJZlRzQZH4z9Q71cNCCiD1+5qJZA1Y52l+KrFU PFR80wq7rh55S/dW7mZRlo/qlyp0I7XrhFipIwteAOlw7YK/WqD1E6rPKS41vZSZnsFOM/ 4N2+ehi7t/MMI84QhuBidVMoTDT9skDuUXDuAf3J6X8E2g3UC5hkJFjrn2BMQyBjSXNpAW HtlAes/8Zi2Z5GY/1g6JfjWOgadcMaVmc+rJypQ2vRnRdbdkETOaIEg4AX7V9jynvHRXL/ Or6NW8j2V+4aWEv6GbFjjtqSHfp6gWlEwbZstyHPGOcu2Vaqbd3Z//YaJGNIZg== 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: -1.36 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: 2A089328B6 X-Spam-Score: -1.36 X-Migadu-Scanner: scn1.migadu.com X-TUID: jlScSrbIUrh7 On Tue, 04 Oct 2022, jordi wrote: > Hi guixers, > > i'm wondering...for my scripts to work in Guix, instead of > '#! /bin/bash' , > Typically the `sh' program should be a symlinked to `bash' in your system profile. I think it is the case for many distro. If you want it to be bulletproof though for other distros maybe something like that: --8<---------------cut here---------------start------------->8--- #!/bin/sh if [ "$(basename $SHELL)" != "bash" ]; then exec bash "$0" "$@" fi echo "hey!" --8<---------------cut here---------------end--------------->8--- -- Olivier Dion oldiob.dev