Skip to content

Commit d99a040

Browse files
committed
upgrade gradle
1 parent 37162f2 commit d99a040

11 files changed

Lines changed: 95 additions & 74 deletions

File tree

modules/openapi-generator-gradle-plugin/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ plugins {
77
id("io.github.gradle-nexus.publish-plugin") version "1.1.0"
88
id("java-gradle-plugin")
99
id("maven-publish")
10-
id("org.gradle.kotlin.kotlin-dsl") version "2.4.1"
10+
id("org.gradle.kotlin.kotlin-dsl") version "5.2.0"
1111
id("org.jetbrains.kotlin.jvm") version "1.9.0"
1212
id("signing")
1313
}
Binary file not shown.
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.4-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.4-bin.zip
44
networkTimeout=10000
5+
validateDistributionUrl=true
56
zipStoreBase=GRADLE_USER_HOME
67
zipStorePath=wrapper/dists

modules/openapi-generator-gradle-plugin/gradlew

Lines changed: 22 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

modules/openapi-generator-gradle-plugin/gradlew.bat

Lines changed: 14 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

modules/openapi-generator-gradle-plugin/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717

1818
<properties>
1919
<skipNexusStagingDeployMojo>true</skipNexusStagingDeployMojo>
20-
<gradleVersion>7.6.4</gradleVersion>
21-
<gradle-tooling.version>7.4.2</gradle-tooling.version>
20+
<gradleVersion>8.14.4</gradleVersion>
21+
<gradle-tooling.version>8.14.4</gradle-tooling.version>
2222
</properties>
2323

2424
<pluginRepositories>

modules/openapi-generator-gradle-plugin/samples/local-spec/build.gradle

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -23,19 +23,19 @@ apply plugin: 'org.openapi.generator'
2323
openApiMeta {
2424
generatorName = "Sample"
2525
packageName = "org.openapitools.example"
26-
outputFolder = "$buildDir/meta".toString()
26+
outputFolder = layout.buildDirectory.dir("meta")
2727
}
2828

2929
openApiValidate {
30-
inputSpec = "$rootDir/petstore-v3.0-invalid.yaml".toString()
30+
inputSpec = layout.projectDirectory.file("petstore-v3.0-invalid.yaml")
3131
recommend = true
3232
}
3333

3434
// Builds a Kotlin client by default.
3535
openApiGenerate {
3636
generatorName = "kotlin"
37-
inputSpec = "$rootDir/petstore-v3.0.yaml".toString()
38-
outputDir = "$buildDir/kotlin".toString()
37+
inputSpec = layout.projectDirectory.file("petstore-v3.0.yaml")
38+
outputDir = layout.buildDirectory.dir("kotlin")
3939
apiPackage = "org.openapitools.example.api"
4040
invokerPackage = "org.openapitools.example.invoker"
4141
modelPackage = "org.openapitools.example.model"
@@ -57,8 +57,8 @@ openApiGenerate {
5757
task buildJavaResttemplateSdk(type: org.openapitools.generator.gradle.plugin.tasks.GenerateTask) {
5858
generatorName = "java"
5959
library = "resttemplate"
60-
inputSpec = "$rootDir/petstore-v3.0.yaml".toString()
61-
outputDir = "$buildDir/java-resttemplate-api-client"
60+
inputSpec = layout.projectDirectory.file("petstore-v3.0.yaml")
61+
outputDir = layout.buildDirectory.dir("java-resttemplate-api-client")
6262
apiPackage = "com.example.client"
6363
invokerPackage = "com.example.invoker"
6464
modelPackage = "com.example.cdm"
@@ -75,24 +75,24 @@ task buildJavaResttemplateSdk(type: org.openapitools.generator.gradle.plugin.tas
7575

7676
task buildGoSdk(type: org.openapitools.generator.gradle.plugin.tasks.GenerateTask){
7777
generatorName = "go"
78-
inputSpec = "$rootDir/petstore-v3.0.yaml".toString()
78+
inputSpec = layout.projectDirectory.file("petstore-v3.0.yaml")
7979
additionalProperties = [
8080
packageName: "petstore"
8181
]
82-
outputDir = "$buildDir/go".toString()
82+
outputDir = layout.buildDirectory.dir("go")
8383
configOptions = [
8484
dateLibrary: "threetenp"
8585
]
8686
}
8787

8888
task buildDotnetSdk(type: org.openapitools.generator.gradle.plugin.tasks.GenerateTask){
8989
generatorName = "csharp"
90-
inputSpec = "$rootDir/petstore-v3.0.yaml".toString()
90+
inputSpec = layout.projectDirectory.file("petstore-v3.0.yaml")
9191
additionalProperties = [
9292
packageGuid: "{321C8C3F-0156-40C1-AE42-D59761FB9B6C}",
9393
useCompareNetObjects: "true"
9494
]
95-
outputDir = "$buildDir/csharp".toString()
95+
outputDir = layout.buildDirectory.dir("csharp")
9696
globalProperties = [
9797
models: "",
9898
apis : "",
@@ -102,22 +102,22 @@ task buildDotnetSdk(type: org.openapitools.generator.gradle.plugin.tasks.Generat
102102
task generateGoWithInvalidSpec(type: org.openapitools.generator.gradle.plugin.tasks.GenerateTask){
103103
validateSpec = true
104104
generatorName = "go"
105-
inputSpec = "$rootDir/petstore-v3.0-invalid.yaml".toString()
105+
inputSpec = layout.projectDirectory.file("petstore-v3.0-invalid.yaml")
106106
additionalProperties = [
107107
packageName: "petstore"
108108
]
109-
outputDir = "$buildDir/go".toString()
109+
outputDir = layout.buildDirectory.dir("go")
110110
configOptions = [
111111
dateLibrary: "threetenp"
112112
]
113113
}
114114

115115
task validateGoodSpec(type: org.openapitools.generator.gradle.plugin.tasks.ValidateTask){
116-
inputSpec = "$rootDir/petstore-v3.0.yaml".toString()
116+
inputSpec = layout.projectDirectory.file("petstore-v3.0.yaml")
117117
}
118118

119119
task validateBadSpec(type: org.openapitools.generator.gradle.plugin.tasks.ValidateTask){
120-
inputSpec = "$rootDir/petstore-v3.0-invalid.yaml".toString()
120+
inputSpec = layout.projectDirectory.file("petstore-v3.0-invalid.yaml")
121121
}
122122

123123
task validateSpecs(dependsOn: ['validateGoodSpec', 'validateBadSpec'])
Binary file not shown.
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.4-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.4-bin.zip
4+
networkTimeout=10000
5+
validateDistributionUrl=true
46
zipStoreBase=GRADLE_USER_HOME
57
zipStorePath=wrapper/dists

modules/openapi-generator-gradle-plugin/samples/local-spec/gradlew

Lines changed: 22 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)