1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-08 02:43:54 +02:00

Add a straightforward way to determine if inside a nix3 shell

This commit is contained in:
Ersei Saggi 2024-12-03 16:06:41 -05:00
parent ff00eebb16
commit 1e77a8dd91
No known key found for this signature in database
GPG key ID: 023FF4C1A9D6BAFD
3 changed files with 4 additions and 0 deletions

View file

@ -36,6 +36,7 @@ nix shell -f shell-hello.nix hello -c env > "$TEST_ROOT/actual-env"
# - __CF_USER_TEXT_ENCODING is set by macOS and is beyond our control
sed -i \
-e 's/PATH=.*/PATH=.../' \
-e '/^IN_NIX_SHELL=.*/d' \
-e 's/_=.*/_=.../' \
-e '/^TMPDIR=\/var\/folders\/.*/d' \
-e '/^__CF_USER_TEXT_ENCODING=.*$/d' \