mirror of
https://github.com/lrnselfreliance/wrolpi.git
synced 2026-12-04 13:49:57 -05:00
tags.yaml declares three sections (Tags, tagged files, tagged Zim entries), so its import reads the file once, diffs it against a snapshot, and writes only the differences, with the file's version, in one write. An unchanged import writes nothing. A removed Tag is deleted with its tagged files and Zim entries; a Collection using it loses only the Tag. A removed tagged file or Zim entry is untagged. A tagged file whose Tag the config does not list is skipped. prepare finds files without a FileGroup on disk, skips missing ones before the write, moves Zim entries of a replaced Zim to the newest one, and maps a file named by a secondary member to its group; the config is then saved with the database's paths. Moving a tagged FileGroup counts as a tags.yaml change (ORM, the bulk move, and a refresh that changes the primary file), so a restart before the save does not untag it. Sections can define `same` (a tagged file without a date matches any date), and prepare can count skipped rows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| test | ||
| __init__.py | ||
| api.py | ||
| config.py | ||
| errors.py | ||
| lib.py | ||
| models.py | ||
| reorganize.py | ||
| schema.py | ||
| sync.py | ||
| types.py | ||