Novel::Robot::Packer pack novel/bbs content to txt / html , etc
小说/贴子 打包引擎
支持输出类型
raw : 经过MessagePack压缩的二进制文件 html : html单网页格式 txt : txt文本格式 web : html多网页格式(目录为index.html,每个章节1个html)
初始化解析模块
my $packer = Novel::Robot::Packer->new(type => 'html');
打包文件
my $book_ref = { writer => 'xxx', book => 'yyy', floor_list => [ { id=>1, title=>'aaa', content=> '<p>kkk</p>' }, { id=>2, title=>'bbb', content=> '<p>jjj</p>' }, ], }; my $ret = $self->main($book_ref, with_toc => 1);
To install Novel::Robot::Packer, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Novel::Robot::Packer
CPAN shell
perl -MCPAN -e shell install Novel::Robot::Packer
For more information on module installation, please visit the detailed CPAN module installation guide.