X-Git-Url: https://git.kaliko.me/?p=python-musicpd.git;a=blobdiff_plain;f=doc%2Fsource%2Fexamples%2Ffindadd.py;fp=doc%2Fsource%2Fexamples%2Ffindadd.py;h=922cae17cf17bf3438e297dc7803d1e5eee0889e;hp=0000000000000000000000000000000000000000;hb=c7b2fbbb9689a180f220322b21e2b0bef798eb68;hpb=43a63d085fab34f337ceec232e29e5760f4fcc25 diff --git a/doc/source/examples/findadd.py b/doc/source/examples/findadd.py new file mode 100644 index 0000000..922cae1 --- /dev/null +++ b/doc/source/examples/findadd.py @@ -0,0 +1,8 @@ +import musicpd + +# Using a context manager +# (use env var if you need to override default host) +with musicpd.MPDClient() as client: + client.clear() + client.findadd("(artist == 'Monkey3')") + client.play()