https://github.com/serial-ata/lyr
A tool to download and embed lyrics from multiple sources
https://github.com/serial-ata/lyr
lyrics lyrics-fetcher lyrics-finder lyrics-search rust
Last synced: 7 months ago
JSON representation
A tool to download and embed lyrics from multiple sources
- Host: GitHub
- URL: https://github.com/serial-ata/lyr
- Owner: Serial-ATA
- License: apache-2.0
- Created: 2022-08-01T02:46:26.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2024-07-23T20:49:22.000Z (about 1 year ago)
- Last Synced: 2025-03-25T18:54:45.796Z (7 months ago)
- Topics: lyrics, lyrics-fetcher, lyrics-finder, lyrics-search, rust
- Language: Rust
- Homepage:
- Size: 135 KB
- Stars: 12
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE-APACHE
Awesome Lists containing this project
README
# Lyr
[](https://github.com/Serial-ATA/lyr/actions/workflows/ci.yml)
[](https://crates.io/crates/lyr)
[](https://crates.io/crates/lyr)Download and embed lyrics from multiple sources.
## Sources
* [AZLyrics](https://azlyrics.com)
* [Genius](https://genius.com)
* [JahLyrics](https://jah-lyrics.com)
* [Musixmatch](https://www.musixmatch.com)NOTE: Genius currently has an issue where there will be missing newlines
between section headers, so the output may look like:```
[Verse 1]
Foo
Bar Baz
Qux
[Chorus] # Notice this header immediately follows the last line of Verse 1
```Not sure how to fix this as of now.
## Usage
Fetch and print the lyrics to stdout:
```console
$ lyr --artist="2Pac" --title="Changes"
```Try to get the artist and title from the tags in the file:
For the list of supported files see [lofty-rs](https://github.com/Serial-ATA/lofty-rs#supported-formats).
```console
# NOTE: This will add the lyrics to the tags of the file
$ lyr --input="some-music-file.mp3"
# Use the `no-embed` flag to prevent this
$ lyr --input="some-music-file.mp3" --no-embed
```Output the lyrics to a file:
```console
$ lyr --artist="2Pac" --title="Changes" lyrics.txt
```## Config
This config is stored at `$CONFIG_DIR/lyr/config.toml`.
```toml
# Default flags to append to every command
flags = ''
# The list of fetchers to use when searching for lyrics
fetchers = ['AZLyrics', 'Genius', 'JahLyrics', 'Musixmatch']
```## License
Licensed under either of
* Apache License, Version 2.0
([LICENSE-APACHE](LICENSE-APACHE) or http://www.apache.org/licenses/LICENSE-2.0)
* MIT license
([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)at your option.
## Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted
for inclusion in the work by you, as defined in the Apache-2.0 license, shall be
dual licensed as above, without any additional terms or conditions.