2022-10-31 21:00:11 +00:00
|
|
|
#!/bin/bash
|
|
|
|
TYPES=($(nmcli device show | grep "GENERAL.TYPE" | awk '{print $2}'))
|
|
|
|
STATES=($(nmcli device show | grep "GENERAL.STATE" | awk '{print $3}'))
|
|
|
|
|
|
|
|
for ((i = 0; i < "${#TYPES[@]}"; i++)); do
|
|
|
|
if [[ ${STATES[$i]} = "(connected)" ]]; then
|
|
|
|
if [[ ${TYPES[$i]} == *"wifi"* ]]; then
|
2023-05-19 12:22:02 +01:00
|
|
|
echo "<fc=#DFDFDF><fn=3></fn></fc>"
|
2022-10-31 21:00:11 +00:00
|
|
|
else
|
2023-05-19 12:22:02 +01:00
|
|
|
echo "<fc=#DFDFDF><fn=3></fn></fc>"
|
2022-10-31 21:00:11 +00:00
|
|
|
fi
|
|
|
|
fi
|
|
|
|
done
|