htagcli
htaglib is a command-line tool for viewing and editing tags in audio files. It also includes utilities to organize your music collection in various ways. All audio formats supported by [taglib] are supported.
![demo][demo]
Installation
A static binary is available in the [releases][releases] page. It should work on any linux distribution. For Arch Linux users, the package is available on the [AUR][status-aur]. For nix users, an overlay is available in the flake file.
Basic usage
The basic syntax of htagcli is:
$ htagcli COMMAND [OPTIONS] [FILE|DIRECTORY]You can pass as many files or directories as needed. Directories are processed recursively. For directories, only audio files with extensions supported by [taglib] are considered. You can change this with the --extension option.
htagcli supports the --help option at any level. When in doubt, use it to get detailed usage information.
Tag operations
To display the tags of one or more files, use the get command:
$ htagcli get ./data/sample.mp3
File: /path/to/htagcli/data/sample.mp3
Title: title
Artist: artist
Album Artist: albumartist
Album: album
Genre: genre
Year: 2055
Track: 7To edit tags, use the set command. For example, to change the genre for all files in an album:
$ htagcli set --genre "Avant-garde" ./dataIt is also possible, to edit the tags in your $EDITOR with the edit command:
$ htagcli edit ./data/sample.mp3This opens the tags of the specified files in your default text editor. Edit the tags as needed, then save and quit the editor. The changes will be applied accordingly.