mirror of
https://gitlab.com/dwt1/dotfiles.git
synced 2023-02-13 20:55:19 -05:00
Merge branch 'polybar-fixes' into 'master'
polybar: Wireless works with any interface name and better multi-monitor support See merge request dwt1/dotfiles!1
This commit is contained in:
commit
0cea6e4d87
2 changed files with 5 additions and 8 deletions
|
@ -1422,7 +1422,7 @@ label-disconnected-foreground = ${colors.foreground}
|
||||||
[module/wireless-network]
|
[module/wireless-network]
|
||||||
;https://github.com/jaagr/polybar/wiki/Module:-network
|
;https://github.com/jaagr/polybar/wiki/Module:-network
|
||||||
type = internal/network
|
type = internal/network
|
||||||
interface = wlp3s0
|
interface = ${env:WIRELESS}
|
||||||
interval = 3.0
|
interval = 3.0
|
||||||
label-connected = %essid%
|
label-connected = %essid%
|
||||||
|
|
||||||
|
@ -1520,3 +1520,4 @@ format-foreground = ${colors.foreground}
|
||||||
format-background = ${colors.background}
|
format-background = ${colors.background}
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
# vim:ft=dosini
|
||||||
|
|
|
@ -6,12 +6,8 @@ killall -q polybar
|
||||||
# Wait until the processes have been shut down
|
# Wait until the processes have been shut down
|
||||||
while pgrep -u $UID -x polybar >/dev/null; do sleep 1; done
|
while pgrep -u $UID -x polybar >/dev/null; do sleep 1; done
|
||||||
|
|
||||||
if type "xrandr"; then
|
for m in $(polybar --list-monitors | cut -d":" -f1); do
|
||||||
for m in $(xrandr --query | grep " connected" | cut -d" " -f1); do
|
WIRELESS=$(ls /sys/class/net/ | grep ^wl | awk 'NR==1{print $1}') MONITOR=$m polybar --reload mainbar-i3 &
|
||||||
MONITOR=$m polybar --reload mainbar-i3 &
|
done
|
||||||
done
|
|
||||||
else
|
|
||||||
polybar --reload mainbar-i3 &
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "Bars launched..."
|
echo "Bars launched..."
|
||||||
|
|
Loading…
Add table
Reference in a new issue