PKGBUILDs/extra/ifplugd/ifplugd.action

27 lines
457 B
Text
Raw Normal View History

2009-10-10 02:23:22 +00:00
#!/bin/sh
#
# ifplugd.action script for Arch Linux
. /etc/rc.conf
. /etc/rc.d/functions
case "$2" in
up)
/etc/rc.d/network ifup $1
# ugly way to load up gateway, since
# al's net configuration doesn't associate
# gateways with specific interfaces
/sbin/route add $gateway
;;
down)
/etc/rc.d/network ifdown $1
# same as up...
/sbin/route del $1
;;
*)
echo "Wrong arguments" > /dev/stderr
;;
esac
exit 1