Skip to content

Commit d8ee2d2

Browse files
committed
Add doc for using MusicBrainz DB
1 parent 2ad9b11 commit d8ee2d2

1 file changed

Lines changed: 100 additions & 0 deletions

File tree

README.md

Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,99 @@ accordingly.
6565

6666
Delete the whole file content before quitting to cancel the operation.
6767

68+
## Setting tags with MusicBrainz
69+
70+
`htagcli` can fetch tags from [MusicBrainz][musicbrainz] to automatically set
71+
the tags of your files. To do this, one can search for an album/artist using
72+
the `search` command:
73+
74+
```
75+
$ htagcli search --album repeater --artist fugazi
76+
Searching: "fugazi" - "repeater"
77+
78+
3 releases found
79+
80+
1. ID: 37e6a462-1417-45dc-9d88-4ef9aff4bc19
81+
Artist: Fugazi
82+
Album: Repeater
83+
Year: 2005
84+
Discs: 1
85+
Tracks: 14
86+
87+
Disc 1: Tracks: 14
88+
89+
1. Turnover
90+
2. Repeater
91+
3. Brendan #1
92+
...
93+
```
94+
95+
If the search is run against an existing album, `htagcli` will show similarity
96+
values to help you choose the best match. In the following case, the first
97+
result shows a low similarity because the number of tracks is different from
98+
the actual album. The second result is a perfect match.
99+
100+
```
101+
$ htagcli search ./repeater/
102+
Searching: "Fugazi" - "Repeater"
103+
104+
3 releases found
105+
106+
1. ID: 37e6a462-1417-45dc-9d88-4ef9aff4bc19 (87%)
107+
Artist: Fugazi (100%)
108+
Album: Repeater (100%)
109+
Year: 2005 (1990)
110+
Discs: 1
111+
Tracks: 14 (11)
112+
113+
Disc 1: (79%) - Tracks: 14 (11)
114+
115+
1. Turnover (100%)
116+
2. Repeater (100%)
117+
3. Brendan #1 (100%)
118+
4. Merchandise (100%)
119+
5. Blueprint (100%)
120+
6. Sieve-Fisted Find (100%)
121+
7. Greed (100%)
122+
8. Two Beats Off (100%)
123+
9. Styrofoam (100%)
124+
10. Reprovisional (100%)
125+
11. Shut the Door (100%)
126+
12. Song #1
127+
13. Joe #1
128+
14. Break-In
129+
130+
2. ID: 00baa173-29db-33a9-af6d-fe109e53a211 (100%)
131+
Artist: Fugazi (100%)
132+
Album: Repeater (100%)
133+
Year: 1990
134+
Discs: 1
135+
Tracks: 11
136+
137+
Disc 1: (100%) - Tracks: 11
138+
139+
1. Turnover (100%)
140+
2. Repeater (100%)
141+
3. Brendan #1 (100%)
142+
4. Merchandise (100%)
143+
5. Blueprint (100%)
144+
6. Sieve-Fisted Find (100%)
145+
7. Greed (100%)
146+
8. Two Beats Off (100%)
147+
9. Styrofoam (100%)
148+
10. Reprovisional (100%)
149+
11. Shut the Door (100%)
150+
151+
...
152+
```
153+
154+
Once you found a matching release, you can set the tags using the ID of the
155+
release:
156+
157+
```
158+
$ htagcli set --id 00baa173-29db-33a9-af6d-fe109e53a211 ./repeater/
159+
```
160+
68161
## Configuration
69162

70163
The next commands require a configuration file. You can generate [a default
@@ -96,6 +189,12 @@ collection clean and well-organized. Available checks include:
96189
- Cover file: Checks the presence of a cover image in the disc directory.
97190
Also verifies that the cover image size is within specified limits.
98191
- Disc tags: Checks that the tags from all files in a disc are the same
192+
- Track numbers: Checks that the track numbers are sequential and start
193+
from 1
194+
- Album level:
195+
- Disc numbers: Checks that the disc numbers are sequential and start from
196+
1
197+
- Album tags: Checks that the tags from all files in an album are the same
99198
- Artist level:
100199
- Genre: Ensures that all tracks from an artist share the same genre
101200

@@ -158,6 +257,7 @@ This project uses [htaglib] as the underlying library to manipulate audio file.
158257

159258
[demo]: ./demo.png
160259
[htaglib]: https://github.com/mrkkrp/htaglib
260+
[musicbrainz]: https://musicbrainz.org/
161261
[nix]: https://nixos.org/
162262
[releases]: https://github.com/jecaro/htagcli/releases
163263
[status-nix-png]: https://github.com/jecaro/htagcli/workflows/nix/badge.svg

0 commit comments

Comments
 (0)