1) anything that reduces (not excessively) the code is fineI see that within your scripts you usually enter the configuration context and handle things there. Example:Code:/log[...]:foreach rlog in=[find where message~"((25[0-5]|(2[0-4]|[01]\?[0-9]\?)[0-9])\\.){3}(25[0-5]|(2[0-4]|[01]\?[0-9]\?)[0-9])"] do={[...]
And I prefer to use the entire path of the command every time:What differences do you see in the two methodologies?Code:[...]:foreach rlog in=[/log find where message~"((25[0-5]|(2[0-4]|[01]\?[0-9]\?)[0-9])\\.){3}(25[0-5]|(2[0-4]|[01]\?[0-9]\?)[0-9])"] do={[...]
Is one better or worse? And why?
2) It is easier to correct a single line, if it changes the context as you wrote, rather than rewriting them all...
3) it is less heavy and more readable.
Statistics: Posted by rextended — Mon Apr 07, 2025 1:20 am