Skip to content

How to add built hibernate to local maven repo?

To build hibernate (5.5) I do this:

git clone git://
./gradlew build -x test

as a result I have in release/target/distributions two files:


These files have binary and source code of the hibernate. However, built jars are not added to local maven repo. Could anyone say how to add them including sources and javadoc?


The task you’re looking for is publishToMavenLocal. And instead of build -x test you can use assemble.

./gradlew assemble publishToMavenLocal