anymore, so search further is futile. Maybe the backend could even add a
marker, ignored by read_entry_all, but understood by read_entry_small, that
indicates end of $res2 and start of $res3
+- Debtags: print friendly names instead of raw names?
+- Store in db \1-separated, and split on that, instead of the more fragile
+ '/, /' split
Missing pieces from old code:
debug( "Data search and merging took ".timestr($std) ) if DEBUG;
my $did = $page->get_newest( 'description' );
+ my @tags = split(/, /, $page->get_newest( 'tag' ));
$section = $page->get_newest( 'section' );
$subsection = $page->get_newest( 'subsection' );
my $filenames = $page->get_arch_field( 'filename' );
);
}
$package_page .= pdesc( $short_desc, $long_desc );
+ $package_page .= ptags( $pkg, @tags ) if @tags;
#
# display dependencies
our @ISA = qw( Exporter );
our @EXPORT = qw( header title trailer file_changed time_stamp
read_md5_hash write_md5_hash simple_menu
- ds_begin ds_item ds_end title marker pdesc
+ ds_begin ds_item ds_end title marker pdesc ptags
pdeplegend pkg_list pmoreinfo print_deps print_src_deps );
our $CHANGELOG_URL = '/changelogs';
return $str;
}
+sub ptags {
+ my ( $package, @tags ) = @_;
+ my $str = "";
+
+ $str .= "<div id=\"ptags\">\n<p>";
+ $str .= "<a href=\"http://debtags.alioth.debian.org/cgi-bin/edit.cgi?pkg=".uri_escape($package)."\">Tags</a>:\n";
+ foreach my $tag (@tags) {
+ $str .= "<a href=\"http://debtags.alioth.debian.org/cgi-bin/index.cgi?tags=".uri_escape($tag)."\">$tag</a>\n";
+ }
+ $str .= "</p>\n</div> <!-- end ptags -->\n";
+
+ return $str;
+}
+
sub pdeplegend {
my $str = "<table id=\"pdeplegend\" summary=\"legend\"><tr>\n";
/* classes and div names for package pages */
-#pdesc, #pdeps, #pdownload, #pmoreinfo {
+#pdesc, #ptags, #pdeps, #pdownload, #pmoreinfo {
margin-left: 1em;
margin-right: 1em;
}