From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 0KylFHgbsF6OUQAA0tVLHw (envelope-from ) for ; Mon, 04 May 2020 13:41:12 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id WNXOF4IbsF6cCgAAB5/wlQ (envelope-from ) for ; Mon, 04 May 2020 13:41:22 +0000 Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:470:142::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 A882294462F for ; Mon, 4 May 2020 13:34:59 +0000 (UTC) Received: from localhost ([::1]:46142 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jVbFM-0001u9-1G for larch@yhetil.org; Mon, 04 May 2020 09:35:00 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37786) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jVbFC-0001sM-Ij for guix-devel@gnu.org; Mon, 04 May 2020 09:34:50 -0400 Received: from mail-qv1-xf41.google.com ([2607:f8b0:4864:20::f41]:41685) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jVbFB-0002ZG-6w; Mon, 04 May 2020 09:34:50 -0400 Received: by mail-qv1-xf41.google.com with SMTP id h6so8288501qvz.8; Mon, 04 May 2020 06:34:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=8Wk2UeEy22pB0IltyMWA0wBntFvrak7rkgaAFngAHH4=; b=EpyghrW6O9EpwAy70SGM5AVZ8btYDlOM3ZcehBUHQkg3RfJBAjDfg0iiu4PxT28+mL 647DUmQK3gV+Sslb14hScGi2PUFcZz/BuHsuTc9Rz1LU9zhqAcGNeRFykBeCQTqwsazx ZN+u/Zr/sMIJg+zBCKv5HzY3sem7aCB1as4JNpS2XvuTFbnInpyTQImAP6VDuS5LFr8e SAndxPGV4GmS950cqf5pwk0XuRWZNQZgDOtFTDCAhW0zypDC2E08MiAYdChbJxN9HvuG p4zFd9BXlA3jIBPuzlP9e3pUG50V5dOXTlRMrU0ryVVkJlvjerG/TOfzJZb8nvK5Wrg9 BvAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=8Wk2UeEy22pB0IltyMWA0wBntFvrak7rkgaAFngAHH4=; b=gmfvMgW9u80oREbY7viGmpkKfwQWsNfb9GiBiek1yxm6Ki1EMnFnPzpHlvUo5cNSkt by5g/spIu35HkkZoQ0I5efTa5ensD47PyRKpNGaCVNRBBktTEB6JUHBGEeOagpJpOOXt A6s9CzhN9bvemZDIEpf4ktEIpYxDv0Cs6PScXN1U2oaM6ZK3I6j9jn001Rzgg6fdRzCj gnCjGasSCnbi5aZ83qLOhz+RV3Ef3Xc0meRTfLA/pvxZLZqo6tR23kiigSpcNtD1aOk1 bEfoszIukzy49N0+PoGCuOZVKl5i8jprqtAW8KCyiaZfYxAo8EFUG3Jzb5f3zSTjo+VE qduw== X-Gm-Message-State: AGi0PuZWQI21V+c6NEKgFw1ee3IMPB7fD1/W97GAqOh1lTbNu9SXYdAW qrboZEJpTPufTDTSVmSueKNBlhWJT4yIgn8rncMudlMJ X-Google-Smtp-Source: APiQypKg74UnKfhIsOLhjEIGko6mYzjY4Asm8o/8o9hq8spo1X1vZ5laFpmiPUh3r77KesxdjpVcTHXaPunFwBrbkoM= X-Received: by 2002:ad4:5604:: with SMTP id ca4mr16606496qvb.6.1588599287797; Mon, 04 May 2020 06:34:47 -0700 (PDT) MIME-Version: 1.0 References: <490f77b9f9b0829f985ba717f6fbe008f54a816d.camel@gnu.org> <171c1dae752.b806970b21211.4448157853317564236@zoho.com> <87ftcgwyjq.fsf@gnu.org> In-Reply-To: <87ftcgwyjq.fsf@gnu.org> From: zimoun Date: Mon, 4 May 2020 15:34:36 +0200 Message-ID: Subject: Re: Adding a subcommand "load-profile" To: =?UTF-8?Q?Ludovic_Court=C3=A8s?= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2607:f8b0:4864:20::f41; envelope-from=zimon.toutoune@gmail.com; helo=mail-qv1-xf41.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: guix-devel Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Scanner: scn0 X-Spam-Score: 0.09 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=gmail.com header.s=20161025 header.b=EpyghrW6; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 2001:470:142::17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Scan-Result: default: False [0.09 / 13.00]; GENERIC_REPUTATION(0.00)[-0.49461436205316]; DWL_DNSWL_FAIL(0.00)[2001:470:142::17:server fail]; R_SPF_ALLOW(-0.20)[+ip6:2001:470:142::/48:c]; R_DKIM_REJECT(1.00)[gmail.com:s=20161025]; FREEMAIL_FROM(0.00)[gmail.com]; IP_REPUTATION_HAM(0.00)[asn: 22989(0.13), country: US(-0.00), ip: 2001:470:142::17(-0.49)]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[gmail.com:-]; RCPT_COUNT_TWO(0.00)[2]; MX_GOOD(-0.50)[cached: eggs.gnu.org]; MAILLIST(-0.20)[mailman]; FORGED_RECIPIENTS_MAILLIST(0.00)[]; RCVD_IN_DNSWL_FAIL(0.00)[2001:470:142::17:server fail]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:22989, ipnet:2001:470:142::/48, country:US]; TAGGED_FROM(0.00)[larch=yhetil.org]; FROM_NEQ_ENVFROM(0.00)[zimontoutoune@gmail.com,guix-devel-bounces@gnu.org]; ARC_NA(0.00)[]; RCVD_COUNT_FIVE(0.00)[5]; URIBL_BLOCKED(0.00)[gnu.org:email]; FROM_HAS_DN(0.00)[]; MIME_GOOD(-0.10)[text/plain]; HAS_LIST_UNSUB(-0.01)[]; FORGED_SENDER_MAILLIST(0.00)[]; DMARC_POLICY_SOFTFAIL(0.10)[gmail.com : SPF not aligned (relaxed),none] X-TUID: tyWXKPfNhkvk Hi Ludo, On Sun, 3 May 2020 at 22:31, Ludovic Court=C3=A8s wrote: > 1. guix environment (but it=E2=80=99s slower) > > 2. sh > . /my/profile/etc/profile.sh > exit Personally, time to time I use (thanks Pjotr): env -i $(which bash) --login --noprofile --norc . /my/profile/etc/profile exit because 'sh' is roughly bare and typing /my/long/path/to/profile without completion, history, move backward, etc. is not practical. Note: it is written in the Cookbook. Bottom of [1]. [1] https://guix.gnu.org/cookbook/en/html_node/Basic-setup-with-manifests.h= tml#Basic-setup-with-manifests > 3. sh > eval `guix package -p /my/profile --search-paths` > exit > > Options #2 and #3 are more verbose, and less obvious to someone not > familiar with the shell. > > Still, such commands are targeting shell users, which makes me wonder > how far we should go. It=E2=80=99s an honest question: I=E2=80=99m torn = between the > will to provide a simple CLI, and the need to avoid proliferation of > commands all more or less equivalent. Well, part of the subcommand "environment" could be done with "guix package -p" and then #3 but it is more more (more!) convenient to have a full subcommand: easy to use day-to-day and easy to explain, etc.. However, I am not in favour for adding another subcommands for only the use case of loading a profile. (Note that the point of Roel is legitimate: minimize the burden of their users already typing "guixr load-profile".) >From my point of view, instead of a subcommand, it should be an option: guix environment --load-profile or in short -P. And if another subcommand is added, it should be the more ambitious "profile manager", e.g., "guix profile", as it has been partly discussed, for examples in threads starting there: https://lists.gnu.org/archive/html/guix-devel/2019-10/msg00565.html https://lists.gnu.org/archive/html/guix-devel/2019-12/msg00358.html Last, I prefer another subcommand (load-profile) than nothing. Because it is requested since a long time. All the best, simon