bash : Illegal number

You have syntax error in your if condition, use this if condition:

if [ "$EUID" -ne 0 ];

OR using [[ and ]]

if [[ "$EUID" -ne 0 ]];

Leave a Comment