Daiku::Registry - Daiku's engine
use autodie; my $daiku = Daiku->new(); $daiku->register( Daiku::Task->new( dst => 'all', deps => [qw/a.out/] ) ); $daiku->register( Daiku::File->new( dst => 'a.out', deps => [qw/b.o c.o/], code => sub { my $task = shift; system "cc -o @{[ $task->dst ]} @{[ join ' ', @{$task->src} ]}"; } ) ); $daiku->register( Daiku::SuffixRule->new( src => '.c', dst => '.o', code => sub { my ( $src, $dst ) = @_; system "cc -c $dst $src"; } ) ); $daiku->build('all');
Daiku::Registry is a central registry of Daiku tasks.
my $daiku = Daiku::Registry->new();
Create a new instance of Daiku::Registry.
$daiku->register($task : Daiku::Task|Daiku::SuffixRule|Daiku::File) : void
Register a task with the Daiku::Registry.
$daiku->build($target : Str) : void
Build a $target.
$target
Tokuhiro Matsuno
To install Daiku, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Daiku
CPAN shell
perl -MCPAN -e shell install Daiku
For more information on module installation, please visit the detailed CPAN module installation guide.