Artifacts
Simple Jar
Jar task is provided by Java plugin. We can update its default configuration. For example, if we want to create a runnable jar, we need to provide main class, that will be inserted into manifest.
Assemble task
When we have applied Java plugin, we can run gradle assemble
in order to create jar files in build
directory. We can update the defaults.
Create distribution
Apply plugin distribution and then we can create different distribution archives. Here we create main
distribution, that contains all jars. Then we create docs
distribution that contains all source files.
Publish artifacts
We can use maven-publish
plugin to upload our artifacts into a repository.
Last updated
Was this helpful?