This is a Gradle plugin that is generating a Project or Architecture description. The description is generating using Freemarker templates.
The templates are Markdown based. They have to have '.md.ftl
' suffix, so that
plugin can process them.
Diagraming is supported using PlantUml component.
It is a Gradle model that is supplied to Freemarker template engine, so all project properties, embedded or extended, are available for templates.
The directory containing templates and output directory are configurable.
In your build.gradle
file, add following plugin:
apply plugin: com.biformatic.archtools.ArchDescription
By default, Templates are located in $rootDir/templates
and output is in
$buildDir/description
. Both of these can be configured:
apply plugin: com.biformatic.archtools.ArchDescription
// as example, this is java based project
apply plugin: java
documentation {
templateDir = 'source-description'
outputDir = 'output-description'
}
This plugin adds documentation
task to the project, which initiates the
process of generating the Project or Architecture description. In short,
./gradlew documentation
will invoke this task.
As a result, in outputDir
you will gave Markdown files generated.
documentation {
templateDir = 'source-description'
outputDir = 'output-description'
genHtml = true
}
By setting genHtml
to true
, this plugin will do another pass and convert
Markdown files to Html. The plugin uses Strapdown.js component
for such conversion.
Go to example
directory directory to check out how to use.