[Solved] Use python to run a command line [duplicate]

[ad_1]

You can use subprocess module.

import subprocess
subprocess.call(["tclsh", "oommf.tcl", "avf2odt", "-average", "space", "-axis", "z", "-onefile",  "<filename>.txt", "-headers", "none", "-ipat", "*.omf"])

See https://docs.python.org/2/library/subprocess.html#subprocess.call

3

[ad_2]

solved Use python to run a command line [duplicate]