the (condensed) seed file
11.2[8]SA3
12.0[13]EA1c
12.1[17]
12.2[12b]
12.3[10]
6.4[3]
7.6[2a]
8.3[5]
I want to be able to branch based on the contents of a varable holding an IOS version. How the heck do I anchor the case possibilities to basically say if ver starts with 11, echo 11 code, 12.0 echo 12.0 code etc etc.
I tried "^12.0", "12.0", ^12.0 .. nutting working.
Thanks alot
My cheap code
cat seedfile | cut -d"[" -f1 | while read ver
do
case $ver in
11) echo "I have 11.x IOS code. " ;;
12.0) echo "I have 12.0 IOS code. " ;;
12.1) echo "I have 12.1 IOS code. " ;;
esac
done
11.2[8]SA3
12.0[13]EA1c
12.1[17]
12.2[12b]
12.3[10]
6.4[3]
7.6[2a]
8.3[5]
I want to be able to branch based on the contents of a varable holding an IOS version. How the heck do I anchor the case possibilities to basically say if ver starts with 11, echo 11 code, 12.0 echo 12.0 code etc etc.
I tried "^12.0", "12.0", ^12.0 .. nutting working.
Thanks alot
My cheap code
cat seedfile | cut -d"[" -f1 | while read ver
do
case $ver in
11) echo "I have 11.x IOS code. " ;;
12.0) echo "I have 12.0 IOS code. " ;;
12.1) echo "I have 12.1 IOS code. " ;;
esac
done