10 lines
317 B
Bash
Executable File
10 lines
317 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# https://www.binarytides.com/linux-commands-monitor-network/
|
|
# https://www.cyberciti.biz/faq/linux-list-network-interfaces-names-command/
|
|
|
|
ACTIVE_IFACE=$(ip -4 route ls | grep default | grep -Po '(?<=dev )(\S+)')
|
|
WIFI_IFACE=$(nmcli device status | awk '$2~/^wifi$/ {print $1}')
|
|
|
|
nload $ACTIVE_IFACE
|