run a python script with python and catch command line output code example
Example: run a python script with python and catch command line output
import os
cmd = 'wc -l my_text_file.txt > out_file.txt'
os.system(cmd)
import os
cmd = 'wc -l my_text_file.txt > out_file.txt'
os.system(cmd)