2005-11-07 01:12:51 +00:00
|
|
|
#!/bin/sh
|
2016-02-08 14:28:50 +00:00
|
|
|
# Copyright (C) 2006-2016 OpenWrt.org
|
2006-04-05 02:09:22 +00:00
|
|
|
|
2007-03-31 00:59:49 +00:00
|
|
|
export HOTPLUG_TYPE="$1"
|
|
|
|
|
2012-06-05 16:04:23 +00:00
|
|
|
. /lib/functions.sh
|
2005-11-07 02:18:59 +00:00
|
|
|
|
2016-02-08 14:28:50 +00:00
|
|
|
PATH="%PATH%"
|
2005-11-07 01:12:51 +00:00
|
|
|
LOGNAME=root
|
|
|
|
USER=root
|
|
|
|
export PATH LOGNAME USER
|
2013-11-19 00:03:39 +00:00
|
|
|
export DEVICENAME="${DEVPATH##*/}"
|
2005-11-07 01:12:51 +00:00
|
|
|
|
2019-10-28 09:41:08 +00:00
|
|
|
if [ \! -z "$1" -a -d /etc/hotplug.d/$1 ]; then
|
2005-11-07 01:12:51 +00:00
|
|
|
for script in $(ls /etc/hotplug.d/$1/* 2>&-); do (
|
|
|
|
[ -f $script ] && . $script
|
|
|
|
); done
|
2019-10-28 09:41:08 +00:00
|
|
|
fi
|