Project

General

Profile

shell script that runs when tvheadend is idle

Added by David Coad over 12 years ago

Hi,

I record to the /home/hts folder as my system won't let me record directly to an external HD. (long story dont want to fight it just work with it)

I want to set up a shell script to move all the .mkv files from /home/hts to /media/RECORDINGS/recordedtv as below,

cd /home/hts
mv *.mkv /media/RECORDINGS/recordedtv

what I need help with is that I want to set it up to run the script at a particular time but first check that a recording is not half way through or due to start a scheduled recording soon and if so, delay until it is complete and idle.

Is there a way in the script to check if tvheadend is idle or not planning to start a new recording in the next 30 minutes and then run the move script?

Thanks
Dave


Replies (1)

RE: shell script that runs when tvheadend is idle - Added by Markus Bonet over 12 years ago

You can simply define a "Post-processor command" in the DVR configuration, which will move the file after the recording is finished.

    (1-1/1)