all repos — quickshell @ c48aeb07b7fe47b375705cc3383d0e2b8bf73d1f

A desert-witch desktop shell

0
trickyni trickyniv56@gmail.com
Fri, 26 Sep 2025 12:13:19 +0300
commit

c48aeb07b7fe47b375705cc3383d0e2b8bf73d1f

parent

4005044f20bc8c20e19cfe88185368da743203dd

2 files changed, 14 insertions(+), 16 deletions(-)

jump to
M bar/modules/Network.qmlbar/modules/Network.qml

@@ -33,6 +33,6 @@ Class.TopbarIcon {

id: wifi_strength property var wifi_strength_data font.pixelSize: 9 - text: Icons.network["bar"+wifi_strength_data] + text: Icons.network["bar"+wifi_strength_data]+wifi_strength_data } }
M bar/scripts/network.shbar/scripts/network.sh

@@ -2,21 +2,19 @@ #!/usr/bin/env bash

# Find the first wireless interface connection_type=$(iw dev | awk '$1=="Interface"{print $2; exit}') #gets network type (wired/wifi) -if [ -n "$connection_type" ]; then - network_name=$(iw dev $connection_type link | awk -F': ' '/^\s*SSID:/ {print $2}') - signal_strength=$(iw dev $connection_type link | awk '/signal:/ {print $2}') - if (( sig >= -50 )); then - bars=4 - elif (( sig >= -60 )); then - bars=3 - elif (( sig >= -70 )); then - bars=2 - elif (( sig >= -80 )); then - bars=1 - else - bars=0 - fi - echo -n "$bars"+"$network_name" +network_name=$(iw dev $connection_type link | awk -F': ' '/^\s*SSID:/ {print $2}') +signal_strength=$(iw dev $connection_type link | awk '/signal:/ {print $2}') +if [ -n $signal_strength ]; then + case "$signal_strength" in + -50) bars=4;; + -60) bars=3;; + -70) bars=2;; + -80) bars=1;; + *) bars=0;; + esac +echo -n "$bars"+"$network_name" else echo -n "disconnected" fi + +