diff options
Diffstat (limited to 'mgaadv')
-rwxr-xr-x | mgaadv | 17 |
1 files changed, 17 insertions, 0 deletions
@@ -33,6 +33,15 @@ Create a new advisory file. [type] should be security or bugfix and [bugnum] is the bugzilla bug number. END }, + show => { + run => \&showadv, + descr => 'Show an advisory', + usage => <<END, +$0 show [ID] + +Show an advisory. +END + }, usage => { run => \&usage, descr => 'Show usage informations for an action', @@ -87,6 +96,14 @@ sub listadv { MGA::Advisories::listadv(\%advdb); } +sub showadv { + usageexit('usage', $_[0]) unless @_ == 2; + my $adv = $_[1]; + my %advdb; + $advdb{advisories} = MGA::Advisories::get_advisories(); + MGA::Advisories::showadv(\%advdb, $adv); +} + if (@ARGV == 0 || !$actions{$ARGV[0]}) { usageexit(); } |