From 68b5f866ffbfb014eba9685e8bd2cfaf4aeddff0 Mon Sep 17 00:00:00 2001 From: William Cheng Date: Sun, 31 Oct 2021 23:10:46 +0800 Subject: [PATCH] update readme with better gradle instruction (#10740) --- .../Java/libraries/okhttp-gson/README.mustache | 11 +++++++++-- .../others/java/okhttp-gson-streaming/README.md | 11 +++++++++-- .../java/okhttp-gson-dynamicOperations/README.md | 11 +++++++++-- .../java/okhttp-gson-parcelableModel/README.md | 11 +++++++++-- samples/client/petstore/java/okhttp-gson/README.md | 11 +++++++++-- 5 files changed, 45 insertions(+), 10 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/Java/libraries/okhttp-gson/README.mustache b/modules/openapi-generator/src/main/resources/Java/libraries/okhttp-gson/README.mustache index dd21bcad45f..a1a142bd488 100644 --- a/modules/openapi-generator/src/main/resources/Java/libraries/okhttp-gson/README.mustache +++ b/modules/openapi-generator/src/main/resources/Java/libraries/okhttp-gson/README.mustache @@ -19,7 +19,7 @@ Building the API client library requires: 1. Java {{#java8}}1.8{{/java8}}{{^java8}}1.7{{/java8}}+ -2. Maven/Gradle +2. Maven (3.8.3+)/Gradle (7.2+) ## Installation @@ -55,7 +55,14 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "{{{groupId}}}:{{{artifactId}}}:{{{artifactVersion}}}" + repositories { + mavenCentral() // Needed if the '{{{artifactId}}}' jar has been published to maven central. + mavenLocal() // Needed if the '{{{artifactId}}}' jar has been published to the local maven repo. + } + + dependencies { + implementation "{{{groupId}}}:{{{artifactId}}}:{{{artifactVersion}}}" + } ``` ### Others diff --git a/samples/client/others/java/okhttp-gson-streaming/README.md b/samples/client/others/java/okhttp-gson-streaming/README.md index 4f967a17bac..418a3fb4278 100644 --- a/samples/client/others/java/okhttp-gson-streaming/README.md +++ b/samples/client/others/java/okhttp-gson-streaming/README.md @@ -13,7 +13,7 @@ No description provided (generated by Openapi Generator https://github.com/opena Building the API client library requires: 1. Java 1.7+ -2. Maven/Gradle +2. Maven (3.8.3+)/Gradle (7.2+) ## Installation @@ -49,7 +49,14 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "org.openapitools:petstore-okhttp-gson:1.0" + repositories { + mavenCentral() // Needed if the 'petstore-okhttp-gson' jar has been published to maven central. + mavenLocal() // Needed if the 'petstore-okhttp-gson' jar has been published to the local maven repo. + } + + dependencies { + implementation "org.openapitools:petstore-okhttp-gson:1.0" + } ``` ### Others diff --git a/samples/client/petstore/java/okhttp-gson-dynamicOperations/README.md b/samples/client/petstore/java/okhttp-gson-dynamicOperations/README.md index b45b974dee3..c25c1a39c47 100644 --- a/samples/client/petstore/java/okhttp-gson-dynamicOperations/README.md +++ b/samples/client/petstore/java/okhttp-gson-dynamicOperations/README.md @@ -13,7 +13,7 @@ This spec is mainly for testing Petstore server and contains fake endpoints, mod Building the API client library requires: 1. Java 1.7+ -2. Maven/Gradle +2. Maven (3.8.3+)/Gradle (7.2+) ## Installation @@ -49,7 +49,14 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "org.openapitools:petstore-okhttp-gson-dynamicoperations:1.0.0" + repositories { + mavenCentral() // Needed if the 'petstore-okhttp-gson-dynamicoperations' jar has been published to maven central. + mavenLocal() // Needed if the 'petstore-okhttp-gson-dynamicoperations' jar has been published to the local maven repo. + } + + dependencies { + implementation "org.openapitools:petstore-okhttp-gson-dynamicoperations:1.0.0" + } ``` ### Others diff --git a/samples/client/petstore/java/okhttp-gson-parcelableModel/README.md b/samples/client/petstore/java/okhttp-gson-parcelableModel/README.md index 906bc302af8..40458ad8a74 100644 --- a/samples/client/petstore/java/okhttp-gson-parcelableModel/README.md +++ b/samples/client/petstore/java/okhttp-gson-parcelableModel/README.md @@ -13,7 +13,7 @@ This spec is mainly for testing Petstore server and contains fake endpoints, mod Building the API client library requires: 1. Java 1.7+ -2. Maven/Gradle +2. Maven (3.8.3+)/Gradle (7.2+) ## Installation @@ -49,7 +49,14 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "org.openapitools:petstore-okhttp-gson-parcelableModel:1.0.0" + repositories { + mavenCentral() // Needed if the 'petstore-okhttp-gson-parcelableModel' jar has been published to maven central. + mavenLocal() // Needed if the 'petstore-okhttp-gson-parcelableModel' jar has been published to the local maven repo. + } + + dependencies { + implementation "org.openapitools:petstore-okhttp-gson-parcelableModel:1.0.0" + } ``` ### Others diff --git a/samples/client/petstore/java/okhttp-gson/README.md b/samples/client/petstore/java/okhttp-gson/README.md index 516d98bed0a..8a02b7818b8 100644 --- a/samples/client/petstore/java/okhttp-gson/README.md +++ b/samples/client/petstore/java/okhttp-gson/README.md @@ -13,7 +13,7 @@ This spec is mainly for testing Petstore server and contains fake endpoints, mod Building the API client library requires: 1. Java 1.7+ -2. Maven/Gradle +2. Maven (3.8.3+)/Gradle (7.2+) ## Installation @@ -49,7 +49,14 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "org.openapitools:petstore-okhttp-gson:1.0.0" + repositories { + mavenCentral() // Needed if the 'petstore-okhttp-gson' jar has been published to maven central. + mavenLocal() // Needed if the 'petstore-okhttp-gson' jar has been published to the local maven repo. + } + + dependencies { + implementation "org.openapitools:petstore-okhttp-gson:1.0.0" + } ``` ### Others