summaryrefslogtreecommitdiffstats
path: root/bin/drakconnect
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.com>2008-03-14 12:36:20 +0000
committerOlivier Blin <oblin@mandriva.com>2008-03-14 12:36:20 +0000
commitccda42e7811b3b70850645125c3a5a8f8680c5fb (patch)
treec48743de54ecd396855a37c286f71901795733d0 /bin/drakconnect
parent07a98499aefc20b2f94581401e89e180e9fdffb1 (diff)
downloaddrakx-net-ccda42e7811b3b70850645125c3a5a8f8680c5fb.tar
drakx-net-ccda42e7811b3b70850645125c3a5a8f8680c5fb.tar.gz
drakx-net-ccda42e7811b3b70850645125c3a5a8f8680c5fb.tar.bz2
drakx-net-ccda42e7811b3b70850645125c3a5a8f8680c5fb.tar.xz
drakx-net-ccda42e7811b3b70850645125c3a5a8f8680c5fb.zip
simplify
Diffstat (limited to 'bin/drakconnect')
-rwxr-xr-xbin/drakconnect13
1 files changed, 5 insertions, 8 deletions
diff --git a/bin/drakconnect b/bin/drakconnect
index d550e95..cace8fc 100755
--- a/bin/drakconnect
+++ b/bin/drakconnect
@@ -49,20 +49,17 @@ local $_ = join '', @ARGV;
if (/--skip-wizard/) {
require network::drakconnect::edit;
network::drakconnect::edit::manage($in, $net, $modules_conf);
-}
-/--add/ and add_intf();
-if (/--del/) {
+} elsif (/--del/) {
require network::drakconnect::delete;
network::drakconnect::delete::del_intf($in, $net, $modules_conf);
-}
-if (/--internet/) {
+} elsif (/--internet/) {
require network::drakconnect::global;
network::drakconnect::global::configure_net($in, $net, $modules_conf);
+} else {
+ # default is to run wizard (--add)
+ add_intf();
}
-# default is to run wizard
-add_intf();
-
sub add_intf() {
$::isWizard = 1;
network::netconnect::safe_main($net, $in, $modules_conf);