r1127 + removed debug lines
authorDenis Ovsienko <infrastation@yandex.ru>
Tue, 4 Sep 2007 14:26:27 +0000 (14:26 +0000)
committerDenis Ovsienko <infrastation@yandex.ru>
Tue, 4 Sep 2007 14:26:27 +0000 (14:26 +0000)
+ adopted new OK! syntax

gateways/switchvlans/main

index 1638285..4eb41cb 100755 (executable)
@@ -19,24 +19,22 @@ usage()
 
 [ $# = 4 ] || usage
 
-while read cmd arg; do
-       echo -n $cmd >> /tmp/main.log
-       date >> /tmp/main.log
+while read cmd arg1 arg2; do
        case $cmd in
                listvlans)
-                       echo 'OK 200,204,203,202,201,205,333,334'
+                       echo 'OK!200,204,203,202,201,205,333,334'
                        ;;
                listports)
-                       echo -n 'OK fa0/0/1=200,fa0/0/2=205,fa0/0/3=202,fa0/0/4=trunk,fa0/0/5=333,fa0/0/6=334,fa0/0/7=333,fa0/0/8=334,'
+                       echo -n 'OK!fa0/0/1=200,fa0/0/2=205,fa0/0/3=202,fa0/0/4=trunk,fa0/0/5=333,fa0/0/6=334,fa0/0/7=333,fa0/0/8=334,'
                        echo -n 'fa0/0/9=200,fa0/0/10=205,fa0/0/11=202,fa0/0/12=trunk,fa0/0/13=333,fa0/0/14=334,fa0/0/15=333,fa0/0/16=334,'
                        echo -n 'fa0/1/1=200,fa0/1/2=205,fa0/1/3=202,fa0/1/4=trunk,fa0/1/5=333,fa0/1/6=334,fa0/1/7=333,fa0/1/8=334,'
                        echo 'fa0/1/9=200,fa0/1/10=205,fa0/1/11=202,fa0/1/12=trunk,fa0/1/13=333,fa0/1/14=334,fa0/1/15=333,fa0/1/16=334'
                        ;;
                set)
-                       echo 'OK'
+                       echo 'OK!'
                        ;;
                *)
-                       echo "ERR 'unknown command $cmd'"
+                       echo "ERR!unknown command $cmd"
        esac
 done