Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions scripts/network.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@ get_ssid()
;;

Darwin)
if networksetup -getairportnetwork en0 | cut -d ':' -f 2 | sed 's/^[[:blank:]]*//g' &> /dev/null; then
echo "$wifi_label$(networksetup -getairportnetwork en0 | cut -d ':' -f 2)" | sed 's/^[[:blank:]]*//g'
if ipconfig getsummary en0 | awk -F ' SSID : ' '/ SSID : / {print $2}'; then
wifi_label=$(get_tmux_option "@dracula-network-wifi-label" "")
echo "$wifi_label$(ipconfig getsummary en0 | awk -F ' SSID : ' '/ SSID : / {print $2}')"
else
echo "$ethernet_label"
fi
Expand Down