aboutsummaryrefslogtreecommitdiff
path: root/etc
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2024-04-25 15:55:54 -0300
committerEuAndreh <eu@euandre.org>2024-04-25 15:55:54 -0300
commit0b720343053dd0f67faa53698ebe748fbeddc6b3 (patch)
treecd6faedf9acf2c82405483f9f728079a33ea978e /etc
parentetc/sh/rc: export $TD_USE_BUILTIN_HOOKS (diff)
downloaddotfiles-0b720343053dd0f67faa53698ebe748fbeddc6b3.tar.gz
dotfiles-0b720343053dd0f67faa53698ebe748fbeddc6b3.tar.xz
Revert "Remove Nix/NixOS support from configuration and utilities"
This reverts commit 3b2d27457db9ef8911893fa1b843560f1ccab2eb.
Diffstat (limited to 'etc')
-rw-r--r--etc/guix/system.scm1
-rw-r--r--etc/sh/rc16
2 files changed, 16 insertions, 1 deletions
diff --git a/etc/guix/system.scm b/etc/guix/system.scm
index 9157a16..5fdd436 100644
--- a/etc/guix/system.scm
+++ b/etc/guix/system.scm
@@ -143,6 +143,7 @@ Seiko Epson Color Ink Jet Printers.")
(append
(map (compose list specification->package+output symbol->string)
'(nss-certs
+ nix
cups
ghc
ghc-xmonad-contrib
diff --git a/etc/sh/rc b/etc/sh/rc
index fd6da27..e5fb5e9 100644
--- a/etc/sh/rc
+++ b/etc/sh/rc
@@ -297,6 +297,20 @@ guix_env() {
printf ')'
}
+in_nix_shell() {
+ if [ -z "${IN_NIX_SHELL:-}" ]; then
+ return
+ fi
+
+ printf '\n'
+ color -c blacki '~> '
+ color -c purpleb "$IN_NIX_SHELL "
+ color -c purple 'nix-shell '
+ printf '('
+ color -c blueb "${name:-}"
+ printf ')'
+}
+
in_ssh_session() {
if [ -n "${SSH_CLIENT:-}" ]; then
color -c blackb '\\u'
@@ -323,7 +337,7 @@ vcs_status() {
fi
}
-PS1='`error_marker`'$(timestamp)' '$(path)'`direnv_status``makeflags_status` `shell_status``vcs_status``guix_env`
+PS1='`error_marker`'$(timestamp)' '$(path)'`direnv_status``makeflags_status` `shell_status``vcs_status``guix_env``in_nix_shell`
'$(in_ssh_session)'$ '
export PS1