pkgs.formats.hcl1: host let variables to outside function scope

This commit is contained in:
Eman Resu
2026-06-07 08:48:18 -04:00
parent 01d76243e0
commit 6bd71d7e08
+1 -1
View File
@@ -1063,7 +1063,6 @@ optionalAttrs allowAliases aliases
};
hcl1 =
args:
let
# Helper function to recursively transform values for HCL1 canonicalization
# Rule: If an attribute value is an attribute set, wrap it in a list
@@ -1079,6 +1078,7 @@ optionalAttrs allowAliases aliases
value;
jsonFormat = json { };
in
args:
jsonFormat
// {
generate = name: value: jsonFormat.generate name (mapAttrs (_: transform) value);