So lets say I open CMD or PowerShell and enter
ping google.com -t
I will get a constant stream of pings. (I could obviously also write a script that gets pings within python but that is not the problem, I just want to know how to do this in theory.) What i want to do now is write a python script that gets those outputs from the CMD and prints them out, live. Is this even possible?
Example: I am running a server which prints logs into a command line and I want to read and save them (i know the save part, just the retrieve is my problem)
Example2: I am running my monero wallet (not the gui, the command line version) and want a script that notifies me when money is sent in
Summed up: an external program of which the UI is a Command line or whose logs are printed into CMD or similar programs is running, and i want to get all the things this program prints out.