A simple CLI to view your network usage since last boot.
Can also be used as a module for Polybar
To get started:
git clone https://github.com/Brutuski/NetUsage.git
- Make the script executable:
chmod +x usage.sh
- To list available options:
./usage.sh -h
- User needs to provide their interface name, which looks something like
enp7s0
orwlp8s0
. To list interfaces:ip link
- For more information about interfaces, refer to Arch wiki
View all options and help
./usage.sh -h
Display Net Usage on the Terminal
./usage.sh -i <interface_name> -c
Display Net Usager for Polybar
./usage.sh -i <interface_name> -p
[module/netusage]
type = custom/script
exec = ./usage.sh -i <interface_name> -p
tail = true
interval = 1
label = "%output%"
- Network usage data is fetched from
/proc/net/dev
. This script will not work on MacOS in it's current form. - Data is displayed only in MB for now. GB will be added in a future update.