Execute batch files from JAVA and capture batch environment
I need a solution that allows to capture the batch file exit code and the
resultant environment - by this I mean that I need to retrieve the system
environment + variables set within the batch e.g. "SET VAR=VAL" - I need
that VAR=VAL on batch exit.
First thing I thought about is a ProcessBuilder but in the end it does not
return batch internal variables. I need this solution to be universal -
good for any batch.
No comments:
Post a Comment