Builder (v. 0.0.1)
Builder is a build tool similar to Apache Ant, Apache Maven and Make.
Currently Builder is more similar to Apache Ant than to Apache Maven. This is because no dependency management has been added. The main difference between Builder and Apache Ant is, however, that you do not need to write XML-files to use it. It's all Java source code.
- You write your scripts with pure Java source code.
- Javadoc for built-in methods that can be called from a script exists.
- The project is very light-weight.
- Built-in methods can zip, unzip, compile with
javac, copy files and more.
- You can use it for more than building projects, such as launching projects.
- Builder is open source and uses the LGPL-license.
Currently a distribution is provided in the GitHub-repository (the
dist directory) but no release has been made. You can use the distribution, or you can build the project yourself using Apache Ant.
If you downloaded the distribution, you may have to add the
bin directory in the distribution to your environment variables under
path. This is if you're running Windows. If you're running any other operating system, you will have to write your own launch files at this time, and put them in the
To use Builder, create or navigate to a directory and create the file
Build.java. Then write some Java source code. A
Hello World program will do for now. Then open a terminal in that directory and type
builder and your code should be compiled and executed.
The above was just the default behaviour for Builder. To execute the file
Clean.java, simply write
builder Clean. You can also specify more than one file to execute. Then do something like
builder Clean Build.
The following example demonstrates how you can compile a project with
empty("bin"); mkdirs("bin/main/java"); mkdirs("src/main/java"); javac("bin/main/java", null, null, getFilesFromDirectory("src/main/java"));
This library has not been properly released yet. This means, even though it says it's version 1.0.0 in the build.xml file and all Java source code files, it should not be treated as such. When this library gets released, it will be tagged and available on the "releases" page.