mpd-upload-favs: include # of songs
now-playing: more detailed info
mpd-upload-favs: upload to new seirdy.one website
A collection of useful MPD scripts, written in bashism-free POSIX shell.
media-control
media-control
wraps Playerctl and
mpc. If MPD is running, this "translates"
Playerctl commands (play-pause
, previous
, next
) to mpc commands; otherwise, it
forwards commands to Playerctl. This is useful for binding XF86Audio*
keys to prioritize MPD
over other MPRIS players.
When forwarding commands to Playerctl, it adds $HOME/.local/lib
to
$LD_LIBRARY_PATH
and $GI_TYPELIB_PATH
if Playerctl has been installed with prefix
$HOME/.local
start-music
and stop-music
start-music
starts MPD and mpDris2. stop-music
stops these, as well as
kunst,
cava,
ncmpcpp,
clerk,
cantata-dynamic,
and projectM.
MPD, mpDris2, and cantata-dynamic are managed by Systemd. Yes, I know, I know...
Scripts in the "smart-playlists" directory utilize MPD's pseudo-standard "rating" sticker, taking values from 1-10. Programs such as cantata, gmpc, ncmpy, and clerk use this sticker.
mpd-playlist-above-rating
takes an integer argument from 0-10, and outputs a
playlist containing tracks above the given rating.
mpd-playlist-unrated
outputs a list of tracks without a "rating" sticker. This is
useful for listening to music in your library you haven't heard yet.
mpd-playlist-smart
generates a playlist skewed towards your favorite tracks,
intended to be played with shuffle on. The playlist is built according to one rule:
the number of times a track appears is equal to its rating minus 5 (or 0, whichever
is greater). As a result, tracks must contain a rating of at least 6 to be added.
Tracks rated 6/10 appear once, while tracks rated 10/10 appear four times. The higher
you rate a track, the more likely it is to be played on shuffle. It requires
mpd-playlist-above-rating
.
Scripts in the now-playing
directory operate on the current track. They display the
currently-playing track with some extra info, get/set the track's rating and other
stickers, etc.