diff --git a/.config/sxhkd/sxhkdrc b/.config/sxhkd/sxhkdrc index 2e49a7d..6deafa7 100644 --- a/.config/sxhkd/sxhkdrc +++ b/.config/sxhkd/sxhkdrc @@ -15,9 +15,11 @@ super + a; {g,k,l,i} {gimp,keepassxc,libreoffice,inkscape} super + {_,ctrl +} m - rofi-mpd {-a,-s} + rofi-mpd {-a,-s} && refbar super + apostrophe mpdqueue +XF86Tools + mpdrandom {Prior,super + x} slock super + z diff --git a/.local/bin/scripts/mpdrandom b/.local/bin/scripts/mpdrandom new file mode 100755 index 0000000..635231f --- /dev/null +++ b/.local/bin/scripts/mpdrandom @@ -0,0 +1,13 @@ +#!/bin/sh + +# Add random song to mpd queue. + +song="$(mpc listall | shuf -r -n 1)" + +mpc add "$song" + +notify-send -u normal "MPD added random song" "$( + mpc -f "%artist% - %title%" find filename "$song" +)" + +mpc play>/dev/null