[英]How generate documentation with maven-swagger-codegen-plugin?
I have configured swagger-codegen-plugin like that 我已经配置了swagger-codegen-plugin
<plugin>
<groupId>io.swagger</groupId>
<artifactId>swagger-codegen-maven-plugin</artifactId>
<version>2.1.5</version>
<executions>
<execution>
<goals>
<goal>generate</goal>
</goals>
<configuration>
<inputSpec>${project.basedir}/src/main/resources/model.json</inputSpec>
<language>java</language>
<configOptions>
<sourceFolder>src/gen/java/main</sourceFolder>
</configOptions>
<modelPackage>com.mypackage</modelPackage>
<environmentVariables>
<models></models>
<supportingFiles>false</supportingFiles>
</environmentVariables>
</configuration>
</execution>
</executions>
</plugin>
Everything works, but when I change language to <language>html</language>
nothing was generate. 一切正常,但当我将语言改为
<language>html</language>
没有任何内容生成。
So how to generation staitc html documentation? 那么如何生成staitc html文档呢?
At present, you are specifying the language as <language>java</language>
to generate html this should either be <language>html</language>
or <language>html2</language>
as this specifies the output language generator for swagger-codegen. 目前,您将语言指定为
<language>java</language>
以生成html,这应该是<language>html</language>
或<language>html2</language>
因为它指定了swagger的输出语言生成器-codegen。
There are 2 different html generators so you will need to decide your preferred flavour. 有2个不同的html生成器,所以你需要决定你喜欢的味道。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.