Configuration

~/.config/mpv/mpv.conf

input-ipc-server=~~/socket

Commands

Play / Pause

echo cycle pause | socat - ~/.config/mpv/socket

You can add a key-binding to XF86AudioPlay and XF86AudioPause media controls.

Next Track

echo playlist-next | socat - ~/.config/mpv/socket

You can add a key-binding to XF86AudioNext media control.

Previous Track

echo playlist-prev | socat - ~/.config/mpv/socket

You can add a key-binding to XF86AudioPrev media control.