A plugin for Gradle that adds a support for Java Platform Module System, also known as Jigsaw, introduced by Java 9.
Gradle doesn't currently support building Java 9 modules in a first-class way, except for a extremely limited
experimental-jigsaw
plugin. This plugin aims to provide the necessary support by reconfiguring common Gradle
tasks to use modules, so that you could use modules in your project right now.
The full documentation and some tips, how to solve common problems with Jigsaw, can be found on wiki.
If you already have a working Java project, applying the plugin is just one step:
plugins {
id 'com.zyxist.chainsaw' version 'x.y.z'
}
Chainsaw will automatically detect your Jigsaw module descriptor and reconfigure Gradle tasks to use modules instead of classpath.
Every release brings improvements and support for more and more corner cases and use cases, based on real-world projects. The plugin is already quite usable. All of the features:
run
task,installDist
task.The long-term vision includes providing support for building modular runtime images, and multirelease JAR archives. To learn more about using Chainsaw, visit the project wiki.
Chainsaw is a community project. You can help in various ways:
When creating a Pull Request, remember to write integration tests for the new functionality. Jigsaw tends to be very tricky and these tests are important to ensure that new features don't break anything that has previously worked.
Apache License 2.0