mirror of
https://github.com/nix-community/home-manager.git
synced 2026-12-06 04:40:17 +00:00
Starting nushell 0.111.0, pipefail is enabled by default. A non-zero exit of `direnv export json` (e.g. on an `.envrc` or a `.env`, that has not been explicitly allowed or blocked) raises an error in the middle of the pipeline. That error aborts every pre_prompt hook registered after direnv's. For instance, it stops atuin from finishing its history entries, so commands run in such a directory are never recorded. It also discards direnv's output, which is still meaningful on failure: it unloads the environment of the directory being left and records the blocked state, so the warning is shown only once. Other shells evaluate it regardless of the exit status. Run the export through `complete` so the exit status no longer raises and stdout is always loaded. stderr is passed straight through, so direnv's messages still show up as they happen.