From 50adf43449743dfc0e4e82ab533112ef110bcfb0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joaqu=C3=ADn=20Tri=C3=B1anes?= Date: Thu, 17 Jul 2025 21:15:13 +0200 Subject: [PATCH] nushell: fix `get -i` deprecation (#7490) Since https://github.com/nushell/nushell/pull/16007, the recommended flag to avoid erroring on missing fields is `--optional`. To avoid compatibility issues, the builtin optional access syntax is used instead, which is backwards-compatible. --- modules/programs/direnv.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/programs/direnv.nix b/modules/programs/direnv.nix index 80e7e0c7..de616a70 100644 --- a/modules/programs/direnv.nix +++ b/modules/programs/direnv.nix @@ -193,8 +193,8 @@ in } } | merge ($env.ENV_CONVERSIONS? | default {}) - | get -i ([[value, optional, insensitive]; [$key, false, true]] | into cell-path) - | get -i from_string + | get ([[value, optional, insensitive]; [$key, true, true]] | into cell-path) + | get from_string? | if ($in | is-empty) { {|x| $x} } else { $in } ) $value return [ $key $value ]