unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: Maxime Devos <maximedevos@telenet.be>
To: Andrew Tropin <andrew@trop.in>, 56661@debbugs.gnu.org
Subject: bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate
Date: Wed, 20 Jul 2022 14:30:30 +0200	[thread overview]
Message-ID: <5e3f98c8-eeb1-909b-8407-ef55f01a6881@telenet.be> (raw)
In-Reply-To: <87v8rsoukp.fsf@trop.in>


[-- Attachment #1.1.1: Type: text/plain, Size: 3901 bytes --]


On 20-07-2022 14:08, Andrew Tropin wrote:
> Hi Maxime,
>
> According to the documentation to get all the environment variables set
> correctly you either need to manage your login shell with Guix Home or
> do additional configuration of your shell:
> https://guix.gnu.org/manual/devel/en/html_node/Configuring-the-Shell.html

I am not using a login shell, though I suppose there might be one under 
the hood somewhere (IIRC, and if it hasn't changed, some login managers 
are wrapped in Guix System to insert a bash --login in-between). Even if 
I am using a (non-login) shell, there's still an issue: if I start an 
application via the graphical things, they don't get all the environment 
variables (I tested this by opening a terminal that starts bash and 
doing "echo $EMACSLOADPATH", but that a shell is used for the test seems 
irrelevant here to me).

>  From what I see you manage bash with Guix Home,
I am not. I just keep the default ~/.bash_profile etc that a fresh Guix 
System install gave me and the only reason bash_profile things appear in 
the home configuration is because "guix home import" generated that. I'm 
not managing anything, just keeping the defaults.
> so according to the
> source code your bash_profile should look differently from what you've
> posted and must contain `source ~/.profile` in it:

~/.bash_profile does contain that line:

# Set up the system, user profile, and related variables.
# /etc/profile will be sourced by bash automatically
# Set up the home environment profile.
if [ -f ~/.profile ]; then source ~/.profile; fi

# Honor per-interactive-shell startup file
if [ -f ~/.bashrc ]; then source ~/.bashrc; fi
# Honor per-interactive-shell startup file
if [ -f ~/.bashrc ]; then . ~/.bashrc; fi

However, .bash_profile (the one from the local-file) does not:

# Honor per-interactive-shell startup file
if [ -f ~/.bashrc ]; then . ~/.bashrc; fi


> https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/home/services/shells.scm#n440
>
> This line makes your login shell

I am not using a login shell but a graphical environment -- the only 
reason I actually use a shell at all is because I find it more 
convenient to open a terminal and type "emacs" than to look in the 
graphical desktop thingy for the Emacs icon. Also, I'm not finding Emacs 
here even though in the previous installation of Guix System (GDM + Mate 
IIRC, without Guix Home but with "guix install ...".  Icedove isn't 
appearing there either, though the browser is.

I recall that it login shells were not necessary on Guix System + 
~/.guix-profile (without Guix Home), at least for the desktop 
environment combination I used back then, though it was required on my 
Debian system to do "bash --login".  I can do "bash --login" on my Guix 
System + Guix Home setup to start a login shell, but that would be a 
regression.

>   source .profile, which sources
> setup-environment, which sources ~/.guix-home/profile/etc/profile, which
> sets EMACSLOADPATH.
>
> Additionally, I've built the home environment you provided and it
> contains the code I mentioned above.
>
> Make sure that ~/.bash_profile and ~/.guix-home/files/.bash_profile
> point to the same file in the store.

antipode@antipode ~$ ls -l .bash_profile
lrwxrwxrwx 1 antipode users 56 19 jul 22:14 .bash_profile -> 
/gnu/store/1cq87qf8zccxlnkjwifcyhawmxvy7wfw-bash_profile

antipode@antipode ~$ ls -l ~/.guix-home/files/.bash_profile
lrwxrwxrwx 1 root root 56  1 jan  1970 
/home/antipode/.guix-home/files/.bash_profile -> 
/gnu/store/1cq87qf8zccxlnkjwifcyhawmxvy7wfw-bash_profile

They do.  Also, shouldn't ~/.bash_profile point to 
~/.guix-home/files/.bash_profile instead of directly to the store, to be 
more atomic (unrelated to #56661 though), like done for symlinks in /etc 
in Guix System?

Greetings,
Maxime.


[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 929 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 236 bytes --]

  reply	other threads:[~2022-07-20 12:31 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-20 10:45 bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate Maxime Devos
2022-07-20 10:59 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos
2022-07-20 12:08 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Andrew Tropin
2022-07-20 12:30   ` Maxime Devos [this message]
2022-07-20 17:47     ` Andrew Tropin
2022-07-22  9:28       ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos
2022-07-22 10:17         ` Maxime Devos
2022-07-22  9:32       ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Maxime Devos
2022-07-22 13:03         ` Andrew Tropin
2022-07-22 13:13           ` bug#56661: SDDM does not do the equivalent of 'login shell --login', unlike other login managers Maxime Devos
2022-07-22 10:24 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Maxime Devos
2022-07-22 10:44   ` Maxime Devos
2022-07-22 11:00     ` bug#56661: SDDM does not do the equivalent of 'login shell --login', unlike other login managers Maxime Devos
2022-07-22 13:15     ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Andrew Tropin
2022-07-30 11:16 ` bug#56661: [PATCH] build-self: Try printing nicer error messages Maxime Devos
2022-07-30 11:17   ` Maxime Devos

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5e3f98c8-eeb1-909b-8407-ef55f01a6881@telenet.be \
    --to=maximedevos@telenet.be \
    --cc=56661@debbugs.gnu.org \
    --cc=andrew@trop.in \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).