yolo-mpd

Various music-related tweaks/tips/scripts. Includes fuzzy selection of artist/genre/album script and albumart in the console script


Project maintained by uriel1998 Hosted on GitHub Pages — Theme by mattgraham

yolo-mpd

Various MP3 and MPD tweaks, tips, tools, and scripts I have put together or found and then tweaked.

This README documents every Bash script in the repository root. Legacy scripts that were moved into old_versions/ are not covered here except where they matter for migration notes.

Script Index

Library repair and tagging

Now playing displays

Playback control and integration

Streaming, playlists, and cover export

Legacy note

Common assumptions

Most scripts assume:

Several scripts also keep scratch files in ${XDG_CACHE_HOME:-$HOME/.config}/yadshow.

Script Reference

f_fix_covers.sh

Repairs album art for MP3 directories by comparing cover.jpg, folder.jpg, and embedded artwork, optionally prompting for a choice, searching online, and embedding the selected result back into the files.

Important behavior:

Usage:

./f_fix_covers.sh -d /path/to/music [options]

Dependencies:

rerun_non_square_covers.sh

Scans a root tree for cover.jpg files whose width and height differ, then reruns f_fix_covers.sh on those directories only.

Usage:

./rerun_non_square_covers.sh [--dry-run] ROOT_DIR

Dependencies:

f_fix_lyrics.sh

Recursively scans MP3 files and creates missing synchronized (.lrc) and plain-text (.txt) lyric sidecars.

Important behavior:

Usage:

./f_fix_lyrics.sh [--loud] [--force] [--delay SECONDS] [--base DIRECTORY]

Dependencies:

bpmtoolshelper.sh

Computes BPM values with bpm-tag, writes them with eyeD3, and restores the original file timestamp afterward.

Behavior:

Usage:

./bpmtoolshelper.sh [--save] [--skip] [--quiet]

Dependencies:

mp3gainhelper.sh

Runs loudgain per directory while preserving file timestamps after modification.

Behavior:

Usage:

./mp3gainhelper.sh [--noclobber] [DIRECTORY ...]

Dependencies:

edit_current_mp3tags.sh

Locates the currently playing local file across supported players and prints the resolved on-disk file path.

This is mainly a helper for tag-editing workflows that already know what to do with the returned path.

Usage:

./edit_current_mp3tags.sh

Dependencies:

yad_show_mpd.sh

Shows the current cover art and track name in a YAD popup window.

Behavior:

Usage:

./yad_show_mpd.sh

Dependencies:

terminal_covers.sh

Shows current cover art in a terminal, using one of several terminal-friendly image renderers.

Behavior:

Usage:

./terminal_covers.sh [--notify]

Dependencies:

terminal_lyrics.sh

Shows lyrics for the current track in the terminal.

Behavior:

Usage:

./terminal_lyrics.sh

Dependencies:

show_covers_w3mimage.sh

Watches MPD for player events and passes the resolved cover image to w3mimg.sh.

Behavior:

Usage:

./show_covers_w3mimage.sh

Dependencies:

terminal_multiplexer.sh

Creates or reattaches to a tmux session named MPD with panes for:

Usage:

./terminal_multiplexer.sh

Dependencies:

mediakey.sh

Uses MPRIS to send playback controls to active players, with optional player selection.

Supported actions:

Supported player selectors:

Usage:

./mediakey.sh [p|n|b|s|z] [PLAYER]

Dependencies:

mediakey_no_checking.sh

Simpler mediakey variant that assumes the selected player or active MPRIS players are available and skips some of the extra presence checks from mediakey.sh.

Usage:

./mediakey_no_checking.sh [p|n|b|s|z] [PLAYER]

Dependencies:

nowplaying_to_maubot.sh

Builds a “now playing” composite image, sets it as the desktop background with feh, and posts the current track title to a Maubot webhook.

Behavior:

Required configuration in maubot_vars.env:

Usage:

./nowplaying_to_maubot.sh

Dependencies:

stream_to_mpd.sh

Takes a stream URL or bookmark, resolves the underlying playable URL, and sends it to one of three destinations.

Destinations:

Usage:

./stream_to_mpd.sh [--host PASSWORD@HOST] [--mpd|--playlist|--native] [--bookmarks] STREAM

Dependencies:

update_playlists_for_mpd.sh

Converts .m3u playlists from a Clementine playlist directory into MPD-style relative-path playlists.

Behavior:

Usage:

./update_playlists_for_mpd.sh

Dependencies:

webserver_covers.sh

Mirrors only cover image files into a webserver tree while preserving directory structure.

Behavior:

Usage:

./webserver_covers.sh

Dependencies:

Some AI/LLM Use

button_some-ai-used

The code in this repository has been to some degree written or altered by an AI tool with human supervision. This may include one or more of the following: documentation, locating bugs, or commit messages; in this repository it’s been bugsquashing and reorganizing and updating the documentation.


Steven Saus injects people with radioactivity for his day job, but only to serve the forces of good.
Mostly.