blob: ffd91a9fba6faf4372876da50862bd6804ac725d (
plain) (
tree)
|
|
#!/bin/bash
# Prints out if there is an ethernet cable connected
ETHERNET_ICON='🖥️'
get_ethernet()
{
if [ -d /sys/class/net/eth? ]; then
if [ "$(cat /sys/class/net/eth?/carrier)" == "1" ]; then
echo "$ETHERNET_ICON"
fi
fi
}
get_ethernet
|