Merge pull request 'clan-core/secrets: escape trailing newline in facts' (#586) from a-kenji-trim-facts into main

This commit is contained in:
clan-bot
2023-11-29 13:27:03 +00:00

View File

@@ -105,7 +105,7 @@
type = lib.types.nullOr lib.types.str; type = lib.types.nullOr lib.types.str;
default = default =
if builtins.pathExists "${config.clanCore.clanDir}/${fact.config.path}" then if builtins.pathExists "${config.clanCore.clanDir}/${fact.config.path}" then
builtins.readFile "${config.clanCore.clanDir}/${fact.config.path}" lib.strings.removeSuffix "\n" (builtins.readFile "${config.clanCore.clanDir}/${fact.config.path}")
else else
null; null;
}; };