Docker

Docker

Made by DeepSource

Unexpected == detected DOK-SC1097

Bug risk
Major

== is being used in an unexpected way. The two most common reasons for this is:

  • You wanted to assign a value but accidentally used == instead of =.
  • You wanted to compare two values, but neglected to use [ .. ] or [[ .. ]].

If you wanted to assign a literal equals sign, use quotes to make this clear:

var="=sum(A1:A10)"

Bad Practice

var==value

Recommended

Assignment:

var=value

Comparison:

[ "$var" = value ]