If I read your question correctly, you want to pass the output from one command to another.
This is usually done as follows:
cmd1 | cmd2
However, you say that your program writes only files. I would double check the documentation to make sure that this is not a way to force the command to write to stdout instead of a file.
If this is not possible, you can create a so-called named pipe . It is displayed as a file in your file system, but in fact it is just a data buffer that can be written and read (data is a stream and can be read only once). This means that your program, after reading it, will not be completed until the program writing to the handset stops writing and closes the "file". I have no experience with named pipes in windows, so you need to ask a new question. One bottom side of the pipes is that they have a limited buffer size. Therefore, if there is no data on reading the program from the channel, then after the buffer is full, the write program cannot continue and just wait indefinitely until the program starts reading from the channel.
An alternative is that on Unix there is a program called tail , which can be configured to continuously monitor the file for changes and output any data as it is added to the file (with a slight delay.
tail --follow=textfile.txt --retry | mycmd # wait for data to be appended to the file and output new data to mycmd cmd1 >> textfile.txt # append output to file
One note about this is that tail will not stop just because the first command stopped writing to the file. tail will continue to listen to changes to this file forever, either until mycmd stops listening to tail , or until tail is killed (or "sigint-ed").
This question has various answers on how to get the tail version on a Windows machine.
Dunes source share