From 853e7bd24f875bac2e3a0cf72f993e917d0f8cf5 Mon Sep 17 00:00:00 2001 From: K900 Date: Thu, 26 Sep 2024 23:03:30 +0300 Subject: [PATCH] direnv: even better nushell fix Avoid do | complete, because it swallows stderr, which can contain direnv debug output. --- modules/programs/direnv.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/programs/direnv.nix b/modules/programs/direnv.nix index 1b409991c..951061f98 100644 --- a/modules/programs/direnv.nix +++ b/modules/programs/direnv.nix @@ -143,9 +143,9 @@ in { let direnv = ( # We want to get the stdout from direnv even if it exits with non-zero, # because it will have the DIRENV_ internal variables defined. - do { ${getExe cfg.package} export json } - | complete - | get stdout + do --ignore-program-errors { ${ + getExe cfg.package + } export json } | from json --strict | default {} )