Commit graph

1 commit

Author SHA1 Message Date
ab5cdb87a9 feat(channels): store channel profiles in local SQLite with CRUD API
Replace the committed channels/<slug>.json files as the runtime source of
truth with a local SQLite database at the repo root (clipwright.db),
overridable via CLIPWRIGHT_DB. Existing JSON profiles are imported once on
first bootstrap, then the store is authoritative.

- add clipwright/storage/channel_profiles.py (stdlib sqlite3, WAL + lock)
- add Profile/TitleRules/ThumbnailRules.to_dict() for round-tripping
- load_profile/list_profiles read the store; channels_dir stays a file seam
- /api/channels CRUD plus import/export endpoints
- untrack channels/*.json, ignore the DB files
- seed a temp DB in tests/conftest.py
2026-10-06 11:54:29 +01:00