TIL: Some surprising code execution sources in bash

@yossarian The use of '[[' is the problem. That's an evaluating comparison and is as dangerous as 'eval' (as shown). All scripts should be using just the single '['. Using '[[' is for compatibility with ancient shells.
@kees @yossarian uh, good to know. I'm pretty sure at some point I've been told (maybe by some linting tool?) that [[ is preferrable to [.
@kees @yossarian https://www.shellcheck.net/wiki/SC2292 says "[[ .. ]] suppresses word splitting and globbing, supports a wider variety of tests, and is generally safer and better defined than [ .. ]"
Not enabled by default in current version, but I believe it was in the past.
ShellCheck: SC2292 – Prefer `[[ ]]` over `[ ]` for tests in Bash/Ksh.

@hanno @kees huh yeah, I guess that’s where I got the idea that [[ was preferred over [ from! thanks for finding that!