SC1125 – ShellCheck Wiki

See this page on GitHub

Sitemap


Invalid key=value pair in directive

Problematic code:

# shellcheck disable=SC2153 (variable not a misspelling)

Correct code:

# shellcheck disable=SC2153 # variable not a misspelling

Rationale:

A comment at the end of a directive must be preceded by a # to avoid it being interpreted as an instruction. The directive page contains more guidance about commenting style.


ShellCheck is a static analysis tool for shell scripts. This page is part of its documentation.