diff options
author | James Rayner <james@archlinux.org> | 2009-09-27 15:45:41 +0200 |
---|---|---|
committer | James Rayner <james@archlinux.org> | 2009-09-27 15:45:41 +0200 |
commit | df2c2b5c04393ed72c2798407f50f99a6298b673 (patch) | |
tree | c432706c3b31ff5702217ec0d16edb4ecae11b0b /autowifi/autowifi-netcfg-action | |
parent | 818dacfa7f435e42fe1c81ae002a8df01ea80677 (diff) | |
download | netctl-df2c2b5c04393ed72c2798407f50f99a6298b673.tar.gz netctl-df2c2b5c04393ed72c2798407f50f99a6298b673.tar.xz |
Rename autowifi->wpa_actiond, add makefile, bugfix
Diffstat (limited to 'autowifi/autowifi-netcfg-action')
-rwxr-xr-x | autowifi/autowifi-netcfg-action | 54 |
1 files changed, 0 insertions, 54 deletions
diff --git a/autowifi/autowifi-netcfg-action b/autowifi/autowifi-netcfg-action deleted file mode 100755 index f273b3b..0000000 --- a/autowifi/autowifi-netcfg-action +++ /dev/null @@ -1,54 +0,0 @@ -#! /bin/bash - -interface=$1 -ssid=$2 -profile=$3 -action=$4 - -. /usr/lib/network/network -[[ $profile ]] && load_profile "$profile" - -case $action in - CONNECT) - if [[ -z $profile ]]; then - dhcpcd $interface - exit $? - fi - if ! $CONN_DIR/ethernet up "$profile"; then - exit 1 # what to do if fail? - fi - - set_profile up "$profile" - - if ! ( eval $POST_UP ); then # JP: sandbox the eval - # failing POST_UP will take interface down - "$CONN_DIR/$ethernet" down "$profile" - exit 1 - fi - ;; - DISCONNECT) - if [[ -z $profile ]]; then - dhcpcd -k $interface - exit $? - fi - if ! ( eval $PRE_DOWN ); then # JP: sandbox the eval - exit 1 - fi - if ! "$CONN_DIR/ethernet" down "$profile"; then - exit 1 - fi - if ! ( eval $POST_DOWN ); then # JP: sandbox the eval - exit 1 - fi - set_profile down "$profile" - ;; - LOST|REESTABLISHED) - # Not handled. - exit 0 - ;; - *) - # ??? - exit 1 - ;; -esac - |