3 homepage: https://github.com/koalaman/shellcheck
5 ShellCheck - A shell script static analysis tool
8 To update or switch versions, run `webi shellcheck@stable`, or `@vx.y.z` for a
13 > shellcheck catches rookie mistakes (and old-habits-die-hard mistakes) in bash
15 Also recommended by Google's
16 [Shell Style Guide](https://google.github.io/styleguide/shellguide.html)
18 ### How to run shellcheck from the CLI
21 shellcheck ./script.sh
24 ### How to run shellcheck in vim
27 [supported by `vim-ale`](https://github.com/dense-analysis/ale/blob/master/supported-tools.md)
30 Just [install `vim-ale`](https://webinstall.dev/vim-ale) and `shellcheck` and
33 ### How to run shellcheck in VS Code
36 [Visual Studio Marketplace: ShellCheck](https://marketplace.visualstudio.com/items?itemName=timonwong.shellcheck).
38 ### To use shellcheck in a build or test suite:
40 Simply include shellcheck in the process.
44 # Fail if any of these files have warnings
45 shellcheck myscripts/*.sh
48 ### How to ignore an error
50 You can ignore an error by putting a comment with the `SCXXXX` error code above
54 # shellcheck disable=<code>
58 # shellcheck disable=SC1004
59 NOT_AN_ERROR='Look, a literal \
63 Complete list of `SCXXXX` error codes:
64 <https://gist.github.com/nicerobot/53cee11ee0abbdc997661e65b348f375>