SC1027 – ShellCheck Wiki

See this page on GitHub

Sitemap


Expected another argument for this operator.

Problematic code:

[ $a -ne ]

Correct code:

[ $a -ne $b ]

Rationale:

ShellCheck found a test operator without an operand. This could be a copy-paste fail, bad linebreak, or trying to use <> instead of != or -ne.

Exceptions:

None.


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