diff options
| author | Martin Fischer <martin@push-f.com> | 2026-09-30 18:44:39 +0200 |
|---|---|---|
| committer | Martin Fischer <martin@push-f.com> | 2026-09-30 19:58:13 +0200 |
| commit | 11732a457b69c6cd72a38ac17fa6762e221e1ce6 (patch) | |
| tree | 481b9de76525bde256a35d50435a5a7bfae72283 | |
| parent | 88909568036342f5692b0a7c6fc022416eb0235f (diff) | |
nix-direnv isn't used automatically when installed,
it needs to be sourced in direnvrc, which I was missing.
Just enabling programs.direnv does this by default
(programs.direnv.nix-direnv.enable defaults to true).
This had caused gcroots to be broken for some reason.
I'm removing user/direnv/direnv.toml because with
programs.direnv it's not read anymore since the module
sets DIRENV_CONFIG=/etc/direnv.
| -rw-r--r-- | nixos/profiles/workstation/dev.nix | 10 | ||||
| -rw-r--r-- | user/direnv/direnv.toml | 4 | ||||
| -rw-r--r-- | user/zsh/zshrc-workstation.sh | 2 |
3 files changed, 7 insertions, 9 deletions
diff --git a/nixos/profiles/workstation/dev.nix b/nixos/profiles/workstation/dev.nix index 693e5a3..0f28507 100644 --- a/nixos/profiles/workstation/dev.nix +++ b/nixos/profiles/workstation/dev.nix @@ -1,15 +1,19 @@ { config, pkgs, pkgs-unstable, ... }: { + programs.direnv = { + enable = true; + settings.global = { + hide_env_diff = true; + }; + }; + environment.systemPackages = with pkgs; [ rustup go python313 nodejs_22 - direnv - nix-direnv - # CLI tools docker-compose gnumake diff --git a/user/direnv/direnv.toml b/user/direnv/direnv.toml deleted file mode 100644 index 1573479..0000000 --- a/user/direnv/direnv.toml +++ /dev/null @@ -1,4 +0,0 @@ -[global] -# direnv by default prints which environment variables are being exported -# Since nix-direnv sets quite a lot I'm filtering this out. -log_filter = "^(un)?loading" diff --git a/user/zsh/zshrc-workstation.sh b/user/zsh/zshrc-workstation.sh index a31627b..44be2d2 100644 --- a/user/zsh/zshrc-workstation.sh +++ b/user/zsh/zshrc-workstation.sh @@ -17,8 +17,6 @@ path+=$CARGO_HOME/bin path+=$GOPATH/bin path+=$NPM_CONFIG_PREFIX/bin -eval "$(direnv hook zsh)" - function ssh() { # When I ssh into a server my terminal changes to a host-specific background color via # a LocalCommand configured in ~/.ssh/config and this ZSH function resets the color on exit. |
