@Jonte, which one, and what problem you having? I can offer what see in @rextended’s examples below, but can’t vouch that’s all the V7 issues.
I didn’t try this one, but I DO know it won’t detect functions right in V7. “eval” is now “evl”, here no :parse be needed, just different string to look for in V7 vs V6 to fix that one.
:global x do={:put "blah"}
# Version 7 it's ";evl(" that need to be :find
/system script environment print detail where name=x
# 3 name="x" value=";(evl (evl /putmessage=blah))"
# But in Version 6, it's ";eval" that's @rextended uses
/system script environment print detail where name=x
# 1 name="x" value=";(eval (eval /putmessage=blah))"
Basically those are :typeof str, but represent the “compiled script” which why @rextended excludes them. Only issue how he’s identifying them similar “:if ($majorversion>6) do={} else={}” thing.
Save RouterBOARD full backup of everything [configuration, certificates, host key, router users (no passwords), user-manager, dude, other files]
Router crashes are wiping the config - #7 by rextended
This one has a different problem. I don’t know exactly why but the “$byemail …” lines need be wrapped in a parenthesis. Only did a quick test, but changing the ALL the $byemail lines like this:
# did not work in V7
$bymail $dsubj="Certificate $certname $date $time" $dfile="auto_$certname.p12"
# works in V7
($bymail $dsubj="Certificate $certname $date $time" $dfile="auto_$certname.p12")
# NOTE: I'm not sure the $ in $dsubj= needed
I’ve found being using a “command subdirectory” to then “short form” find/get/set’s sometimes causes odd issues in V7. Do something like “/certificate”, then your code does make the script more human readable – but RouterOS “script compiler” seems to needs more help to figure stuff out when you do that. So putting commands or functions with parameters in parenthesis and/or brackets often helps MT’s hidden script compiler. In theory, I wouldn’t say you should need them, but the ($bymail …) fixed @rextended’s backup script on v7.2rc4 in my quick test.