diff options
author | Angelo Naselli <anaselli@linux.it> | 2014-12-08 22:31:59 +0100 |
---|---|---|
committer | Angelo Naselli <anaselli@linux.it> | 2014-12-08 22:31:59 +0100 |
commit | 5aa3c064e85b7ac50cf7b8bc78dd642d7198415d (patch) | |
tree | 448e1204faff2bf03f0b7aed906b5f193155b660 | |
parent | 897f3ef246c2541642ed73238ddcb6c6fbe93247 (diff) | |
download | manatools-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.tar manatools-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.tar.gz manatools-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.tar.bz2 manatools-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.tar.xz manatools-5aa3c064e85b7ac50cf7b8bc78dd642d7198415d.zip |
Fixed tab in presentation
-rwxr-xr-x | scripts/mana | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/scripts/mana b/scripts/mana index f6e26ccf..329f3b25 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); } |