I want to check if the user running the script is root or not before running. But it doesn't seem to work. I'm currently logged in as root, but its something wrong with the syntax I think.
if[[ $EUID -ne 0 ]];
then
echo "Sorry, you are not root."
exit 1
else
echo "You are root, script will continue."
fi