From: Don Armstrong Date: Thu, 19 Feb 2009 05:04:45 +0000 (-0800) Subject: add bug_status command to Debbugs::Common X-Git-Tag: release/2.6.0~461^2~52 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=5de1c86ac2c032ec5d92ccd8beed6677e07a8492;p=debbugs.git add bug_status command to Debbugs::Common --- diff --git a/Debbugs/Common.pm b/Debbugs/Common.pm index aaa8db19..2044304f 100644 --- a/Debbugs/Common.pm +++ b/Debbugs/Common.pm @@ -40,6 +40,7 @@ BEGIN{ @EXPORT = (); %EXPORT_TAGS = (util => [qw(getbugcomponent getbuglocation getlocationpath get_hashname), qw(appendfile buglog getparsedaddrs getmaintainers), + qw(bug_status), qw(getmaintainers_reverse), qw(getpseudodesc), ], @@ -177,6 +178,23 @@ sub buglog { return undef; } +=head2 bug_status + + bug_status($bugnum) + + +Returns the path to the summary file corresponding to the bug. + +Returns undef if the bug does not exist. + +=cut + +sub bug_status{ + my ($bugnum) = @_; + my $location = getbuglocation($bugnum, 'summary'); + return getbugcomponent($bugnum, 'summary', $location) if ($location); + return undef; +} =head2 appendfile