How to insert output of command into string in MikroTik RouterOS (scripting)
If you have a MikroTik RouterOS command such as
email_send_example.rsc
/tool e-mail send to=me@mydomain.com subject="MikroTik test E-Mail"you can insert the output of a command such as
system_identity_get.rsc
/system identity get nameinto it by using the $[...] syntax:
email_send_with_identity_example.rsc
/tool e-mail send to=me@mydomain.com subject="My identity is $[/system identity get name]"Check out similar posts by category:
MikroTik, Networking
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow