diff --git a/lib/types.nix b/lib/types.nix index 4d6ac51c8988..6d8e58dc0be8 100644 --- a/lib/types.nix +++ b/lib/types.nix @@ -192,7 +192,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) // {