scripts

shell scripts
git clone git://git.bitsmanent.org/scripts
Log | Files | Refs | README

commit 429002cc7a9458ef5224db422ba4899da0ed9d6d
parent 29ed53568304e3c5847e051b8b752cd7f686c679
Author: Claudio Alessi <smoppy@gmail.com>
Date:   Sat, 21 Jan 2023 13:22:15 +0100

[iwpick] Don't reset the interface if there was errors.

Diffstat:
Msrc/iwpick | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/iwpick b/src/iwpick @@ -89,7 +89,6 @@ main() { done [ "$(id -u)" -ne 0 ] && die "You must be root" - ifconfig $iface up 0.0.0.0 if [ $pick -eq 1 ]; then echo "Looking for a suitable network... " essid="$(pickone "$iface" "$file")" @@ -110,6 +109,7 @@ main() { # If explicitly specified, check if the ESSID do exists valid="$(iwlist $iface scan |grep ESSID |grep -wc "$essid")" [ $valid -eq 0 ] && die "$essid: no network found" + ifconfig $iface up 0.0.0.0 apps=(wpa_supplicant dhclient) for a in ${apps[@]} do