I'm using some casperjs scripts (which I don't really understand) with a known issue that the process hangs after a specific warning message. Otherwise it's outputting a log message every few seconds.
I need to restart the process when it hangs.
So can I make a script which checks if a log file is getting bigger at each time interval? Or can I intercept the console output of a process and check if the last message is the same as the specific warning message?
Any help will be appreciated, thanks!