Forge is a Lua scriptable build tool that tracks dependencies between files, uses relative timestamps to determine which are out of date, and carries out actions to bring those files up to date.
Copy {bar,baz,foo}.in
to output/{bar,baz,foo}.out
:
local toolset = require 'forge' {
output = root( 'output' );
};
toolset:all {
toolset:Copy '${output}/%1.out' {
'bar.in';
'baz.in';
'foo.in';
};
};
The Lua script that defines the Copy
rule:
local Copy = PatternRule( 'Copy' );
function Copy.build( toolset, target )
rm( target );
cp( target, target:dependency() );
end
return Copy;
Execute the build by running forge
from a directory within the project:
$ forge
The User Manual has more documentation including:
-
Installation in development and build environments.
-
Getting Started to get up and running.
-
Copy Files and Compile and Link C++ for examples of Forge in practice.
-
Reference describing the Forge API in detail.
All contributions and feedback welcomed. Please use the Github issue tracker and/or open a pull request. Thanks!
Forge is licensed under the MIT License