Convert tool batch files to python scripts