Skip to main content

Fetch synced .lrc lyrics from lrclib.net for beets

Project description

beets-getlrc

A beets plugin that downloads synced .lrc lyric files for your music library.

What does this do?

Some digital audio players (like the Sony Walkman, HiBy R3, Shanling M0 Pro, FiiO devices, etc.) can display synced lyrics — the kind that scroll line-by-line as the song plays. However, they usually require a separate .lrc file stored right next to each track.

Beets already has a built-in lyrics plugin that fetches plain-text lyrics and stores them directly inside your library database. beets-getlrc fills a different gap: it fetches synced .lrc files from lrclib.net and saves them as sidecar files directly alongside your FLAC or MP3 files.

Installation

If you installed beets with pip:

pip install beets-getlrc

If you installed beets with pipx (recommended):

pipx inject beets beets-getlrc

Configuration

Add getlrc to your beets configuration file (config.yaml)

plugins:

  • getlrc
  • ... your other plugins

adjust the options as desired:

Parameter Default Value Description
auto yes If it fetches lrc files automatically on import
overwrite no If it looks to replace lrc files already existing files
timeout 30 Seconds until timeout
retries 3 How many times it retries
delay 0.5 How long it waits before lookups (Seconds)
cache_results yes Remember lookups in the beets database so it does not look for files its already checked
recheck_days 30 How many days before retrying a song that it already looked for and cached
stats yes Print a summary of the lrc files found
progress yes Show per-track progress and progress bar in the command output
workers 1 Use multiple threads for faster fetching; set higher for network-bound workloads

Usage

Run it manually any time with the beet getlrc command:

Command Description
beet getlrc Fetch lyrics for all tracks in your library
beet getlrc beatles Only fetch for tracks matching "beatles"
beet getlrc -a beatles Fetch for albums matching "beatles"
beet getlrc -f Force overwrite existing .lrc files
beet getlrc -p Pretend mode — shows what would be fetched without writing anything

How it Works

  1. The plugin looks for the artist and other tags in the metadata
  2. it looks for the lyrics at lrclib.net
  3. if found, it adds them to the folder using the same name as the music file

Example

Code

beet getlrc wetleg
getlrc: No synced lyrics: Wet Leg - Wet Leg - Being in Love
getlrc: Created: Wet Leg - Wet Leg - Chaise Longue

Resulting Directory Structure

text ├── Being in Love.flac ├── Chaise Longue.flac └── Chaise Longue.lrc <-- Created by beets-getlrc

Requirements

  • beets 2.0.0 or newer
  • python 3.9 or later
  • internet

Notes

  • This only fetches synced lyrics, so if lrclib.net does not have them, then no lrc files will be created.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

beets_getlrc-0.1.9.tar.gz (7.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

beets_getlrc-0.1.9-py3-none-any.whl (8.1 kB view details)

Uploaded Python 3

File details

Details for the file beets_getlrc-0.1.9.tar.gz.

File metadata

  • Download URL: beets_getlrc-0.1.9.tar.gz
  • Upload date:
  • Size: 7.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for beets_getlrc-0.1.9.tar.gz
Algorithm Hash digest
SHA256 a1b22f4462838a93716a63eebc87f31b877e9d9f49e7bc3c55d436c20d9a2b97
MD5 1dadd997a53b5fd7168c20b700e1ce04
BLAKE2b-256 33d0578934e2377aca021a82d1602b0a7a345f3a3c7db55cf8de2aa64f5f39eb

See more details on using hashes here.

File details

Details for the file beets_getlrc-0.1.9-py3-none-any.whl.

File metadata

  • Download URL: beets_getlrc-0.1.9-py3-none-any.whl
  • Upload date:
  • Size: 8.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for beets_getlrc-0.1.9-py3-none-any.whl
Algorithm Hash digest
SHA256 6a9b7da236fef2bb6523bdec57d3cb1b7894e9985af6ed6f36ef19f8b4282ccd
MD5 e4426108793fcba2ace49910e83e95ec
BLAKE2b-256 6679b2f988e888f75f7d69bdf61050e9e830298c4bb200b93265e8688b45f7f1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page