Nov-13-2016, 06:36 AM
i have one or more CLI commands to run. they could be run in a Python script by using subprocess.call though this is not the ultimate method. what i would like to do is make a Python script frontend that filters the input and filters the output. by filter i mean some kind of processing i decide on such as appending changing filename extensions on inputs and adding timestamps on outputs. so there certainly needs to be a pipe or pipes between the filter script and the stdin and stdout of the interactive program to be run.
i am looking for examples of this kind of code or descriptions of exactly what to do (code).
i am looking for examples of this kind of code or descriptions of exactly what to do (code).