feat: add write --clear to remove otag's tags from files

This commit is contained in:
randogoth 2026-10-24 22:24:39 +03:00
parent c1bc07ffeb
commit 8a19f5f0af
11 changed files with 193 additions and 29 deletions

View file

@ -102,11 +102,12 @@ $ otag purge old-project/
`scan` (`s`) reads tags that are embedded in files and adds them to their entries, in the given folder (default: current) and its subdirectories.
`write` (`w`) writes the entry of a file into the file itself, using the named plugin.
`write` (`w`) writes the entry of a file into the file itself, using the named plugin. It replaces what the plugin stored before, so tags removed with `otag remove` disappear from the file on the next `write`. `-c` (`--clear`) removes the plugin's tags from the file instead, e.g. after all tags were removed; it is never done implicitly, because a file without entry may also be one otag never tagged.
```
$ otag scan music/
$ otag write id3 song.mp3
$ otag write --clear id3 song.mp3
```
| Plugin | File types | Where the tags are stored |