Here is the code in question
Code:
# Determine which release of Debian is
# being used.
CODENAME=`lsb_release -c`
# Backup /etc/apt/sources.list
mv /etc/apt/sources.list /etc/apt/sources.list.bak
# Install the correct /etc/apt/sources.list
# file.
LENNY='Codename: lenny'
if [ "$CODENAME" -eq "$LENNY" ] ; then
cp $SRCDIR/files/aptsources/lenny /etc/apt/sources.list
fi
How ever when I run this script I get the following error
Quote:
./test.sh: line 57: [: too many arguments
|
Line 57 is the line that reads
if [ "$CODENAME" -eq "$LENNY" ] ; then
I just don't get it, I have racked my brain trying to figure out every combination of how I should write this if statement and I can't get it to work. What am I doing wrong and why is it wrong?
Thanks