21 lines
628 B
Bash
21 lines
628 B
Bash
#!/bin/bash
|
|
|
|
################################################################################
|
|
#
|
|
# spotify-launcher
|
|
# Launches spotify and forces it to use the correct (dark) GTK theme variant
|
|
#
|
|
################################################################################
|
|
|
|
export GTK_THEME=:dark
|
|
export GTK_THEME_VARIANT="dark"
|
|
|
|
/usr/bin/flatpak run --branch=stable --arch=x86_64 --command=spotify --file-forwarding com.spotify.Client @@u %U @@ &
|
|
|
|
# This is dumb, but it works...
|
|
for i in {1..11}
|
|
do
|
|
xprop -f _GTK_THEME_VARIANT 8u -set _GTK_THEME_VARIANT dark -id $(wmctrl -lp | grep Spotify | cut -d ' ' -f1)
|
|
sleep 1
|
|
done
|