[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Profiles/manifests-related command line interface enhancements
From: |
Pierre Neidhardt |
Subject: |
Re: Profiles/manifests-related command line interface enhancements |
Date: |
Thu, 31 Oct 2019 12:38:22 +0100 |
> --8<---------------cut here---------------start------------->8---
> GUIX_PROFILE=/path/to/profile ; . $GUIX_PROFILE/etc/profile
> --8<---------------cut here---------------end--------------->8---
If we want to activate a profile in a subshell, it would be enough to
add a `--profile` argument to `guix environment`, wouldn't it?
--8<---------------cut here---------------start------------->8---
guix environment --profile=/path/to/profile
--8<---------------cut here---------------end--------------->8---
It's simpler and hides the implementation details.
Better: support _multiple profiles_ so that we can compose environments
more easily.
Regarding the shell functions to activate a profile: I think with the
above it would not be really useful beyond the ~/.bash_profile settings.
So documenting the required snippet for ~/.bash_profile would be enough.
I can think of just one case where `guix environment' does not work:
Emacs' Eshell. Here we could provide an Emacs function (maybe in
emacs-guix.el?) to load a profile. Note that every eshell has a
let-bound `process-environment`, so activating a profile in an Eshell
only affects the current Eshell.
Cheers!
--
Pierre Neidhardt
https://ambrevar.xyz/
signature.asc
Description: PGP signature
- Profiles/manifests-related command line interface enhancements, Pierre Neidhardt, 2019/10/23
- Re: Profiles/manifests-related command line interface enhancements, Mark H Weaver, 2019/10/24
- Re: Profiles/manifests-related command line interface enhancements, Pierre Neidhardt, 2019/10/24
- Re: Profiles/manifests-related command line interface enhancements, Pierre Neidhardt, 2019/10/24
- Re: Profiles/manifests-related command line interface enhancements, Danny Milosavljevic, 2019/10/24
- Re: Profiles/manifests-related command line interface enhancements, Pierre Neidhardt, 2019/10/24
- Re: Profiles/manifests-related command line interface enhancements, Mark H Weaver, 2019/10/24
- Re: Profiles/manifests-related command line interface enhancements, Pierre Neidhardt, 2019/10/24
- Re: Profiles/manifests-related command line interface enhancements, Mark H Weaver, 2019/10/24
- Re: Profiles/manifests-related command line interface enhancements, Pierre Neidhardt, 2019/10/25
- Re: Profiles/manifests-related command line interface enhancements,
Pierre Neidhardt <=