Помогите разобраться в синтаксисе
Добавлено: 04 авг 2021, 13:21
Только начинаю разбираться в скриптах и не могу понять какую команду он просит закрыть.
ругается на else
expected end of command (line 7 column 2)
ругается на else
expected end of command (line 7 column 2)
Код: Выделить всё
:local strike [/tool netwatch find host="192.168.43.1"]
:local InfoOn [:log info message="Strike ON"]
:local InfoOff [:log info message="Strike OFF"]
:if ($strike = "") do={
/tool netwatch add host=192.168.43.1 interval=1s up-script=$InfoOn down-script=$InfoOff;
:log info message="added";
}else={
:log info message="not added";
}