[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Emacs in multiple profiles
From: |
Alex Kost |
Subject: |
Re: Emacs in multiple profiles |
Date: |
Fri, 23 Mar 2018 20:25:25 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) |
Konrad Hinsen (2018-03-23 08:57 +0100) wrote:
> Hi Alex,
>
> Alex Kost <address@hidden> writes:
>
>>> Since nothing runs before site-start.el, I don't see how I could
>>> override this definition. My only choice is to use the -Q option on the
>>> Emacs command line to bypass site-start.el altogether. But then I don't
>>> get the packages from my new profile either.
>>
>> It's not the only choice. You can also use "--no-site-file". It is
>> also mentioned at:
>>
>> https://www.gnu.org/software/guix/manual/html_node/Application-Setup.html#Emacs-Packages
>
> Right, but that's not very different from -Q:
It is completely different: with "-Q", your .emacs file is not loaded at
all, and with "--no-site-file", only the emacs packages from the guix
profile are not autoloaded. Isn't that what you wanted?
> I get no start-site at all
> and thus none of the Guix-installed packages. What I am looking for is a
> way to get the packages that I put into the profile from which I started
> Emacs.
>
> I suspect that this could only be done via some environment variable,
> analogous $PATH and others. Emacs doesn't consult any such variable, and
> it seems that Guix didn't introduce one either. At least I didn't find
> any.
If you want to autoload emacs packages from a guix environment (or
similarly from any non-standard guix profile), you can do it like this:
(let ((guix-env (getenv "GUIX_ENVIRONMENT")))
(when (and guix-env
(require 'guix-emacs nil t))
(guix-emacs-autoload-packages guix-env)))
> Is this a decision made for a good reason, or just something "to be
> done"?
Sorry, I don't understand your use case (I think I just didn't read your
message carefully enough), but if you think there is something to be
done, please tell.
--
Alex