Shell Person Help me keep the shell people alive.

22Apr/103

MPC Script – Quickly Find and Play by Album

This is a simple script for MPD & MPC users. It allows you to quickly queue and play an album. I name the script "album" and put it in ~/bin (which is included in my $PATH).

#!/bin/bash
## Shortcut to search, add, and play an album (after clearing current playlist).
## Use -a (for "add") to add the album to the playlist without clearing current playlist.

if [ $1 = -a ]
then
shift
mpc search album "$*" | mpc add ; mpc play
exit
fi

mpc clear
mpc search album "$*" | mpc add ; mpc play