From 1131349511ce835c3d5dae1ff7b9bad96d3a1b93 Mon Sep 17 00:00:00 2001 From: guusvanmeerveld Date: Fri, 10 Dec 2021 16:52:32 +0100 Subject: [PATCH] Added spotify to polybar --- applications.conf.yaml | 5 +- config/polybar/config | 57 +------------------ config/polybar/modules/spotify | 26 +++++++++ config/polybar/modules/status | 4 +- config/polybar/scripts/get_spotify_status.sh | 50 ++++++++++++++++ .../polybar/scripts/scroll_spotify_status.sh | 12 ++++ packages.conf.yaml | 1 + 7 files changed, 98 insertions(+), 57 deletions(-) create mode 100644 config/polybar/modules/spotify create mode 100755 config/polybar/scripts/get_spotify_status.sh create mode 100755 config/polybar/scripts/scroll_spotify_status.sh diff --git a/applications.conf.yaml b/applications.conf.yaml index 9c170b4..1591af6 100644 --- a/applications.conf.yaml +++ b/applications.conf.yaml @@ -6,8 +6,9 @@ # Chromium - ungoogled-chromium - # Spotifyd - - spotify-tui-bin + # Spotify + - spotify + - spicetify-cli - spotifyd - discord diff --git a/config/polybar/config b/config/polybar/config index da3dcf7..d5bd6a9 100644 --- a/config/polybar/config +++ b/config/polybar/config @@ -33,29 +33,6 @@ alert = #bd2c40 [constants] height = 40 -margin-top = 10 - -[bar/workspace] -font-0 = Roboto:pixelsize=13;1 -font-1 = Material Icons:pixelsize=15;4 - -width = 390 -height = ${constants.height} - -radius = 20 -fixed-center = true - -offset-x = 5 -offset-y = ${constants.margin-top} - -background = ${colors.background} -foreground = ${colors.foreground} - -modules-center = bspwm - -wm-restack = bspwm - -cursor-click = pointer [bar/system] font-0 = Roboto:pixelsize=13;1 @@ -64,51 +41,23 @@ font-1 = Material Icons:pixelsize=15;4 background = ${colors.background} foreground = ${colors.foreground} -radius = 20 fixed-center = true -offset-y = ${constants.margin-top} -offset-x = 70%:10 - padding-right = 5 -width = 26.5% height = ${constants.height} module-margin-right = 2 module-margin-left = 2 -modules-right = temperature memory cpu battery wlan eth date +modules-left = bspwm +modules-center = spotify spotify-prev spotify-play-pause spotify-next +modules-right = temperature memory cpu battery wlan eth date powermenu wm-restack = bspwm cursor-click = pointer -[bar/power] -font-0 = Roboto:pixelsize=13;1 -font-1 = Material Icons:pixelsize=15;4 - -background = ${colors.primary} -foreground = ${colors.foreground} - -radius = 20 -fixed-center = true - -offset-y = ${constants.margin-top} -offset-x = 97%:10 - -width = ${constants.height} -height = ${constants.height} - -modules-center = powermenu - -wm-restack = bspwm - -cursor-click = pointer -cursor-scroll = default - -click-left = ~/.config/polybar/scripts/power-menu.sh & - [settings] screenchange-reload = true diff --git a/config/polybar/modules/spotify b/config/polybar/modules/spotify new file mode 100644 index 0000000..861e47e --- /dev/null +++ b/config/polybar/modules/spotify @@ -0,0 +1,26 @@ +[module/spotify] +type = custom/script +tail = true + +format-prefix =  +format =