||, or bad expression?
[ "$1" ] input="$1"
[ "$1" ] && input="$1"
ShellCheck found characters (other than redirections) after the
]] in a test expression. This is not valid.
This sometimes happens when there was an additional expression or command, but joining
&& is missing. Alternatively, it could happen due to typos (like
[[ $1 ]]] with an extra
]), or generally from malformed test expressions.
ShellCheck is a static analysis tool for shell scripts. This page is part of its documentation.