I have an Opus script (user command) that I want to run every evening at X time. Is that possible? Does opus support command line calls to run its script?
Thanks!
I have an Opus script (user command) that I want to run every evening at X time. Is that possible? Does opus support command line calls to run its script?
Thanks!
DOpusRT is a small utility program utilized by Directory Opus for various things. You can use it to send commands to Directory Opus from outside of Opus itself.
Use the /cmd parameter for this. For example, to display the Opus About dialog from a DOS prompt you could use the following command:
dopusrt.exe /cmd help about
The dopusrt keyword is supported by the external command system as a shortcut for the actual location of the dopusrt.exe program. Instead of specifying,
for example, c:\Program Files\GP Software\Directory Opus\dopusrt.exe you can just use dopusrt.
I got an user command (touch_specific) that "touches" a specific directory, and all its files:
SetAttr RECURSE MODIFIED=now FILE="W:\foo\comp 2899\in\lab3"
I tried to execute it like this:
dopusrt /cmd user touch_specific
but that didn't work. What worked though is this:
dopusrt /cmd SetAttr RECURSE MODIFIED=now FILE="W:\foo\comp 2899\in\lab3"
Thanks! Directory Opus rocks!
Try just dopusrt /cmd touch_specific. The "user" keyword you have in there isn't required (and in fact, won't work at all as you've found.)
Follow up question: what if instead of setting modified date to now, I want to set it to 5 minutes in the past from now. Is there a way to perform date arithmetic in Opus?
I don't think the SetAttr command in Opus can do date arithmetic.
You could do it in the calling script, though, and then pass the date/time to the command.
(User commands can also take arguments and pass them to whatever they call so that shouldn't be a problem.)