Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 38 lines (29 sloc) 0.717 kB
f415455 @kthakore Adding build system
kthakore authored
1 #!/usr/bin/perl
2 use strict;
3 use warnings;
4 use feature ':5.10';
5 use Getopt::Long;
6 use SDLManualLatex;
7 use Template;
8
9 main();
10
11 sub main {
12 my $paper;
13 GetOptions(
14
15 # Should be one of: a4, letter.
16 'paper:s' => \$paper,
17 ) or die;
18
19 my $output;
20 for (@ARGV) {
21 my $parser = SDLManualLatex->new();
22 $parser->emit_environments( sidebar => "sidebar" );
23 $parser->codes_in_verbatim(1);
24 $parser->output_string( \$output );
25 $parser->parse_file($_);
26 }
27
28 my $tt = Template->new( { INCLUDE_PATH => 'lib', } );
29
30 print $tt->process(
31 'book.sty', {
32 content => $output,
33 paper => $paper,
34 } );
35
36 } ## end sub main
37
Something went wrong with that request. Please try again.