diff options
author | Angelo Naselli <anaselli@linux.it> | 2014-10-16 13:53:01 +0200 |
---|---|---|
committer | Angelo Naselli <anaselli@linux.it> | 2014-10-16 13:53:01 +0200 |
commit | 0d421e9d20fbf0b48ab922b0472b8890d7b35d63 (patch) | |
tree | a2edab5b3ab8f6228f16688a63ddee6683d20ad1 /scripts/mana | |
parent | e59223e7737d9d85fdbb155ad30c2172f81e9774 (diff) | |
download | colin-keep-0d421e9d20fbf0b48ab922b0472b8890d7b35d63.tar colin-keep-0d421e9d20fbf0b48ab922b0472b8890d7b35d63.tar.gz colin-keep-0d421e9d20fbf0b48ab922b0472b8890d7b35d63.tar.bz2 colin-keep-0d421e9d20fbf0b48ab922b0472b8890d7b35d63.tar.xz colin-keep-0d421e9d20fbf0b48ab922b0472b8890d7b35d63.zip |
addded mandm needed files
Diffstat (limited to 'scripts/mana')
-rwxr-xr-x | scripts/mana | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/scripts/mana b/scripts/mana index 2910025..265cab9 100755 --- a/scripts/mana +++ b/scripts/mana @@ -38,6 +38,10 @@ my %modules = ( exec => '/usr/bin/manaservice', descr => "manaservice: service manager", }, + dm => { + exec => '/usr/bin/manadm', + descr => "manadm: login manager configuration", + }, clock => { exec => '/usr/bin/manaclock', descr => "manaclock: date/time manager", @@ -68,10 +72,15 @@ die "Command ". $cmd . " not found!\n" if !defined($modules{$cmd}); my $mod = $modules{$cmd}->{exec}; shift(@ARGV); -if(is_root_capability_required()) { - system("/usr/bin/pkexec", $mod, @ARGV); -} else { - system($mod, @ARGV); +eval { + if(is_root_capability_required()) { + system("/usr/bin/pkexec", $mod, @ARGV); + } else { + system($mod, @ARGV); + } +}; +if ( $@ ) { + print "ERROR: " . $@ ."\n"; } #============================================================= |