From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id wMlLL7wz92C9fAAAgWs5BA (envelope-from ) for ; Tue, 20 Jul 2021 22:36:12 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id mFEJK7wz92BFWQAA1q6Kng (envelope-from ) for ; Tue, 20 Jul 2021 20:36:12 +0000 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 2C8D9187C2 for ; Tue, 20 Jul 2021 22:36:12 +0200 (CEST) Received: from localhost ([::1]:57450 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m5wTL-0004uW-41 for larch@yhetil.org; Tue, 20 Jul 2021 16:36:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36520) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m5wTC-0004rI-Aw for guix-patches@gnu.org; Tue, 20 Jul 2021 16:36:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:52176) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m5wTB-0000vK-Tz for guix-patches@gnu.org; Tue, 20 Jul 2021 16:36:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1m5wTB-0002Bs-RI for guix-patches@gnu.org; Tue, 20 Jul 2021 16:36:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#49456] [PATCH] gnu: add environment-modules Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 20 Jul 2021 20:36:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49456 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Ivan Gankevich Cc: 49456@debbugs.gnu.org Received: via spool by 49456-submit@debbugs.gnu.org id=B49456.16268133058348 (code B ref 49456); Tue, 20 Jul 2021 20:36:01 +0000 Received: (at 49456) by debbugs.gnu.org; 20 Jul 2021 20:35:05 +0000 Received: from localhost ([127.0.0.1]:35489 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5wSH-0002AZ-Bn for submit@debbugs.gnu.org; Tue, 20 Jul 2021 16:35:05 -0400 Received: from eggs.gnu.org ([209.51.188.92]:38540) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5wSF-0002A1-Gd for 49456@debbugs.gnu.org; Tue, 20 Jul 2021 16:35:04 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:57988) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m5wS9-0000Cy-GJ; Tue, 20 Jul 2021 16:34:57 -0400 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=45234 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m5wS9-0003QK-8T; Tue, 20 Jul 2021 16:34:57 -0400 From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <20210707085932.20751-1-i.gankevich@spbu.ru> Date: Tue, 20 Jul 2021 22:34:55 +0200 In-Reply-To: <20210707085932.20751-1-i.gankevich@spbu.ru> (Ivan Gankevich's message of "Wed, 7 Jul 2021 11:59:33 +0300") Message-ID: <87o8awk9lc.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1626813372; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: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; bh=5EFcGPK+iREJohGHPCZkXbvaud8u3LF0qagjT1gx44E=; b=e3m77Jt3G3AG4O8X7492zQ9vXl/peWjXeic17g5AbRhNGZ9Auir99yh8nNLxkt+A1m/6Z2 RvdXb8IoYaTh8KVsXLVOEGYU2MXxBgQIfkYjR1TGS/gGEwwrKy4Coe2Yu4JQNDQK3biH+C 8L/Wju9O8zyurdKZO/xNT2sWXZqCb3HBPh+EYO7dA4xYDqMFfCT6PCteCY2jbq0eBVssoa PMCeb3SHAzslKHZILSF2b3Rv49cBLIcHDwRc3+XhDlTxwaFON/HhasB82t00GGWjs1ph7N fHD8x7toZZMGvU/QTQRdDGnhqCW+SUk2ylmg8d2RZQaqGdVGeYh6ISObUHII6Q== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1626813372; a=rsa-sha256; cv=none; b=grUHVJlkIB3fNc2Hu4Z1RGAmPaMdAguu4fP9D6yMlJ/MW2o6tdxmjM3OosxU1GEDDoF8ob a4Gg0Jvn0WiyHlVQCD24XO8ibOIKnCYe7qZ5rRCM3llgSOhbl+95kb5TP1qv5ftmfWL4Uc MgUpP+01YisDfneudhSrgxlOdjQOgfq+uH2UPLyUU7rywWMIKQu4E46Mqt2N1i3unCm0zz dykrvz/qs521y8IjOSHGLVmq09KU1pvUkOKSoTG9G0ePT1bYY5z97UUA0w56wPBWRtNzzc XAuZEmH/88aBdohIl9ROqCoeyTfkleELYDx2wQlcNPGIMQYm7yjRY0RLyWn6aQ== 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 guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -2.92 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 2C8D9187C2 X-Spam-Score: -2.92 X-Migadu-Scanner: scn0.migadu.com X-TUID: bMi7S7f50vCz Hello, Nice! Overall LGTM, modulo cosmetic issues described below. Ivan Gankevich skribis: > +++ b/gnu/packages/parallel.scm How about =E2=80=98package-management.scm=E2=80=99 instead? You probably need to add a copyright line for you too. > +(define-public environment-modules > + (package > + (name "environment-modules") Should the package name be =E2=80=9Cmodules=E2=80=9D, since that=E2=80=99s = the name that upstream seems to be using? > + (add-before 'configure 'patch-scripts-for-python-3 > + (lambda _ > + ;; patch the script for python-3 Nitpick: please capitalize sentences and end with a period. > + (substitute* "script/createmodule.py.in" > + (("pathkeys.sort\\(\\)") "pathkeys =3D sorted(pathkeys)") > + (("print\\(\"\\\\t\"\\*") "print(\"\\t\"*int") > + (("@PYTHON@") (which "python3"))) > + #t)) You can omit the trailing #t (here and elsewhere). > + (add-after 'configure 'patch-/bin/sh-in-tests > + (lambda _ > + (for-each > + (lambda (file) > + (substitute* file > + (("/bin/sh") (which "bash")) > + ;; For some reason "kvm" group cannot be resolved for > + ;; "nixbld" user. We remove "-n" switch here to not > + ;; resolve the groups at all. > + (("exec id -G -n -z") "exec id -G -z") > + (("exec id -G -n") "exec id -G") Is this change made for tests? In the build environment, the build user is potentially in the =E2=80=9Ckvm=E2=80=9D group if it exists, but indeed,= /etc/group lacks =E2=80=9Ckvm=E2=80=9D (see nix/libstore/build.cc:1777). Should a post-check phase reinstate =E2=80=98-n=E2=80=99? > + )) Consider moving the parents on the previous line, as =E2=80=98guix lint=E2= =80=99 suggests. :-) > + (synopsis "Shell environment variables and aliases management") > + (description "A tool that simplify shell initialization and lets use= rs > +easily modify their environment during the session with modulefiles.") Please write full sentences for the description. Could you send an updated patch? Bonus points if you can provide a commit log that follows our conventions. :-) https://guix.gnu.org/manual/en/html_node/Submitting-Patches.html Thanks! Ludo=E2=80=99.