all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Chris Marusich <cmmarusich@gmail.com>
To: help-guix@gnu.org
Subject: "The following environment variable definitions may be needed"
Date: Tue, 09 May 2017 22:53:06 -0700	[thread overview]
Message-ID: <87lgq5p8al.fsf@gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 1995 bytes --]

Hi,

Sometimes, when you install a package, you get a message like this:

--8<---------------cut here---------------start------------->8---
[0] marusich@garuda:/tmp
$ guix package -p test-profile -i guile
The following package will be installed:
   guile	2.2.2	/gnu/store/5zx29y44nrqj0s8h3jlvlj82k8hj4dxs-guile-2.2.2

1 package in profile
The following environment variable definitions may be needed:
   export PATH="test-profile/bin${PATH:+:}$PATH"
[0] marusich@garuda:/tmp
$ 
--8<---------------cut here---------------end--------------->8---

Up until now, I've always added the recommended export statements to my
~/.bashrc or ~/.bash_profile.  I (mistakenly?) assumed that's what the
message was really telling me to do.  However, I've just learned that
these recommended variables also appear to get exported in
$GUIX_PROFILE/etc/profile, which is automatically sourced by
/etc/profile on GuixSD.  Even on a foreign distro,
$GUIX_PROFILE/etc/profile is automatically sourced if one follows the
guidance in the manual ((guix) Binary Installation):

--8<---------------cut here---------------start------------->8---
     Source ‘etc/profile’ to augment ‘PATH’ and other relevant
     environment variables:

          # GUIX_PROFILE=$HOME/.guix-profile \
            source $GUIX_PROFILE/etc/profile
--8<---------------cut here---------------end--------------->8---

This leads to my question: If I'm using GuixSD (or a foreign distro in
which $GUIX_PROFILE/etc/profile is automatically sourced), do I need to
add these recommended export statements to my ~/.bashrc or
~/.bash_profile?

My suspicion is that the answer is "no".  The next time I reboot or log
out and back in, the environment variables will be set correctly even if
I don't add them to my ~/.bashrc or ~/.bash_profile.  In fact, by adding
them there, I would be adding redundant entries.  I am hoping that
someone can confirm that my understanding is correct.

-- 
Chris

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

             reply	other threads:[~2017-05-10  5:53 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-10  5:53 Chris Marusich [this message]
2017-05-10  9:19 ` "The following environment variable definitions may be needed" ng0
2017-05-10 12:01 ` Ludovic Courtès
2017-05-10 13:39   ` myglc2
2017-05-10 21:49     ` Niall Dooley
2017-05-11  8:55       ` Ludovic Courtès
2017-05-11 19:55         ` Niall Dooley

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

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

  git send-email \
    --in-reply-to=87lgq5p8al.fsf@gmail.com \
    --to=cmmarusich@gmail.com \
    --cc=help-guix@gnu.org \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.