From e22956a0797c6247802581c5c027247f25754498 Mon Sep 17 00:00:00 2001 From: Mart Lubbers Date: Thu, 27 Jul 2023 14:29:10 +0200 Subject: [PATCH] toggle --- music/.local/bin/music_toggle | 6 ++++++ vim/.vim/pack/plugins/start/vimwiki | 1 + 2 files changed, 7 insertions(+) create mode 160000 vim/.vim/pack/plugins/start/vimwiki diff --git a/music/.local/bin/music_toggle b/music/.local/bin/music_toggle index eaddd60..5cb654f 100755 --- a/music/.local/bin/music_toggle +++ b/music/.local/bin/music_toggle @@ -8,6 +8,12 @@ then elif cmus-remote -Q then cmus-remote --pause +elif dbus-send --session --dest=org.freedesktop.DBus --type=method_call \ + --print-reply /org/freedesktop/DBus org.freedesktop.DBus.ListNames\ + | grep -q "org\.mpris\.MediaPlayer2\.spotify" +then + dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify\ + /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlayPause else echo "$(date) $0: no music player detected" fi diff --git a/vim/.vim/pack/plugins/start/vimwiki b/vim/.vim/pack/plugins/start/vimwiki new file mode 160000 index 0000000..619f04f --- /dev/null +++ b/vim/.vim/pack/plugins/start/vimwiki @@ -0,0 +1 @@ +Subproject commit 619f04f89861c58e5a6415a4f83847752928252d -- 2.20.1