1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-07 06:01:48 +02:00

Merge pull request #8193 from hercules-ci/dry-strings

Deduplicate string literal rendering, fix 4909
This commit is contained in:
Robert Hensing 2023-04-17 11:19:40 +02:00 committed by GitHub
commit 9af9c260fc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 158 additions and 64 deletions

View file

@ -79,6 +79,14 @@ testReplResponse '
"result: ${a}"
' "result: 2"
# check dollar escaping https://github.com/NixOS/nix/issues/4909
# note the escaped \,
# \\
# because the second argument is a regex
testReplResponse '
"$" + "{hi}"
' '"\\${hi}"'
testReplResponse '
drvPath
' '".*-simple.drv"' \