aboutsummaryrefslogtreecommitdiffhomepage
path: root/files/.profile
diff options
context:
space:
mode:
Diffstat (limited to 'files/.profile')
-rwxr-xr-xfiles/.profile14
1 files changed, 14 insertions, 0 deletions
diff --git a/files/.profile b/files/.profile
new file mode 100755
index 0000000..68b4473
--- /dev/null
+++ b/files/.profile
@@ -0,0 +1,14 @@
1#!/usr/bin/env bash
2
3# Copy initial saved nix context if the /nix is empty
4[ ! "$(ls -A /nix)" ] && cp -R ~/initial-nix/* /nix/
5
6# Source nix environment
7nix_profile="/home/nixuser/.nix-profile/etc/profile.d/nix.sh"
8# shellcheck source=/home/nixuser/.nix-profile/etc/profile.d/nix.sh
9[ -e "${nix_profile}" ] && . "${nix_profile}"
10
11# Propagate UTF8
12# https://github.com/NixOS/nix/issues/599#issuecomment-153885553
13LOCALE_ARCHIVE="$(nix-env --installed --no-name --out-path --query glibc-locales)/lib/locale/locale-archive"
14export LOCALE_ARCHIVE