Document::Maker

Document::Maker contains makefile-like functionality in Perl.
Download

Document::Maker Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Robert Krimen
  • Publisher web site:
  • http://search.cpan.org/~rkrimen/

Document::Maker Tags


Document::Maker Description

Document::Maker contains makefile-like functionality in Perl. Document::Maker contains makefile-like functionality in Perl.SYNOPSIS my $maker = Document::Maker->new; $maker->parser->parse_target( "tgt/a.out" => "src/defs.txt", do => sub { my $target = shift; my $file = shift; # tgt/a.out .... }, ); $maker->make("tgt/a.out"); # Will only make if "tgt/a.out" is older than "src/defs.txt" or doesn't existDocument::Maker is intended to have similar functionality as GNU make with additional enhancements.WARNING: Although this is a 3rd-iteration attempt at Makefile-ness, the API is very fluid and could change in future versions.WARNING: There may be bugs lurking about, I'll be happy to entertain bug reports.Already workingTarget-from-one-source $maker->parser->parse_target( "tgt/a.out" => "src/defs.txt", do => sub { my $target = shift; my $file = shift; # tgt/a.out .... }, );Target-from-many-sources $maker->parser->parse_target( "tgt/a.out" => , do => sub { my $target = shift; my $file = shift; # tgt/a.out .... }, );Many-targets-dependent-on-many-sources $maker->parser->parse_target( => , do => sub { my $target = shift; my $file = shift; .... }, );Non-file, Target-only $maker->parser->parse_simple_target( "configure", do => sub { my $target = shift; # No second argument .... }, );Target/source-patterns $maker->parser->parse_pattern_target(qw( tgt/%.html src/%.in a b c d e ), , { do => sub { my $target = shift; my $file = shift; # tgt/a.html, tgt/b.html, etc. my $source_file = shift; # src/a.in, src/b.in, etc. .... }, });Target/source-patterns based on crawling through a directory # This will crawl src/ looking for every file matching the src pattern and making a target out of it $maker->parser->parse_pattern_target(qw( tgt/%.html src/%.in src/* ), , { do => sub { my $target = shift; my $file = shift; my $source_file = shift; .... }, }); Requirements: · Perl


Document::Maker Related Software