about summary refs log tree commit diff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/strings.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/strings.nix b/lib/strings.nix
index 3a61f5be68b65..45d3bcbb440db 100644
--- a/lib/strings.nix
+++ b/lib/strings.nix
@@ -757,7 +757,7 @@ rec {
        => "-nix-store-2g75chlbpxlrqn15zlby2dfh8hr9qwbk-hello-2.10"
   */
   sanitizeDerivationName =
-  let okRegex = match "^[[:alnum:]+_?=-][[:alnum:]+._?=-]*$";
+  let okRegex = match "[[:alnum:]+_?=-][[:alnum:]+._?=-]*";
   in
   string:
   # First detect the common case of already valid strings, to speed those up