#!/bin/sh if iwctl station wlan0 show | grep -q "Connected network" ; then echo $(iwctl station wlan0 show | grep "AverageRSSI" | tr -s ' ' | cut -d " " -f 3); else echo "Disconnected"; fi