News for hackers. Stuff that matters.
Re:Writing Safe Shell Scripts (2019) by 3xblah on Saturday February 01, 2020 @11:10PM (#22215087)
"The double quotes are of course technically correct, but when ... it's overkill and makes everyrthing ugly."

The only way you know this is being a person who routinely writes shell scripts.

There is no substitute for knowing what you're doing.

Try running shellcheck on configure scripts.

Or try this

    curl -4O https://ftp.netbsd.org/pub/NetBSD/NetBSD-release-8/src/build.sh
    shellcheck build.sh
Or try shellcheck on the build.sh from buildroot.org.

These scripts are "safe" enough for hundreds or thousands of competent users to be running them every day.

Re:Writing Safe Shell Scripts (2019) by yyx on Saturday February 01, 2020 @11:37PM (#22215164)
>all I get are false positives

double quotes, mixing string and array, unused variables. Why is this normal?