global-functions: introduce $MAX

This commit is contained in:
Christian Hesse 2023-11-30 12:01:59 +01:00
parent 080bef89a9
commit 495eff48de

View file

@ -48,6 +48,7 @@
:global IsTimeSync;
:global LogPrintExit2;
:global LogPrintOnce;
:global MAX;
:global MkDir;
:global NotificationFunctions;
:global ParseDate;
@ -680,6 +681,12 @@
$LogPrintExit2 $Severity $Name $Message false;
}
# get max value
:set MAX do={
:if ($1 > $2) do={ :return $1; }
:return $2;
}
# create directory
:set MkDir do={
:local Path [ :tostr $1 ];