[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to do initialization specific to guix repl inside .guile?
From: |
Tomas Volf |
Subject: |
Re: How to do initialization specific to guix repl inside .guile? |
Date: |
Sat, 9 Mar 2024 15:30:38 +0100 |
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<br>
> > so that I can branch on that?<br>
>
> 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.
signature.asc
Description: PGP signature