4 ms·
> For anyone writing bash scripts today I would avoid the old test/[ functions entirely. I think it's better said that anyone writing bash scripts today should
by inetknght 6y ago
> For anyone writing bash scripts today I would avoid the old test/[ functions entirely.
I think it's better said that anyone writing bash scripts today should always pass their script to shellcheck.net. It can even be installed locally in case sharing the script online is undesired.
Shellcheck will not only look for problems in the script but it will also usually provide some background about how the problem is a problem and a suggested workaround or solution.