From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.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 kGlYDf9q02MpSQAAbAwnHQ (envelope-from ) for ; Fri, 27 Jan 2023 07:11:11 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id IBZoDP9q02OXHwAAG6o9tA (envelope-from ) for ; Fri, 27 Jan 2023 07:11:11 +0100 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 C87BA37EFC for ; Fri, 27 Jan 2023 07:11:10 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pLHwW-0005H0-9o; Fri, 27 Jan 2023 01:10:32 -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 1pLHwU-0005GY-0G for help-guix@gnu.org; Fri, 27 Jan 2023 01:10:30 -0500 Received: from mx2.dismail.de ([159.69.191.136]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pLHwS-0004lM-1q for help-guix@gnu.org; Fri, 27 Jan 2023 01:10:29 -0500 Received: from mx2.dismail.de (localhost [127.0.0.1]) by mx2.dismail.de (OpenSMTPD) with ESMTP id 4085a951; Fri, 27 Jan 2023 07:10:23 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=dismail.de; h= mime-version:date:content-type:content-transfer-encoding:from :message-id:subject:to:in-reply-to:references; s=20190914; bh=hP MgU77jmG740u3tS7Y08rDiUFh1Xp9k4HrAr2mobVA=; b=sQawRCx3r1wXQs9Tsu aFSCe2EUOf4VYwc+x4Pcz3MMziIjo3BlozRx0nkxFLMJd4pb/UnL73bq0VSlpkiu wPkPd0tT9PQIHY3laN/EEZ7l92toKbHB1rvvYpDreHchzU/azK/X0R4YEsw6Nod1 9XXgvkgjuXGvc6PQQtNNrnznHPlJt89wDN12UvDJlLwWek9m5kweD3e0yEpXtHwi Egh0JTuZx8gWlPT4W8oULLAJcXHXKHxes26FfXGF24EB0ojYYgUoUNUvh9omZk02 5eSMabTlgPaD4s50OVnhuCSFSalYCDYfyUAVe0POcM5Ep8UqjztbcNWKmGzvM2BA IH+Q== Received: from smtp1.dismail.de ( [10.240.26.11]) by mx2.dismail.de (OpenSMTPD) with ESMTP id 12cbaed6; Fri, 27 Jan 2023 07:10:23 +0100 (CET) Received: from smtp1.dismail.de (localhost [127.0.0.1]) by smtp1.dismail.de (OpenSMTPD) with ESMTP id d072fe49; Fri, 27 Jan 2023 07:10:23 +0100 (CET) Received: by dismail.de (OpenSMTPD) with ESMTPSA id d63babb6 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Fri, 27 Jan 2023 07:10:23 +0100 (CET) MIME-Version: 1.0 Date: Fri, 27 Jan 2023 06:10:22 +0000 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Mailer: RainLoop/1.16.0a From: "jgart" Message-ID: Subject: Re: shebang for python script? To: "zimoun" , help-guix@gnu.org In-Reply-To: <86zga7554a.fsf@gmail.com> References: <86zga7554a.fsf@gmail.com> Received-SPF: pass client-ip=159.69.191.136; envelope-from=jgart@dismail.de; helo=mx2.dismail.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=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-bounces+larch=yhetil.org@gnu.org 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=1674799871; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=hPMgU77jmG740u3tS7Y08rDiUFh1Xp9k4HrAr2mobVA=; b=ZAPTpCbbsLGpRkPQsdcM9lhcTHhvicN6T0l89grW2/+NHxs8GhFVWM/VaU3Y8zW3u1WIWu +OsQ+vZM1i4+4nw+iadhMdLJue67X0m0KNclt9Q9XGz9W7Z0xzolLHmFVY6E5jto9srYeS m6rxrdllD3QzJXflGvdSIh3JyE+B5E/rmpIxDRMnlmYIkcwtZlaymXGz4gvKE1zMFgZnIV DwLjNk7gF2Xp9mFQH7Wy4ARqiZBhK8QFxtaFrde/lnsc0CzuTZPY3OXWHeLCBr7QfE/A2e oRdjvxJLoQEqUeYsgJVoTzJ13IM1cYAWN8NKdmqzH3lCe68w8oS70yIvAU2SBQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=dismail.de header.s=20190914 header.b=sQawRCx3; dmarc=pass (policy=reject) header.from=dismail.de; 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" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1674799871; a=rsa-sha256; cv=none; b=PbCPkldlkbL8+oGiTowejtU/THSHe8H8WOsJmx4sspwTmYflLjeEfFeA7+tZZ6WKvpjKIC cHWsvAT1S3xw0EUj31iF1E78+2gFsp4dYHseR1U2cHx8KP13uAulkZUV4a+KReI2fzT7Im beiGKHx5TZ9TTgJunr9a2taXzi0l5MkN1r7Mhzuvaw0rRy+pmiZHORvP0hlBKhDDZ2JOQe OLUx2iueOAkChYl62Fg1GFDGjF2ceBeb8PZ47fs5b+saAC1f1ys04TGAhON659bsUCF3wU iEuKaYDlaoP7yijcDV9zm5O0WY/SE+kcwS+7bHBn5F4PUeGUfXZi+s3mZFJvFg== Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=dismail.de header.s=20190914 header.b=sQawRCx3; dmarc=pass (policy=reject) header.from=dismail.de; 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-Scanner: scn0.migadu.com X-Migadu-Spam-Score: -6.84 X-Spam-Score: -6.84 X-Migadu-Queue-Id: C87BA37EFC X-TUID: 9tp81J/AUbIC Hi, thanks!!=20 Should=20we document this approach in the manual somewhere?=20 If=20so, where would be a good place to mention how to do this? > --8<---------------cut here---------------start------------->8--- > #!/usr/bin/env -S guix shell python -- python3 > import numpy as np > a =3D np.array([1,2]) > b =3D np.array([3,4]) > print(f"The dot product of {a} and {b} is: {np.dot(a, b)}") > --8<---------------cut here---------------end--------------->8--- >=20 >=20And to answer your other question about specific revision, I would do= : >=20 >=20--8<---------------cut here---------------start------------->8--- > #!/usr/bin/env -S guix time-machine --commit=3D29efa27 -- shell python = -- python3 > import numpy as np > a =3D np.array([1,2]) > b =3D np.array([3,4]) > print(f"The dot product of {a} and {b} is: {np.dot(a, b)}") > --8<---------------cut here---------------end--------------->8--- >=20 >=20Cheers, > simon