Q: Configured JReleaser in a multi-module project and got
org.jreleaser.util.JReleaserException: Could not determine git HEAD
when running any commands. How can I fix this?
This happens when JReleaser is invoked on a directory that’s not the root where you’d typically find the root
To fix this you can move the configuration to the root directory or instruct JReleaser to search for the Git root directory:
Maven set the
jreleaser.git.root.searchproperty or set
<gitRootSearch>in the plugin’s configuration.
Gradle set the
gitRootSearchproperty on the
jreleaserextension or set the
Ant set the
Q: Can I use JReleaser with Rust projects?
Yes, you can. You can continue to use Cargo to build the Rust binaries then instruct JReleaser to release said binaries. The https://github.com/aalmiray/helloworld-rustx/ repository shows a trivial CLI application that produces 5 different binaries built with Cargo and released with JReleaser.
Q: The generated changelog is missing all history or fails to find the previous tag. What am I missing?
It’s likely that JReleaser was run on a shallow working copy. When running on GitHub Actions take note of adding the
fetch-depth: 0 option on the
Checkout step. It is required for JReleaser to work properly.