How to improve and debug your shell scripts with ShellCheck

ShellCheck is a free and open source static analysis tool which can be used to check and improve shell scripts. It is able to highlight both common and edge-case errors, and suggest the appropriate fixes. ShellCheck can be used as an online or system utility, but can also be integrated as a linter in various text editors.

Source: LXer – How to improve and debug your shell scripts with ShellCheck