From 7ec492dbbc82d577e97ff9b74719a1d84ff5a01e Mon Sep 17 00:00:00 2001 From: CramMK Date: Fri, 20 Mar 2020 09:58:31 +0100 Subject: [PATCH] Fix startscript for polybar --- dotfiles/polybar/config | 17 ++++++++++++----- dotfiles/polybar/start.sh | 5 +++++ 2 files changed, 17 insertions(+), 5 deletions(-) diff --git a/dotfiles/polybar/config b/dotfiles/polybar/config index 7b83d35..a25fd92 100644 --- a/dotfiles/polybar/config +++ b/dotfiles/polybar/config @@ -92,17 +92,24 @@ wrapping-scroll = false foreground = ${colors.accent} background = #383D41 -label-unfocused = %index% -label-unfocused-foreground = #ffffff -label-unfocused-background = ${self.background} -label-unfocused-padding = 2 - label-focused = %index% label-focused-foreground = ${self.foreground} label-focused-background = ${self.background} label-focused-underline = #fba922 label-focused-padding = 2 +label-unfocused = %index% +label-unfocused-foreground = #ffffff +label-unfocused-background = ${self.background} +label-unfocused-underline = #fba922 +label-unfocused-padding = 2 + +label-visible = %index% +label-visible-foreground = #ffffff +label-visible-background = ${self.background} +label-visible-underline = #fba922 +label-visible-padding = 2 + label-urgent = %index% label-urgent-background = ${self.foreground} label-urgent-foreground = ${self.background} diff --git a/dotfiles/polybar/start.sh b/dotfiles/polybar/start.sh index aaf5ecd..34d84ba 100755 --- a/dotfiles/polybar/start.sh +++ b/dotfiles/polybar/start.sh @@ -6,7 +6,12 @@ while pgrep -u $UID -x polybar >/dev/null; do sleep 1; done # Launch laptop=$(xrandr --query | grep 'eDP-1') +hdmi1=$(xrandr --query | grep 'HDMI-1') if [[ ${laptop} = *connected* ]]; then polybar laptop & fi + +if [[ ${hdmi1} = *connected* ]]; then + polybar HDMI1 & +fi