2013-10-18, 22:04
Version 1.0.2
* Add: New options, set and testset, to allow limited modification of movie, tvshow, episode, musicvideo, artist, album and song library items. Use testset to verify the request is valid before performing any update.
Example:
to set clearlogo, clearart, playcount and tag fields for the movie with the movieid 312.
Most basic fields can be specified (eg. plot, trailer, playcount, art etc. - see JSON API v6 for details of which fields can be specified on the Set*Details calls). However modification of more complex fields - such as cast, streamdetails etc. - is not supported by JSON. Also, the file field cannot be modified.
In addition, for the sake of efficiency, batches of data can also be read from stdin. In the following example, the two movies and one tv show are to be updated. The fields being updated are specified by the "items" list within each movie or tv show (in each case, setting new clearart and clearlogo artwork urls).
The file update.dat contains the following information:
and to apply the update:
* Added of tools/mktools.py which can read in the output from "texturecache.py jd movies" or "texturecache.py jd tvshows" and convert remote artwork to local. It will retrieve the original remote artwork from the web site and write it into your media directory. Output from mklocal.py can be fed into "texturecache,py set" to re-point your media library so that it now uses the local artwork. Run mklocal.py in different ways to download remote artwork, or just assign existing local artwork to your media library. See --help for more details.
* Add: New options, set and testset, to allow limited modification of movie, tvshow, episode, musicvideo, artist, album and song library items. Use testset to verify the request is valid before performing any update.
Example:
Code:
./texturecache.py set movie 312
art.clearlogo "nfs://myserver/movies/thismovie-logo.png" \
art.clearart "nfs://myserver/movies/thismovie-clearart.png" \
playcount 12 \
trailer "http://www.totaleclips.com/Player/Bounce.aspx?eclipid=e121648&bitrateid=449&vendorid=102&type=.mp" \
tag "['horror', 'zombies']"
to set clearlogo, clearart, playcount and tag fields for the movie with the movieid 312.
Most basic fields can be specified (eg. plot, trailer, playcount, art etc. - see JSON API v6 for details of which fields can be specified on the Set*Details calls). However modification of more complex fields - such as cast, streamdetails etc. - is not supported by JSON. Also, the file field cannot be modified.
In addition, for the sake of efficiency, batches of data can also be read from stdin. In the following example, the two movies and one tv show are to be updated. The fields being updated are specified by the "items" list within each movie or tv show (in each case, setting new clearart and clearlogo artwork urls).
The file update.dat contains the following information:
Code:
[
{
"libraryid": 1,
"items": {
"art.clearart": "nfs://192.168.0.3/mnt/share/media/Video/MoviesSD/9 (2009)[DVDRip]-clearart.png",
"art.clearlogo": "nfs://192.168.0.3/mnt/share/media/Video/MoviesSD/9 (2009)[DVDRip]-logo.png"
},
"type": "movie",
"title": "9"
},
{
"libraryid": 358,
"items": {
"art.clearart": "nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Classics/12 Angry Men (1957)[BDRip]-clearart.png",
"art.clearlogo": "nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Classics/12 Angry Men (1957)[BDRip]-logo.png"
},
"type": "movie",
"title": "12 Angry Men"
},
{
"libraryid": 115,
"items": {
"art.clearart": "nfs://192.168.0.3/mnt/share/media/Video-Private/TVShows/Arrested Development/clearart.png",
"art.clearlogo": "nfs://192.168.0.3/mnt/share/media/Video-Private/TVShows/Arrested Development/logo.png"
},
"type": "tvshow",
"title": "Arrested Development"
}
]
Code:
cat update.dat | ./texturecache.py set
* Added of tools/mktools.py which can read in the output from "texturecache.py jd movies" or "texturecache.py jd tvshows" and convert remote artwork to local. It will retrieve the original remote artwork from the web site and write it into your media directory. Output from mklocal.py can be fed into "texturecache,py set" to re-point your media library so that it now uses the local artwork. Run mklocal.py in different ways to download remote artwork, or just assign existing local artwork to your media library. See --help for more details.