Unexpected operator error [duplicate]

You need to use = instead of == in the [ $? == 0 ] line.

Leave a Comment