From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id qE7zGrdy7GWL5wAAqHPOHw:P1 (envelope-from ) for ; Sat, 09 Mar 2024 15:31:19 +0100 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id qE7zGrdy7GWL5wAAqHPOHw (envelope-from ) for ; Sat, 09 Mar 2024 15:31:19 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=wolfsden.cz header.s=mail header.b=KkhTi8HP; dkim=pass header.d=wolfsden.cz header.s=mail header.b=n0Zs5U7i; dmarc=pass (policy=none) header.from=wolfsden.cz; 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=1709994679; a=rsa-sha256; cv=none; b=o1oaAoXbaFS+wkyVrBhSHR/K3jcJX4HIETTuKHUSoDASVBt5c/QMzaVATatsfHP5kx1S1C cS5ZQs8yJk1Vq542E9TIXR/EvOep0ZkeJ9BjQyoGe0xoIksD8/V/sldElnDswyTCpypoI1 4EdPlqlYHDLhh84ed35h2YUGGHBP8OjrFx12t47v9lx747UgVe8NF10fZJDSL1BqWHQSwj bRGe+skDml3imG3Rc9Q9L1YGVtWouuAoTkhGks+RbCXICJrzK4AELiCnOw7C6hW7PDzO6t q8ENlnNMf0ze+SFzjppBv1lpL4B9YFygkYLVPrBhfGYyxMMbjRnJfP3uUiTrWA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=wolfsden.cz header.s=mail header.b=KkhTi8HP; dkim=pass header.d=wolfsden.cz header.s=mail header.b=n0Zs5U7i; dmarc=pass (policy=none) header.from=wolfsden.cz; 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-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1709994679; 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:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=uS4FKnjCop6R+02AhJcGkLfyP7WRQhmhjj7DtGKgQDQ=; b=rWnKQT7hXwzEM0k8MakEGDKzwUHiwZ5zSEGhi1xi3JgqkO1G9ljNlpETuR32fYhBQs+UJX mYJmRRKoAuaENu3wn9i4l5h4hYSrrOIrKCHE2bXwCGuxyruyTwejyz4P9s5ZGRtQ0gkD/K eSHeVivT5x3UU/vpa32SRNLHC+d+cNTyGGAGQT7KbqAC2gv/fLj4YIjkmLnPpuFXwO6XYk Wo5SLoECJP3ER68VlqTqzDhcbc6S9BmZy17j+EQ39iXrLitbMiGVZfcKcuAVT8Rn+kkGjG ozpls80Pal8jHD7wRmCVnaA0oEyFQJ/3tzqAs2Kg/iqyBiV0/p8YrdCB2w1RRQ== 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 4CB066DC80 for ; Sat, 9 Mar 2024 15:31:19 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rixio-0003VT-Vv; Sat, 09 Mar 2024 09:30:47 -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 <~@wolfsden.cz>) id 1rixin-0003V6-P4 for help-guix@gnu.org; Sat, 09 Mar 2024 09:30:45 -0500 Received: from wolfsden.cz ([37.205.8.62]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <~@wolfsden.cz>) id 1rixil-0005cM-N7 for help-guix@gnu.org; Sat, 09 Mar 2024 09:30:45 -0500 Received: by wolfsden.cz (Postfix, from userid 104) id A6C002885BE; Sat, 9 Mar 2024 14:30:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1709994639; bh=wOczcWmVX26/UlO9LBao9NPNCnFhfl86E7LMo/zSm2g=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=KkhTi8HPPPwTpswwusmMJ076Lei6npu/+4JG4QqpmNeNz7pGXiYc4TblmXhJrW5yZ ogPbF8Mooq/tV3QPU3NIgFM3G2dUs/fWIbNK7Bf2K+6bdl8ri8YhSFXRyGSoG+BCQb XG8T1yTKGeBcreWx13ldxCXxaRJ0cqXSypEuxcvM8oyFl4lZBFyWsN2Z7HrzDZ18N8 P1TZQHbZ1OJKeaeV+KGRhKoroL16GlxdczZgZc+omL7YKr5tmp5q+FFaqf7quHogKe etox1Kwx0Qj30jv7ULkcfsR1cbrQ1IM3O25ZlZ0n61mEIbLV0I+LKZkpOvc5NLWNio luWquXByUJJ7PsYwvuE/rYJ42wQQ8iuIB/wwr0kezcDD7chzT2Lhc8cTTx2+seYYOr FiiXDN1qg5CdTRYZpl7YE7jHbfoWjIqs8N2qJ+8NIHyqlrKZ57eTkKp1whRiZh4cls wprwGMWCH8QR+iDlf+P2yc0kFJVJJBQwaQemRn9I5MVWrrqVylikYIbAz7q11mgXAP mctjtxyGSfKJD3b5hfDGCfv95s8eVqvJsjfuKDjkfl+I88hyefPbzOn48/QQzatI4R dJ/dzSZnX67UPLyWa1sEZqwy+YBYRlqMObHWDu6VBswhU1vRjedTFwvWv5YqnSjkci Eq0DzCg6c6yShQXIDPllzddg= Received: from localhost (unknown [193.32.127.157]) by wolfsden.cz (Postfix) with ESMTPSA id C815A24F71A; Sat, 9 Mar 2024 14:30:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1709994638; bh=wOczcWmVX26/UlO9LBao9NPNCnFhfl86E7LMo/zSm2g=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=n0Zs5U7iEVTDvZNSNYVg4GuR9LQsAf45uod4jxeQerd5VlrVCYNu58q/uOqWSMQwO 5KM93gGQlIz0aDCTyoYhADk5l/NVsYYBsaUh+2OFGJ6l+YcagulFNNY1kdBRu+lntN D+EJhXWmEbWFVf9yrlSOpph2wuaUUk5Q4k0OkaK/S+ZPoUxwSX0fvwpmoy7FTNsj2R /nQX8S92pGqHPPKHeejROZ6fR1ib8l0ueuYzBNe0WgVaEY27mv7fVSqvId8/0e3Qij U3r7Prt0shh9L60Zmur85Zzrmo2Wt0m0FS4t8/hLRRTRJxqeTazeOzDNIl5AYOmU2O vOMdda32NxGi/PNe3Op6EXcioEHYELlXGoKkvpw6uGkq3zIGQM2yapkFuLgz1Lqnyf 4sX4gO2+N+/8goB/huAQEz0dTggpm6Q0TV/hfsvKgBbyzUlIHGjIqZJzIrb8XqvZjD U7FZw/WNys3TPMgKdcJp8TSgeUBVuagE1vy/N0GkRFA3okHsLjUg0hhqv9aF8q+KQp Ch0eSmieIG/X2cYQYvQVI4+RqG4HaoM/vc/9MlmNn/JHoaPoBzZJWJJ77rVzkj4yKI dX5fdpbkwDMdFDzF2uvKs5ZoWEmPDewHfDKg7MLZD1Ghs0x2szkh+FCY1feOuxTDUo /BWw4xDlCalgJWGKnsUOZpO8= Date: Sat, 9 Mar 2024 15:30:38 +0100 From: Tomas Volf <~@wolfsden.cz> To: Parnikkapore Cc: help-guix@gnu.org Subject: Re: How to do initialization specific to guix repl inside .guile? Message-ID: Mail-Followup-To: Parnikkapore , help-guix@gnu.org References: <1050daeb5254a3fcbd3655db883e24e375cd5f70.camel@yahoo.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="ZheujupshMftYD3U" Content-Disposition: inline In-Reply-To: <1050daeb5254a3fcbd3655db883e24e375cd5f70.camel@yahoo.com> Received-SPF: pass client-ip=37.205.8.62; envelope-from=~@wolfsden.cz; helo=wolfsden.cz 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, 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-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Scanner: mx10.migadu.com X-Migadu-Spam-Score: -10.46 X-Spam-Score: -10.46 X-Migadu-Queue-Id: 4CB066DC80 X-TUID: ttQyHwRiyNAv --ZheujupshMftYD3U Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On 2024-03-09 00:45:32 +0700, Parnikkapore wrote: > Hi, > > On Wed, 2024-03-06 at 15:47 +0100, Tomas Volf wrote: > > Is there a way to detect from .guile whether guix repl or guile repl is starting
> > so that I can branch on that?
> > The kludge I currently use for this is this: > > ```scheme > (when (equal? (module-name (current-module)) '(guix-user)) > ; `guix repl`-only init code > ) > ``` Yes, that seems to work just fine, thank you very much :) T. -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors. --ZheujupshMftYD3U Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEt4NJs4wUfTYpiGikL7/ufbZ/wakFAmXsco4ACgkQL7/ufbZ/ walXuw/+NHhLJHi//ILzZwr+8NPH4pIHNqBVD2e2c0W/PXyJdXec9zZdS5bGhT6k IAd35ocHibHdzNgy3t1S4f7fHDu3orVLrbgyuVmWsh+yN8M8sxAn/ITvbE4rksaq c7X+omDVyk2Tm/B4KZGfi5qGOOiOWWSjLSoPjuYp202yTADwJm5TI9I9NH6gf6oT fj/pHnnB3Ymdyc7wiC4IGVVylp1vLwpYS86+Q7EBy9lj1ifgp8EAgA2yVoTiUAWa 1xW7vdDmKD9XHqRR6BHCUwMKynTs5YNzH8WplshWgpfdXaSdBHu9PZuXuONq0pez 3yLkydxtEXwRQDTbImGFNFKZLdDspu54BRGyO2gsbEF0jUVQNjh7Tr9Mn+/BxOwB /WGZ1A8Kvo5WZCDUKZsu+N/l33mFpQt4cciw3QOn4k9X3j38dTWfa5gPI7OUUCDi Xmnsd2mNu4VeQNQie8svaUuMveQ9f7XlokR6QJcElBkr5pE6BKRbASD8A0owUxI2 eiZJqk1BR0wyVpcRfZ6kIVGFcnVvQmsef5ONKsvO6nmCq17n/Vx9q1oM6/4XZ0O0 12GjfS3AfXn/LiC7umWEuETmfsVGPHPnRsBqCJCPiX3JwvPPEUEyGm2jmiT0+lrz HcXBWN2VXg6rzSQeCva/6php+Xbqx4zQCphs9qg2gTDCEWnstD8= =Kux/ -----END PGP SIGNATURE----- --ZheujupshMftYD3U--