I am trying to automatically press enter after I execute a command in command prompt, for example, I run....
d:\myunit> codecov instrument -ip
And it outputs:
Warning: It is recommended when instrumenting code that you use the sub-unit option for 'codecov' to avoid instrumentation being inserted in the source code in your development unit. Press 'enter' to continue with-out using a sub-unit.
If that command is actually executed from a python script(using os.system('codecov instrument -ip')). How can I make the same script also press enter so that the script can continue without user input? Currently I have been trying to use a subprocess but am not sure if it is the best way to go about it and have not gotten it to work.