Skip to content

Instantly share code, notes, and snippets.

@Allavaz
Created May 28, 2023 20:31
Show Gist options
  • Save Allavaz/55f4444876fa481ab9af7ead052f403d to your computer and use it in GitHub Desktop.
Save Allavaz/55f4444876fa481ab9af7ead052f403d to your computer and use it in GitHub Desktop.
enqueue songs in mpd using fzf
song=$(mpc listall | fzf -i)
if [ -n "$song" ]; then
mpc add "$song"
else
exit 1
fi
if [ -z "$(mpc current)" ]; then
mpc play "$(mpc playlist | wc -l)"
else
mpc playlist
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment