Skip to content
Vidar Holen edited this page Jan 14, 2019 · 1 revision

This shebang specifies a directory. Ensure the interpreter is a file.

Problematic code:

#!/bin/sh/
echo "Hello World"

Correct code:

#!/bin/sh
echo "Hello World"

Rationale:

The shebang specifies which file to use as an interpreter, but probably due to some kind of typo, your script's interpreter ends in a /, indicating a directory.

Ensure it points to a valid executable filename.

Exceptions:

None

Related resources:

  • Help by adding links to BashFAQ, StackOverflow, man pages, POSIX, etc!

ShellCheck

Each individual ShellCheck warning has its own wiki page like SC1000. Use GitHub Wiki's "Pages" feature above to find a specific one, or see Checks.

Clone this wiki locally