TVthe(k)Index
Generates an index of tvthek/mediathek downloaded content and queries TMDB for the meta data
Example
Usage (version 0.5.0)
Prerequisites
Register at TMDB and get an API key.
from binary (windows)
-
download binaries from packages and rename to
tvthekidx.exe -
create database
tvthekidx.exe -v maintenance -d tvthek.db -a createdb
- run the indexer
tvthekidx.exe -v index -k "APIKEY" -d tvthek.db -t movies -c "TVthek" -p x:\TVThek --recursive
(insert your TMDB API key instead of APIKEY)
- generate the html file
tvthekidx.exe export -d tvthek.db -c "TVthek" -f html --title "TVthek" --output tvthek.html
-
if you add or remove content run steps 3 + 4 again
-
occasionally run database maintenance
tvthekidx.exe -v maintenance -d tvthek.db -a compressdb
from binary (linux)
-
download binaries from packages and rename to
tvthekidx -
make tvthekidx executable
chmod +x tvthekidx
- create database
./tvthekidx -v maintenance -d tvthek.db -a createdb
- run the indexer
./tvthekidx -v index -k "APIKEY" -d tvthek.db -t movies -c "TVthek" -p /mnt/TVThek/ --recursive
(insert your TMDB API key instead of APIKEY)
- generate the html file
./tvthekidx export -d tvthek.db -c "TVthek" -f html --title "TVthek" --output tvthek.html
-
if you add or remove content run steps 4 + 5 again
-
occasionally run database maintenance
./tvthekidx -v maintenance -d tvthek.db -a compressdb
from python source
-
download source code from releases
-
install requirements
pip install -e .
- create database
tvthekidx -v maintenance -d tvthek.db -a createdb
- run the indexer
tvthekidx -v index -k "APIKEY" -d tvthek.db -t movies -c "TVthek" -p /mnt/TVThek/ --recursive
(insert your TMDB API key instead of APIKEY)
- generate the html file
tvthekidx export -d tvthek.db -c "TVthek" -f html --title "TVthek" --output tvthek.html
-
if you add or remove content run steps 4 + 5 again
-
occasionally run database maintenance
tvthekidx -v maintenance -d tvthek.db -a compressdb
Global arguments
-q,--quietquiet (set verbose to 0)-v,--verboseincrease verbosity (stackable)
index arguments
-d,--databaseSQLite database file-p,--pathpath to scan for video files-k,--keyTMDB API key-t,--typecontent type (movies; tvshows not yet supported)-c,--collectioncollection name-r,--recursivescan subdirectories recursively
export arguments
-d,--databaseSQLite database file-c,--collectioncomma-separated list of collections to include-f,--formatexport format plugin (html,text); defaulthtml
HTML plugin arguments (passed after export)
--titlepage title--output,-ooutput file (defaulttvthek.html)--graphicsimage handling:embed(default, base64 inline),reference(external files),disable--skip-actorsomit the actors/crew section--skip-headeromit the top-rated and newest-additions header sections--urlhyperlink prefix for video file links (default./)
maintenance arguments
-d,--databaseSQLite database file-a,--actionone of:createdb— create a new databaseupgradedb— run schema migrations on an existing databasecompressdb— deduplicate movies and VACUUMdetecttvstations— run ML-based TV station detection on stored screenshotscleartvstations— remove all TV station assignmentsgetscreenshots— capture/backfill screenshots for files (requires-p)clearscreenshots— delete all stored screenshots
-p,--pathpath to video files (required forgetscreenshots)-c,--collectioncollection filter (optional forgetscreenshots)
tags arguments
-d,--databaseSQLite database file-a,--actionone of:list,add,delete,export-t,--tagtag name-r,--regexregular expression pattern matched against filenames--alldelete all tags (use with--action delete)
What's new in 0.5.0
- Export plugin system — export format is now selectable via
--format;htmlandtextplugins included - TV station detection — screenshots are analysed with a convolutional neural network (CNN) to identify the recording channel; logos are embedded in the HTML export
- Tags — regex-based file tagging with the new
tagssubcommand maintenancesubcommand — replacesdatabase; addsdetecttvstations,cleartvstations,getscreenshots,clearscreenshotsactions--graphicsexport option — choose between embedded base64, external file references, or disabled images- HTML export performance — ~7× faster; bulk SQL queries replace per-movie/per-file round-trips; SQLite mmap and page-cache tuning cuts system time by ~190×
- Database schema v8 — all binary attachments (posters, actor profiles, screenshots) unified in a single
attachmentstable with a composite index on(ref_id, type) - CI pipeline upgraded to Debian trixie — build image updated to
python:3-slim-trixie; test matrix updated to bookworm and trixie; win64 removed
Metadata
Release files for tvthekidx 0.5.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| tvthekidx-0.5.0.tar.gz | 5.9 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| tvthekidx-0.5.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 11.7 MB
Release files / tvthekidx-0.5.0.tar.gz
| Download URL | tvthekidx-0.5.0.tar.gz |
|---|---|
| Size | 5.9 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6a0ce25d5595fdc59caef483cd610315cf8bad21dd7664eb968b1055692b26a5
|
|
BLAKE2b-256 checksum How to use checksums |
8f3cd3fd1eddde09c8c6e6005c9a9c7e50e68d460ed3c0646272ca355218f257
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.3
|
Release files / tvthekidx-0.5.0-py3-none-any.whl
| Download URL | tvthekidx-0.5.0-py3-none-any.whl |
|---|---|
| Size | 5.8 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
52ec06661dd8b19df83ad3096a4135a415f943cba10edbc1e4159e64800f141f
|
|
BLAKE2b-256 checksum How to use checksums |
acf7af3fddeb5e1df004433c1656acdf3ce8d2cdbb4d19ec50eacbb32e66631f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.3
|