swagger-api / swagger-api/swagger-codegen
[swagger-codegen-3.0.0-rc0] Inflector missing gradle support
Open
@HugoMario is already working on this.
Since Feb 6, 2018.
- Dominant language
- Mustache
- Stars
- 17.8k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
Description
java -jar swagger-codegen-cli.jar generate \
-i testing_openapi_3.json \
-l inflector -o server/
Inflector on the 3.0.0 branch lacks gradle support. A pom.xml file is generated, however there's nobuild.gradle
Swagger-codegen version
3.0.0
Suggest a fix/enhancement
Here's my gradle script.
plugins {
id 'org.akhikhl.gretty' version '2.0.0'
}
apply plugin: 'java'
apply plugin: 'maven'
group = 'io.swagger'
version = '1.0.0'
description = """swagger-inflector-server"""
sourceCompatibility = 1.8
targetCompatibility = 1.8
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
// http://akhikhl.github.io/gretty-doc/Gretty-configuration.html
gretty {
httpPort = 8080
contextPath = '/'
httpIdleTimeout = 60000
scanInterval = 1
scanDir 'inflector.yaml'
scanDir 'src/main/swagger/swagger.yaml'
}
sourceSets {
main {
java {
srcDirs 'src/gen/java'
}
}
}
repositories {
jcenter()
}
dependencies {
compile 'io.swagger:swagger-inflector:2.0.0-rc1'
}
Why is maven supported? It seems like it'd be less work to standardize on Gradle.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.