aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAngelo Naselli <anaselli@linux.it>2014-12-08 22:31:59 +0100
committerAngelo Naselli <anaselli@linux.it>2014-12-08 22:31:59 +0100
commit5aa3c064e85b7ac50cf7b8bc78dd642d7198415d (patch)
tree448e1204faff2bf03f0b7aed906b5f193155b660
parent897f3ef246c2541642ed73238ddcb6c6fbe93247 (diff)
downloadcolin-keep-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.tar
colin-keep-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.tar.gz
colin-keep-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.tar.bz2
colin-keep-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.tar.xz
colin-keep-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.zip
Fixed tab in presentation
-rwxr-xr-xscripts/mana14
1 files changed, 8 insertions, 6 deletions
diff --git a/scripts/mana b/scripts/mana
index f6e26cc..329f3b2 100755
--- a/scripts/mana
+++ b/scripts/mana
@@ -62,11 +62,11 @@ my %modules = (
exec => '/usr/bin/rpmdragora',
descr => "rpmdragora: rpm install manager",
},
- update => {
+ update => {
exec => '/usr/bin/dragoraUpdate',
- descr => "dragoraUpdate rpm update manager",
+ descr => "dragoraUpdate: rpm update manager",
},
-);
+);
my $cmdline = new yui::YCommandLine;
@@ -109,10 +109,12 @@ sub usage {
print "Usage mana --help | -h print this help\n";
print "Usage mana <command> [args...]\n\n";
print "valid <commands>:\n";
-# TODO better presentation
- while ( my ($key, $value) = each(%modules) ) {
- print "<" . $key . ">\t\t". $value->{descr} . "\n";
+
+ foreach my $key (sort keys %modules) {
+ # lenght + 2 chars "<" and ">"
+ print "<" . $key . (length $key >= 6 ? ">\t" : ">\t\t") . $modules{$key}->{descr} . "\n";
}
+
print "\n";
exit(0);
}