Member-only story
5 VS Code Extensions for Bash Scripting
Write awesome Bash scripts
VS Code provides excellent extensions for Bash scripting. In this article, we will cover a built-in shell extension, a linter, a formatter, a snippet extension, a debugger, and more.
Ready? Go and fire up VS Code.
Shell Script Language Basics

This extension is bundled with Visual Studio Code. It can be disabled but not uninstalled. It provides syntax highlighting and bracket matching in shell script files.
You can check it by typing @builtin shell
in the extensions tab, as you see in the above image.
Once it is enabled, click “Plain Text” in the bottom status bar.
Select “Shell Script” in the Select Language mode.
ShellCheck

ShellCheck is a shell script static analysis tool. By installing ShellCheck, you can avoid many beginner pitfalls.

You can find the list of warnings on GitHub or use the URL https://github.com/koalaman/shellcheck/wiki/SCXXXX where “XXXX” is the warning code (e.g. 2086).

shell-format

Shell-format formats shell scripts, Dockerfiles, gitignore, dotenv, and more. Shell-format helps you with indentations, removing extra spaces, and alignment.
This extension depends on shfmt
. If you are using Homebrew, you can install it: