Mpd extensions

From wikinotes
Revision as of 18:07, 7 November 2021 by Will (talk | contribs) (Created page with "= python = <blockquote> <source lang="bash"> sudo pip install python-musicpd </source> <source lang="python"> import musicpd c = musicpd.MPDClient() c.connect('localhost', 66...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

python

sudo pip install python-musicpd
import musicpd
c = musicpd.MPDClient()
c.connect('localhost', 6600)
c.find('genre', 'Jazz')
c.close()

netcat

echo "currentsong" | nc 127.0.0.1 6600
echo "find genre Indie" | nc 127.0.0.1 6600 | grep -i "^Artist" | uniq -i