]> git.sev.monster Git - dotfiles.git/blame_incremental - bin/tint2-wifi
switch to sway/wayland, update zsh/mod, move files
[dotfiles.git] / bin / tint2-wifi
... / ...
CommitLineData
1#!/bin/sh
2base=~/.icons/Paper-Mono-Dark/24x24/panel/network-wireless
3excellent=$base-signal-excellent.svg
4 good=$base-signal-good.svg
5 ok=$base-signal-ok.svg
6 low=$base-signal-low.svg
7 none=$base-signal-none.svg
8 no_route=$base-no-route.svg
9 offline=$base-offline.svg
10
11echo $base-acquiring.svg
12while true; do
13 x=$(cat /proc/net/wireless | awk 'NR < 3 {next} {printf "%.0f", $4}')
14 if [ -z $x ]; then
15 echo $offline
16 elif [ $x -ge -55 ]; then
17 echo $excellent
18 elif [ $x -ge -65 ]; then
19 echo $good
20 elif [ $x -ge -75 ]; then
21 echo $ok
22 elif [ $x -ge -85 ]; then
23 echo $low
24 elif [ $x -ge -90 ]; then
25 echo $none
26 else
27 echo $no_route
28 fi
29 sleep 2
30done
This page took 0.036019 seconds and 4 git commands to generate.