We are about to make a change to a variant that lots of our xlt translation programs use. Is there a way to reconfigure batches of the translations via a command line or script?
I am not aware of any command line utility that is shipped with CL.
You could write something in PERL, TCL, or any other language that you have access to to make the changes to the “flat” files. Just a word of warning here… always, always make a backup before you make any changes via another method.
Reconfiguring the translates is fairly simple because it is just a matter of modifying the xlt_infile or xlt_outfile in the header. You could likely (assuming you are on a unix platform) use a sed command to do this part. That comes with the usual caveats that the rest of the folks have already addressed.
The real problem will be if the HL7 paths change due to the difference in the variant and that is VERY LIKELY. In those cases writing a script that would accomplish this automatically would be very challenging (not impossible I suppose but extremely intensive). First you would have to keep a copy of both of the variants, find the instances where they are different, and then replace the paths that differ with the path in the new variant. Even this sounds great in theory but then you have to consider the iterates and automagically modifying the iterate variables…etc, etc….