[CentOS] yum check-updates script not working correctly

Thu May 26 16:22:48 UTC 2011
Leonard den Ottolander <leonard at den.ottolander.nl>

Hello Tod,

On Thu, 2011-05-26 at 10:53 -0400, Denniston, Todd A CIV
NAVSURFWARCENDIV Crane wrote:
> The single '=' sign does assignment, a double '==' does string compare.

No, with the spaces around the '=' and the dollar before the variable
name this actually is a test not an assignment. But using double '=' is
more clear, agreed. Try

#!/bin/sh
C="no"
if [ $C = "yes" ]; then
    echo "1: $C"
fi
if [ $C="yes" ]; then
    echo "2: $C"
fi

This will return:
2: no

Bash is very peculiar ;)

Regards,
Leonard.

-- 
mount -t life -o ro /dev/dna /genetic/research