Skip to content

Commit

Permalink
template: use direnv only
Browse files Browse the repository at this point in the history
nix-direnv depends on NIX_BUILD_TOP, which is removed from our cleaned
environment.

Fixes #188
  • Loading branch information
zimbatm committed Apr 11, 2022
1 parent 6ec7953 commit e22633b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions template/.envrc
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
if ! has nix_direnv_version || ! nix_direnv_version 1.3.0; then
source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/1.3.0/direnvrc" "sha256-1VWM1BnI1GvclYBky5f5Y9HqeThmQUwCWQbsFQM1Eu0="
if [[ $(type -t use_flake) != function ]]; then
echo "ERROR: use_flake function missing."
echo "Please update direnv to v2.30.0 or later."
exit 1
fi

use flake

0 comments on commit e22633b

Please sign in to comment.