diff options
Diffstat (limited to 'media-sound/spotify/files')
-rw-r--r-- | media-sound/spotify/files/spotify-wrapper | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/media-sound/spotify/files/spotify-wrapper b/media-sound/spotify/files/spotify-wrapper new file mode 100644 index 000000000000..db8f8b948780 --- /dev/null +++ b/media-sound/spotify/files/spotify-wrapper @@ -0,0 +1,23 @@ +#!/bin/sh + +export LD_LIBRARY_PATH="/usr/$LIBDIR/apulse" + +if command -v spotify-dbus.py > /dev/null; then + echo "Launching spotify with Gnome systray integration." + spotify-dbus.py "$@" +elif command -v spotify-tray > /dev/null; then + echo "Launching spotify with generic systray integration." + minimized= + for arg; do + if [ "$arg" = --minimized ]; then + minimized=$arg + break + fi + done + spotify-tray \ + --client-path="$SPOTIFY_HOME/spotify" --toggle $minimized -- "$@" +else + echo "Neither gnome-integration-spotify nor spotify-tray are installed." + echo "Launching spotify without systray integration." + exec "$SPOTIFY_HOME/spotify" "$@" +fi |