dotfiles/.bin/OLD/ifonly
2024-02-14 07:55:58 +01:00

12 lines
232 B
Bash
Executable File

#!/bin/sh
only=$1
for if in $(ifconfig | grep "^[a-z]" | cut -d":" -f1 | grep -Ev "lo0|enc0|pflog0")
do
doas ifconfig $if down
doas ifconfig $if -inet
doas ifconfig $if -inet6
done
doas ifconfig $only inet autoconf up