From 1c66ae60b992f423076e2fd858ecace03505b035 Mon Sep 17 00:00:00 2001 From: Rebecca Turner Date: Thu, 8 May 2025 11:42:34 -0700 Subject: [PATCH] nix-direnv: 3.0.6 -> 3.0.7 `direnv` 2.36.0 [changed how logging worked][1]. As a result, the `$DIRENV_LOG_FORMAT` variable is no longer set when the `nix-direnv` `direnvrc` is sourced. Previously, setting `$DIRENV_LOG_FORMAT` to the empty string was [the recommended solution for disabling all log output][2]. Therefore, `nix-direnv`'s warnings are completely silenced when using the latest `direnv`. `nix-direnv` 3.0.7 fixes this issue. Warnings being silenced leads to very surprising behavior and output. We use an `.envrc` that looks like this: nix_direnv_manual_reload use flake `nix_direnv_manual_reload` means that `use flake` is ignored unless a cache already exists. It's supposed to print a warning making this clear, which looks like this: $ direnv allow direnv: loading ~/my-repo/.envrc direnv: using flake direnv: nix-direnv: cache does not exist. use "nix-direnv-reload" to create it direnv: export ~PATH However, with the latest `direnv`, it prints this output instead: $ direnv allow direnv: loading ~/my-repo/.envrc direnv: using flake direnv: export ~PATH This is very misleading; it prints `using flake` as if it's loading the Flake, but actually nothing is happening and the Flake is being ignored entirely! [1]: https://github.com/direnv/direnv/pull/1336 [2]: https://github.com/direnv/direnv/issues/68#issuecomment-42525172 --- pkgs/by-name/ni/nix-direnv/package.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/by-name/ni/nix-direnv/package.nix b/pkgs/by-name/ni/nix-direnv/package.nix index ff56c097c29a..0298c0fd3ec3 100644 --- a/pkgs/by-name/ni/nix-direnv/package.nix +++ b/pkgs/by-name/ni/nix-direnv/package.nix @@ -11,13 +11,13 @@ # https://github.com/abathur/resholve/issues/107 resholve.mkDerivation rec { pname = "nix-direnv"; - version = "3.0.6"; + version = "3.0.7"; src = fetchFromGitHub { owner = "nix-community"; repo = "nix-direnv"; rev = version; - hash = "sha256-oNqhPqgQT92yxbKmcgX4F3e2yTUPyXYG7b2xQm3TvQw="; + hash = "sha256-H59MMmyQ9Tl9CLKKkXIv2NZddrrJNLv8XOOI2e4pG64="; }; installPhase = ''