pake
Krzysztof Suchomski
Contact: krzysztof.suchomski at gmail dot com
Calling program:
pake [options] [tasks]
Pakefile is a script where you define tasks and their dependencies. Within the Pakefile you can access any previosuly defined object using Pake::Application
pake program run task specified in the command line and executes it with dependencies defined in Pakefile.
pake comes with predefined tasks for file and directory manipulations and for running tests. For details refer to other Modules
Pakefile script is a normal perl scipt, by default executed with:
use strict; use warnings;
-T, prints all tasks with descriptions defined in the Pakefile -f FILE, changes the script file name to the specified, default Pakefile -h, print help contents -d DIR, changes the working directory -D, prints all tasks with dependencies -r, Dry run, executes Pakefile to check if script is properly formed -V, prints pake version
#default task default "test2"; desc "task simply prints test"; task { print "test\n"; } "test"; desc "task test1 depends on test" task { print "test1\n"; } "test1" => ["test"]; desc "task test2 depends on test and test1"; task { print "test2\n"; } #run: pake src/com/test desc "Directory Task, it will be executed only if directory does not exists"; directory{ } "src/com/test"; #file dependencies are executed only if the files created by tasks changed file {} "biblioteka.c" => []; file { `gcc -c biblioteka.c` } "biblioteka.o" => ["src/com/test","biblioteka.c"]; file { `gcc -o program program.c biblioteka.o` } "program" => ["biblioteka.o"]; #End script with something true 1;
To install Pake::Task, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Pake::Task
CPAN shell
perl -MCPAN -e shell install Pake::Task
For more information on module installation, please visit the detailed CPAN module installation guide.