Help on simple shell script

Hello,

I need to create one very simple shell script that checks if the first character of the file ./pump.txt is 0 and in that case gives a message.
If the first character is instead 1, it does give a different message.

I have written:

irr= head -c 1  ./pump.txt
if [[ "$irr" == "0" ]]; then
        echo "!!!!!!!!!! Disabled"
else
        echo "Enabled"
fi

It does not work.

Ps, the file ./pump.txt is generated by the following commands:

echo "1" > "./pump.txt"
echo "0" > "./pump.txt"

Can you please help me?
Thanks,
daniele

Try

irr=$(head -c 1  ./pump.txt)

Note: No space between `='.

Please wrap your code in "code" tags!
You want a sub command

irr=$(head -c 1 ./pump.txt)

or in backticks

irr=`head -c 1 ./pump.txt`

More elegant: read the first line

read irr < ./pump.txt

Thanks for helping, it works!

Or, read just one char:

read -n1 irr < ./pump.txt