1. 2

    Writing good bash becomes surprisingly approachable with these 3 things:

    1. Start with a sane template (with the set -euo pipefail and other shenanigans).
    2. Use code snippets (aka live templates) in order to create a loop, a function, or anything really.
    3. Use ShellCheck.