diff --git a/lib/types.nix b/lib/types.nix index 4e44e7521c4b63..ca6794e274c31b 100644 --- a/lib/types.nix +++ b/lib/types.nix @@ -194,7 +194,10 @@ rec { # separator between the values). separatedString = sep: mkOptionType rec { name = "separatedString"; - description = "string"; + description = if sep == "" + then "Concatenated string" # for types.string. + else "strings concatenated with ${builtins.toJSON sep}" + ; check = isString; merge = loc: defs: concatStringsSep sep (getValues defs); functor = (defaultFunctor name) // {