Improve formatting of generated doc tables
This commit is contained in:
parent
aaa7e7d37e
commit
25a2b8e388
|
@ -10,12 +10,12 @@ def processModule(File moduleDir, File generatedResourcesDir) {
|
||||||
def generateAutoConfigurationClassTable(String module, File factories, PrintWriter writer) {
|
def generateAutoConfigurationClassTable(String module, File factories, PrintWriter writer) {
|
||||||
writer.println '[cols="4,1"]'
|
writer.println '[cols="4,1"]'
|
||||||
writer.println '|==='
|
writer.println '|==='
|
||||||
writer.println '|Configuration Class | Links'
|
writer.println '| Configuration Class | Links'
|
||||||
|
|
||||||
getAutoConfigurationClasses(factories).each {
|
getAutoConfigurationClasses(factories).each {
|
||||||
writer.println ''
|
writer.println ''
|
||||||
writer.println "|{github-code}/$module/src/main/java/$it.path.{sc-ext}[$it.name]"
|
writer.println "| {github-code}/$module/src/main/java/$it.path.{sc-ext}[`$it.name`]"
|
||||||
writer.println "|{dc-root}/$it.path.{dc-ext}[javadoc]"
|
writer.println "| {dc-root}/$it.path.{dc-ext}[javadoc]"
|
||||||
}
|
}
|
||||||
|
|
||||||
writer.println '|==='
|
writer.println '|==='
|
||||||
|
@ -38,4 +38,4 @@ def getAutoConfigurationClasses(File factories) {
|
||||||
|
|
||||||
def autoConfigDir = new File(project.build.directory, 'auto-config')
|
def autoConfigDir = new File(project.build.directory, 'auto-config')
|
||||||
def generatedResourcesDir = new File(project.build.directory, 'generated-resources')
|
def generatedResourcesDir = new File(project.build.directory, 'generated-resources')
|
||||||
autoConfigDir.eachDir { processModule(it, generatedResourcesDir) }
|
autoConfigDir.eachDir { processModule(it, generatedResourcesDir) }
|
||||||
|
|
|
@ -6,20 +6,23 @@
|
||||||
<xsl:output method="text" encoding="UTF-8" indent="no"/>
|
<xsl:output method="text" encoding="UTF-8" indent="no"/>
|
||||||
|
|
||||||
<xsl:template match="/">
|
<xsl:template match="/">
|
||||||
<xsl:text>|==================================
</xsl:text>
|
<xsl:text>|===
</xsl:text>
|
||||||
<xsl:text>| Group ID | Artifact ID | Version
</xsl:text>
|
<xsl:text>| Group ID | Artifact ID | Version
</xsl:text>
|
||||||
<xsl:for-each select="//mvn:dependency">
|
<xsl:for-each select="//mvn:dependency">
|
||||||
<xsl:sort select="mvn:groupId"/>
|
<xsl:sort select="mvn:groupId"/>
|
||||||
<xsl:sort select="mvn:artifactId"/>
|
<xsl:sort select="mvn:artifactId"/>
|
||||||
<xsl:text>| </xsl:text>
|
<xsl:text>
</xsl:text>
|
||||||
|
<xsl:text>| `</xsl:text>
|
||||||
<xsl:copy-of select="mvn:groupId"/>
|
<xsl:copy-of select="mvn:groupId"/>
|
||||||
<xsl:text> | </xsl:text>
|
<xsl:text>`
</xsl:text>
|
||||||
|
<xsl:text>| `</xsl:text>
|
||||||
<xsl:copy-of select="mvn:artifactId"/>
|
<xsl:copy-of select="mvn:artifactId"/>
|
||||||
<xsl:text> | </xsl:text>
|
<xsl:text>`
</xsl:text>
|
||||||
|
<xsl:text>| </xsl:text>
|
||||||
<xsl:copy-of select="mvn:version"/>
|
<xsl:copy-of select="mvn:version"/>
|
||||||
<xsl:text>
</xsl:text>
|
<xsl:text>
</xsl:text>
|
||||||
</xsl:for-each>
|
</xsl:for-each>
|
||||||
<xsl:text>|==================================</xsl:text>
|
<xsl:text>|===</xsl:text>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
</xsl:stylesheet>
|
</xsl:stylesheet>
|
||||||
|
|
Loading…
Reference in New Issue