Need to use shellcheck with .zsh and or #!/bin/zsh scripts? [SC1071]

If, like me, you find yourself trying to use shellcheck to lint .zsh files with #!/bin/zsh but it keeps telling you:

shellcheck: error
error 
  • ShellCheck only supports sh/bash/dash/ksh scripts. Sorry! [SC1071]
  • What I was able to do is pass the --shell=bash argument to shellcheck and then it would lint my files.

    In my case this was configured in my SublimeLinter config, like so:

    {
        "linters": {
            "shellcheck": {
                "args": [
                    "--shell=bash"
                ]
            },
        }
    }
    

    …just in case you are using Sublime Text!