Changeset 1141

Show
Ignore:
Timestamp:
07/24/06 04:47:14
Author:
miyagawa
Message:

r3175@rock: miyagawa | 2006-07-23 01:37:22 +0900

Add 'fulltext' config to Publish
Feed to control if you want to publish fulltext feed. Defaults to 1.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/refactoring-planet/plagger/lib/Plagger/Plugin/Publish/Feed.pm

    r1131 r1141  
    3232        mkdir $dir, 0755 or $context->error("mkdir $dir: $!"); 
    3333    } 
     34 
     35    unless (exists $self->conf->{fulltext}) { 
     36        $self->conf->{fulltext} = 1; 
     37    } 
    3438} 
    3539 
     
    5458        $entry->link($e->link); 
    5559        $entry->summary($e->body_text) if defined $e->body; 
    56         $entry->content($e->body)      if defined $e->body; 
     60        $entry->content($e->body) 
     61            if $self->conf->{fulltext} && defined $e->body; 
    5762        $entry->category(join(' ', @{$e->tags})); 
    5863        $entry->issued($e->date) if $e->date; 
     
    153158=head1 CONFIG 
    154159 
    155 =head2 format 
     160=over 4 
     161 
     162=item format 
    156163 
    157164Specify the format of feed. C<Plagger::Plugin::Publish::Feed> supports 
    158165the following syndication feed formats: 
    159166 
    160 =over 4 
    161  
    162 =item * Atom (default) 
    163  
    164 =item * RSS 
     167=over 8 
     168 
     169=item Atom (default) 
     170 
     171=item RSS 
    165172 
    166173=back 
    167174 
    168 =head2 dir 
     175=item dir 
    169176 
    170177Directory to save feed files in. 
    171178 
    172 =head2 filename 
     179=item filename 
    173180 
    174181Filename to be used to create feed files. It defaults to C<%i.rss> for 
     
    176183like printf(): 
    177184 
    178 =over 4 
    179  
    180 =item * %u url 
    181  
    182 =item * %l link 
    183  
    184 =item * %t title 
    185  
    186 =item * %i id 
     185=over 8 
     186 
     187=item %u url 
     188 
     189=item %l link 
     190 
     191=item %t title 
     192 
     193=item %i id 
    187194 
    188195=back 
    189196 
     197=item fulltext 
     198 
     199Whether to publish fulltext content feed. Defaults to 1. 
     200 
     201=back 
     202 
    190203=head1 AUTHOR 
    191204