TUI app for tracking episodes in local series directories
Project description
MPV Tracker
Terminal UI and CLI tool for tracking watched episodes in local series or anime directories.
It keeps a global library index in SQLite and writes per-series playback state
inside the tracked directory itself in .mpv-tracker.json.
Links
- PyPI: https://pypi.org/project/mpv-tracker/
- Project metadata: pyproject.toml
- README: README.md
Installation
Python 3.12 or newer is required.
Run Without Installing Globally
Use uvx to run the latest published version directly:
uvx mpv-tracker
Install With pipx
pipx is a good fit if you want an isolated global command:
pipx install mpv-tracker
mpv-tracker
Install With pip
If you prefer plain pip, install the package into your current environment:
pip install mpv-tracker
mpv-tracker
If you want a user-local install without pipx, you can also use:
python -m pip install --user mpv-tracker
mpv-tracker
TUI
Run mpv-tracker with no arguments to open the Textual interface.
The TUI is built around a few main screens:
Library: browse tracked series, open details, add/edit/remove entries, open MAL account settings, and open application settings.Series Detail: inspect watched count, resume state, MAL linkage, playback preferences, and episode-level progress.MAL: authenticate in the browser, inspect the current MAL account, and manage linked anime metadata.
Typical workflow:
- Launch the app with
mpv-tracker - Press
ato add a series directory - Press
Enteron a series to open the detail view - Select an episode and press
porEnterto play it withmpv - Return to the detail view to inspect updated progress, MAL metadata, and score controls
Useful TUI features:
- Per-series chapter-start preferences for fresh episodes
- MAL browser authentication from inside the TUI
- Linked MAL anime metadata with cached score, rank, popularity, synopsis, titles, genres, studios, and related info
- Direct MAL score updates from the detail view
- Browser-open actions for MAL profile and anime pages
- Built-in help screen on
hor?
Progress is persisted through the same .mpv-tracker.json state file used by
the CLI.
Showcase
Demo
This repo includes vhs tapes you can use to generate short terminal demos:
demo/showcase.tape: main TUI flow using a tracked MAL-linked seriesdemo/mal-auth.tape: MAL settings/authentication screen walkthroughdemo/add-series.tape: add a new MAL-linked series from inside the TUI
Example commands:
vhs demo/showcase.tape
vhs demo/mal-auth.tape
vhs demo/add-series.tape
CLI Commands
add
- Prompts for title, directory, and optional slug when not passed as arguments.
- Stores the tracked series in a SQLite library database.
list
- Shows every tracked series with watched episode count vs total discovered files.
- Shows the currently resumed episode and time offset when present.
watch <slug> [episode]
- Resolves the tracked series by slug.
- Starts
mpvon the tracked directory as a playlist and jumps to the resumed episode, next unwatched episode, or the explicitly selected episode. - Polls MPV over its IPC socket and updates
.mpv-tracker.jsonroughly once per second so resume data survives abrupt closes.
Episode discovery currently scans only the top level of the tracked directory and sorts video files by filename.
Development
This project uses uv for dependency and virtualenv management. Useful commands:
- Create/activate a virtualenv and install dependencies:
uv sync - Run the linter:
uv run ruff check - Run type checks:
uv run mypy - Install local helpers:
uv sync --group local - Run everything in one go:
uv run ruff check && uv run mypy
Pre-commit
uv run prek install
Packaging
Builds are handled by hatchling through uv:
uv build
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mpv_tracker-1.4.0.tar.gz.
File metadata
- Download URL: mpv_tracker-1.4.0.tar.gz
- Upload date:
- Size: 40.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.10 {"installer":{"name":"uv","version":"0.10.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Manjaro Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7d3a8e3ebfade1ff771d5cf67c2dbef67e6db1ad428da9378797c7a6f1d18738
|
|
| MD5 |
82467d9d8cd608185965c70858a1a4d3
|
|
| BLAKE2b-256 |
f99d43be472b0af18c1d2a5c885a665d00e6f59b93cca6ff868f0e47984a4fb8
|
File details
Details for the file mpv_tracker-1.4.0-py3-none-any.whl.
File metadata
- Download URL: mpv_tracker-1.4.0-py3-none-any.whl
- Upload date:
- Size: 46.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.10 {"installer":{"name":"uv","version":"0.10.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Manjaro Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
779c4f0438be4c0f565475fbce4c8e1847945e4e0156e82d7185bf9dba4d2409
|
|
| MD5 |
3bcd46c47731f716f0f9ddcfbbe78a89
|
|
| BLAKE2b-256 |
4e30f1cb90c906754c89df4785e86eeb759522b5a94f8306d8b8454dc84c28f8
|