Skip Menu |
 

This queue is for tickets about the Pod-POM-Web CPAN distribution.

Report information
The Basics
Id: 26734
Status: resolved
Priority: 0/
Queue: Pod-POM-Web

People
Owner: Nobody in particular
Requestors: chris+rt [...] chrisdolan.net
Cc:
AdminCc:

Bug Information
Severity: Unimportant
Broken in: 1.03
Fixed in: 1.05



Subject: [PATCH] AnnoCPAN::PerlDoc support
Download (untitled) / with headers
text/plain 534b
The attached patch adds support for AnnoCPAN comments in local POD. This is accomplished via a local mirror of the annocpan.org SQLite database. I've also attached a screenshot of what the HTML looks like with this patch. This patch lacks documentation, unfortunately. If the concept is approved, I would be willing to contribute some of that documentation. For more info, see: http://search.cpan.org/dist/AnnoCPAN-Perldoc/ and optionally: http://search.cpan.org/dist/AnnoCPAN-Perldoc-SyncDB/ (the latter was written by me)
Subject: annocpan.patch
Download annocpan.patch
text/x-diff 1.1k
--- /Users/chris/perl/lib/perl5/site_perl/Pod/POM/Web.pm 2007-04-24 15:16:17.000000000 -0500 +++ lib/Pod/POM/Web.pm 2007-04-26 20:40:49.000000000 -0500 @@ -32,6 +32,9 @@ my $no_indexer = eval {require Pod::POM::Web::Indexer} ? 0 : $@; +my @podfilters = ( + eval {require AnnoCPAN::Perldoc::Filter} ? sub {AnnoCPAN::Perldoc::Filter->new->filter(@_)} : (), +); #---------------------------------------------------------------------- @@ -252,6 +255,8 @@ : $self->parse_version($content); $version &&= " <small>$version</small>"; + $content = $_->($content) for @podfilters; + # Pod::POM fails to parse correctly when there is an initial blank line $content =~ s/^\s*//; @@ -877,6 +892,20 @@ } +sub view_over { + my ($self, $over) = @_; + # This is a fix for AnnoCPAN POD which routinely has + # =over \n =over \n ... \n =back \n =back + my $content = $self->SUPER::view_over($over); + if ($content eq "") { + my $overs = $over->over(); + if (@$overs) { + return join q{}, '<blockquote>', (map {$self->view_over($_)} @$overs), '</blockquote>'; + } + } + return $content; +} + sub view_item { my ($self, $item) = @_;
Subject: annocpan.png
Download annocpan.png
image/png 109.7k
annocpan.png
Download (untitled) / with headers
text/plain 584b
Le Jeu. Avr. 26 21:48:55 2007, CDOLAN a écrit : Show quoted text
> The attached patch adds support for AnnoCPAN comments in local POD. > This is accomplished via a local mirror of the annocpan.org SQLite > database. I've also attached a screenshot of what the HTML looks
like Show quoted text
> with this patch. > > This patch lacks documentation, unfortunately. If the concept is > approved, I would be willing to contribute some of that
documentation. Show quoted text
>
Good idea, I didn't know that the AnnoCPAN comments database can be downloaded. So please go on with the doc and I'll include it in the next release.
Download (untitled) / with headers
text/plain 531b
On Fri Apr 27 03:19:58 2007, DAMI wrote: Show quoted text
> Good idea, I didn't know that the AnnoCPAN comments database can be > downloaded. So please go on with the doc and I'll include it in the > next release.
The attached patch (annocpan.patch2) obsoletes the earlier one. It does the following: * Documents the @podfilter * Moves "$content =~ s/^\s*//" to the filter array * Applies the filters to sub pod2pom * Documents AnnoCPAN::Perldoc in the optional features section * Expands the explanation for the sub view_over hack Chris
Download annocpan.patch2
application/octet-stream 3.4k

Message body not shown because it is not plain text.

Download (untitled) / with headers
text/plain 132b
Sigh. I uploaded the wrong patch again. The attached annocpan.patch3 is the right one. The previous one was a failed experiment.
Download annocpan.patch3
application/octet-stream 3.4k

Message body not shown because it is not plain text.



This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.