aboutsummaryrefslogtreecommitdiffstats
path: root/global-functions
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2020-07-14 16:32:17 +0200
committerGravatar Christian Hesse <mail@eworm.de>2020-07-14 17:02:41 +0200
commitf4d6e07dbb6c1406b56c77116a52d11ff8b363b1 (patch)
tree18d6ffb82f0708255ccff24c03e3429d457fc440 /global-functions
parentd1b6ca3d0b531f310a21b947837f7771649b9e17 (diff)
global-config: dropped $ScriptUpdatesIgnore, use ignore flag in commentchange-22
Diffstat (limited to 'global-functions')
-rw-r--r--global-functions18
1 files changed, 13 insertions, 5 deletions
diff --git a/global-functions b/global-functions
index 57ae336..db27774 100644
--- a/global-functions
+++ b/global-functions
@@ -8,7 +8,7 @@
# https://git.eworm.de/cgit/routeros-scripts/about/
# expected configuration version
-:global ExpectedConfigVersion 21;
+:global ExpectedConfigVersion 22;
# global variables not to be changed by user
:global GlobalFunctionsReady false;
@@ -529,11 +529,19 @@
}
:if ([ :len $SourceNew ] = 0 && $ScriptUpdatesFetch = true) do={
- :foreach IgnoreLoop in=$ScriptUpdatesIgnore do={
- :if ($IgnoreLoop = $ScriptVal->"name") do={ :set Ignore 1; }
- }
:local Comment [ $ParseKeyValueStore ($ScriptVal->"comment") ];
- :if ($Comment->"ignore" = true) do={ :set Ignore 1; }
+ :if ($Comment->"ignore" = true) do={
+ :set Ignore 1;
+ } else={
+ # TODO: remove at later time
+ :foreach IgnoreLoop in=$ScriptUpdatesIgnore do={
+ :if ($IgnoreLoop = $ScriptVal->"name") do={
+ :set Ignore 1;
+ $LogPrintExit info ("Migrating script " . $ScriptVal->"name" . " to ignore flag in comment.") false;
+ / system script set comment="ignore" ($ScriptVal->"name");
+ }
+ }
+ }
:if ($Ignore = 0) do={
$LogPrintExit debug ("Fetching script from url: " . $ScriptVal->"name") false;