Merge pull request #254815 from johannwagner/fix-leading-hyphens-for-testVersion

This commit is contained in:
Artturi 2023-09-13 01:23:09 +03:00 committed by GitHub
commit edada48556
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -61,7 +61,7 @@
version ? package.version,
}: runCommand "${package.name}-test-version" { nativeBuildInputs = [ package ]; meta.timeout = 60; } ''
if output=$(${command} 2>&1); then
if grep -Fw "${version}" - <<< "$output"; then
if grep -Fw -- "${version}" - <<< "$output"; then
touch $out
else
echo "Version string '${version}' not found!" >&2