Kodi Community Forum

Full Version: write a .watched file
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

I have had a look and cannot find an add-on that does not do what I want....does anyone know of a way to do this or and add-on that does this?

After I have watched a movie or an episode on Kodi I would like it to write a .watched file to the same location as the file I just watched:

\\Multimedia\TV_Series\Drama\Game of Thrones\Season 07
Game of Thrones S07E06.mkv
Game of Thrones S07E06.mkv.watched
Game of Thrones S07E07.mkv
Game of Thrones S07E07.mkv.watched

\\Multimedia\Marvel_Heroes
Guardians of the Galaxy Vol 2.mkv
Guardians of the Galaxy Vol 2.mkv.watched

I would like this as PLEX, KODI and YAMJ all pick up these as watched files.

Thanks,
Your only option as far as I can see is to write your own service addon.
Kodi won't pick up your watched file though.  No idea about the others.
(2019-05-06, 12:13)trogggy Wrote: [ -> ]Your only option as far as I can see is to write your own service addon.
Kodi won't pick up your watched file though.  No idea about the others.

Hi,

Thanks for the reply. This is how I have my setup and have for years when I used YAMJ and did not expect Kodi to read these but it did. I have 100’s of shows and movies and when I first ran Kodi library all my watched movies and shows were automatically picked up.

I will look into own service add-ons but not sure I will have the skills required to write an add-on.

Thanks
(2019-05-06, 12:27)jmuk Wrote: [ -> ]This is how I have my setup and have for years when I used YAMJ and did not expect Kodi to read these but it did. I have 100’s of shows and movies and when I first ran Kodi library all my watched movies and shows were automatically picked up. 
To be honest I wasn't aware kodi would read a .watched file even on an initial scan.  But even if that's the case it won't pick up changes in a folder unless a movie / tv series is refreshed.  It would be easy enough to check this, just try making a couple of files manually and placing them next to files scanned to your library.  Start kodi and I'll be amazed if you see a change in watched status.
(2019-05-06, 12:34)trogggy Wrote: [ -> ]
(2019-05-06, 12:27)jmuk Wrote: [ -> ]This is how I have my setup and have for years when I used YAMJ and did not expect Kodi to read these but it did. I have 100’s of shows and movies and when I first ran Kodi library all my watched movies and shows were automatically picked up. 
To be honest I wasn't aware kodi would read a .watched file even on an initial scan.  But even if that's the case it won't pick up changes in a folder unless a movie / tv series is refreshed.  It would be easy enough to check this, just try making a couple of files manually and placing them next to files scanned to your library.  Start kodi and I'll be amazed if you see a change in watched status. 
Hi,

No you are right - that did not work.....must have been getting confused with Plex (moved from a popcornhour and YAMJ - I thought Plex and Kodi both updated with watched files, but mut have been Plex only)

Do you know if Kodi can read any viewed/watch files/folders/data?
Kodi at least writes the watched state into the specific video database. Those are also exported if you export your db into nfo files. The watched states can also be imported from those nfo files by using the advancedsettings.xml file. Please see: https://kodi.wiki/view/Advancedsettings....deolibrary

But I'm generally not sure what you want to achieve in the end
(2019-05-07, 08:35)DaVu Wrote: [ -> ]Kodi at least writes the watched state into the specific video database. Those are also exported if you export your db into nfo files. The watched states can also be imported from those nfo files by using the advancedsettings.xml file. Please see: https://kodi.wiki/view/Advancedsettings....deolibrary

But I'm generally not sure what you want to achieve in the end

Hi, thanks looks good....the goal is to have the watched episodes/movies updated on all platforms. It may not be possible but would like Plex, YAMJ and Kodi to all have up to date viewed/watched information.

I will have a look at that and try a test.

Thanks
If we are talking about local file playback and you want your watched states synced on multiple devices, you should also take a look at using a MySQL database:

https://kodi.wiki/view/MySQL