Project

General

Profile

Any way to automatically create .nfo files?

Added by A L about 4 years ago

Hi there.

Is there any way I can create an automatic .nfo file for each recording I make, with a post-processing script?

If so it would be really helpful as a backup, for when Kodi cannot find the episode with its scraper.


Replies (1)

RE: Any way to automatically create .nfo files? - Added by Bernd Gravenfeld about 4 years ago

Hi A L,
you may look at my two scripts (pre- and post-processor). I made these some years ago and they work in my environment as supposed:
tvheadend runs on a ubuntu server (24/7), also all of my recordings and mediafiles are stored (accessible via nfs shares) there. Kodi runs on a small "mediacenter" attached to our tv.
The recordings are stored in folders named like " 2020-09-01 20-15 NameoftheRecording ". The prescript creates the folder and the .nfo file, copies the poster and thumbnail. When the recording is finished or stopped the postsript replaces the .nfo file with an updated one and (tries to) make a snapshot of the video file and replaces the thumbnail.
Settings in tvheadend-configuration-recording:
Pre-processor command: /home/hts/prescript "%c" "%t" "%s" "%p" "%S" "%E" "%d"
Post-processor command: /home/hts/postscript "%f" "%b" "%c" "%t" "%s" "%p" "%S" "%E" "%d"
For me, the most important feature in my environment is, that there is no need for kodi to run for a recording at all, and it is so easy to add a movie or show to my recordings just by creating a folder, the .nfo and the .tbn file with the help of small bash scripts. You will need the Texture Cache Maintenance utility from MilhouseVH to scan und update the kodi library.
A warning: the scripts are full of crap, redundant code, insufficient comments and other annoying problems. But perhaps you may find some useful tips. Feel free to use it!

Hermann

prescript (2.71 KB) prescript Pre-processor command script
postscript (3.08 KB) postscript Post-processor command script
    (1-1/1)