57 ms·
I can highly recommend using Shellcheck [0] when writing Bash, it also has extensions for VS Code and other IDE's. It makes writing Bash much easier. [0] https
by woudsma 4y ago
I can highly recommend using Shellcheck [0] when writing Bash, it also has extensions for VS Code and other IDE's. It makes writing Bash much easier.
[0] https://github.com/koalaman/shellcheck https://github.com/koalaman/shellcheck
- placatedmayhem 4y agoI moved over to shellharden a while ago. It can actually apply the suggestions it makes. Aside from that, my employer is somewhat disapproving for GPLv3 tools, but MPL that shellharden uses is essentially auto-approved. https://github.com/anordal/shellharden https://github.com/anordal/shellharden
- scbrg 4y ago> my employer is somewhat disapproving for GPLv3 tools Let's hope it's not bash scripts you're writing :-) http://git.savannah.gnu.org/cgit/bash.git/tree/COPYING http://git.savannah.gnu.org/cgit/bash.git/tree/COPYING
- placatedmayhem 4y agoYeah, other shell flavors are fine.
- franga2000 4y agoHow is GPLv3 any different from MPL when it comes to use (as opposed to modification or distribution)?
- placatedmayhem 4y agoI can only guess about the distinction our legal department sees.
- jakewins 4y agoAgree, this is the way.
- chubot 4y agoShellCheck is great, but since it works on syntax, it can't catch problems that can only be determined at runtime, like "if myfunc" with set -e on. Example here: https://news.ycombinator.com/item?id=33122256 https://news.ycombinator.com/item?id=33122256