Hello!

I'm sorry if this is FAQ question, but googling didn't report it, so
I'm asking here.

In our scripts we often use constructs like

##############
if [ 0 -eq $UID ]
then
        echo "This script must not be run by root user!"
        exit 1
fi
#################

This works fine in bash, but dash fails with warning " [: -ne:
argument expected". Is this intended feature? How to work around it in
dash then?

Best regards
Andrei Voropaev
--
To unsubscribe from this list: send the line "unsubscribe dash" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to