package Text::Markup::Textile; use 5.8.1; use strict; use warnings; use File::BOM qw(open_bom); use Text::Textile '2.10'; our $VERSION = '0.24'; sub parser { my ($file, $encoding, $opts) = @_; my $textile = Text::Textile->new( charset => 'utf-8', char_encoding => 0, trim_spaces => 1, @{ $opts || [] } ); open_bom my $fh, $file, ":encoding($encoding)"; local $/; my $html = $textile->process(<$fh>); return unless $html =~ /\S/; utf8::encode($html); return $html if $opts->{raw}; return qq{
$html }; } 1; __END__ =head1 Name Text::Markup::Textile - Textile parser for Text::Markup =head1 Synopsis my $html = Text::Markup->new->parse(file => 'README.textile'); my $raw = Text::Markup->new->parse(file => 'README.textile', raw => 1); =head1 Description This is the L