Add the version of documentation-generator you want to use in gradle.properties.
documentationGeneratorVersion = 1.16.0Now you can add a dependency to the gradle-plugin.
buildscript {
dependencies {
classpath("dk.fust:documentation-generator-gradle:${documentationGeneratorVersion}")
}
}You can instead of the variable ${documentationGeneratorVersion} simply write the version here.
For every kind of documentation you want generated, you'll need to add the corresponding dependency in the buildscript-section.
For example:
classpath("dk.fust:documentation-generator-erdiagram:${documentationGeneratorVersion}")
documentationGenerator {
generatorConfigurations = [
... list of configurations ...
]
}Another option is to have your configuration in a separate file. See here the description of the configuration file
The list of configurations consists of the desired configurations.
documentationGenerator {
documentationConfigurationFile = new File('generator-configuration.yml')
}To generate documentation, run:
gradle generateDocumentation