Skip to content

Using episode.nfo Templates

Kyle Johnson edited this page Apr 29, 2020 · 8 revisions

Why Use Local episode.nfo Files

Two reasons.

  1. Sometimes you will have a show that has no season or episode information available from your DVR. In cases like that the script will create a Season 0 episode (i.e. S01E01) so that it can scan the episode into Kodi. If there is already a S01E01 episode in a show's directory, the script will find the next available episode number and use it.
  2. Sometimes (really, often) the websites for TV Shows aren't updated until after a show has aired and somebody puts descriptions in. Or the websites are down for days at a time. Without the episode.nfo file, Kodi won't be able to import a show that isn't in one of the external databases (or while the websites are down). Using the episode.nfo file guarantees that the script can get the show into Kodi right after it's recorded.

Setting Up episode.nfo Files

The first time you run the script, it will create a folder called fixes where you can create template episode.nfo files for each show that is recorded. There will be one folder in fixes already called default that will be used if you don't create one specific to a show. You can edit that if you want, as it will never be overwritten (only recreated if you delete it). For any other show you can add a folder with the TV show name and then a file called episode.nfo in the show's folder.

Creating/Editing epsiode.nfo Files

An episode.nfo file can have any XML value that is available in Kodi. To include information from your DVR, you can add certain values to the epsiode.nfo template file.

[TITLE]
The title of the episode. If no title is given, the script will use the current date as an episode title in the format yyyy-mm-dd.

[SEASON]
The season number of the episode. If no season is given, the script will use Season 0.

[EPISODE]
The episode number of the episode. If Season 0 is in use or if no episode is given then the script uses Season 0 with an appropriate episode number based on the files in the show's directory.

[DESC]
The plot of the episode.

[AIRDATE]
The date the recording file was created. If that fails, then this will be the date on which the script was run.

For reference, this is what the default episode.nfo file looks like this:

<episodedetails>
    <title>[TITLE]</title>
    <season>[SEASON]</season>
    <episode>[EPISODE]</episode>
    <plot>[DESC]</plot>
    <playcount>0</playcount>
    <lastplayed></lastplayed>
    <aired>[AIRDATE]</aired>
</episodedetails>
Clone this wiki locally