Remove tabs from plugins

This commit is contained in:
Lars Kruse 2020-02-08 05:32:09 +01:00
parent b5d8f7931b
commit 6b09d74c9a
1 changed files with 4 additions and 8 deletions

View File

@ -16,14 +16,10 @@ config_if() {
echo "up.min 0" echo "up.min 0"
echo "up.negative down" echo "up.negative down"
echo "up.cdef up,8,*" echo "up.cdef up,8,*"
if [ -n "$(which ethtool)" ]; then if [ -n "$(which ethtool)" ] && [ -x "$(which ethtool)" ] && ethtool "$INTERFACE" | grep -q Speed; then
if [ -x "$(which ethtool)" ]; then MAX=$(($(ethtool "$INTERFACE" | grep Speed | sed -e 's/[[:space:]]\{1,\}/ /g' -e 's/^ //' -e 's/M.*//' | cut -d " " -f 2) * 1000000))
if ethtool "$INTERFACE" | grep -q Speed; then echo "up.max $MAX"
MAX=$(($(ethtool "$INTERFACE" | grep Speed | sed -e 's/[[:space:]]\{1,\}/ /g' -e 's/^ //' -e 's/M.*//' | cut -d " " -f 2) * 1000000)) echo "down.max $MAX"
echo "up.max $MAX"
echo "down.max $MAX"
fi
fi
fi fi
} }
fetch_if() { fetch_if() {