From ccda42e7811b3b70850645125c3a5a8f8680c5fb Mon Sep 17 00:00:00 2001 From: Olivier Blin Date: Fri, 14 Mar 2008 12:36:20 +0000 Subject: simplify --- bin/drakconnect | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'bin') 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); -- cgit v1.2.1