未验证 提交 6e1bde7d 编写于 作者: B Bogdan Kobylynskyi 提交者: GitHub

Merge pull request #1057 from kobylynskyi/develop

5.7.1 Release
......@@ -9,7 +9,7 @@ plugins {
id "org.sonarqube" version "3.2.0"
}
def graphqlCodegenVersion = '5.7.0' // This variable used in the automatic release process
def graphqlCodegenVersion = '5.7.1' // This variable used in the automatic release process
group = "io.github.kobylynskyi"
version = graphqlCodegenVersion
......
......@@ -17,7 +17,7 @@
```groovy
plugins {
id "io.github.kobylynskyi.graphql.codegen" version "5.7.0"
id "io.github.kobylynskyi.graphql.codegen" version "5.7.1"
}
```
......@@ -31,7 +31,7 @@ buildscript {
}
}
dependencies {
classpath "io.github.kobylynskyi.graphql.codegen:graphql-codegen-gradle-plugin:5.7.0"
classpath "io.github.kobylynskyi.graphql.codegen:graphql-codegen-gradle-plugin:5.7.1"
}
}
......
......@@ -4,10 +4,10 @@ import io.github.kobylynskyi.graphql.codegen.gradle.GraphQLCodegenGradleTask
plugins {
id "java"
id "org.jetbrains.kotlin.jvm" version "1.6.21"
id "io.github.kobylynskyi.graphql.codegen" version "5.7.0"
id "io.github.kobylynskyi.graphql.codegen" version "5.7.1"
}
def graphqlCodegenClientKotlinVersion = '5.7.0' // Variable used in the automatic release process
def graphqlCodegenClientKotlinVersion = '5.7.1' // Variable used in the automatic release process
group = 'io.github.dreamylost'
version = graphqlCodegenClientKotlinVersion
......@@ -29,7 +29,7 @@ repositories {
dependencies {
implementation "io.github.kobylynskyi:graphql-java-codegen:5.7.0"
implementation "io.github.kobylynskyi:graphql-java-codegen:5.7.1"
implementation "javax.validation:validation-api:2.0.1.Final"
implementation "com.squareup.okhttp3:okhttp:4.2.2"
implementation "com.fasterxml.jackson.core:jackson-core:2.13.3"
......@@ -37,8 +37,8 @@ dependencies {
implementation "com.fasterxml.jackson.module:jackson-module-kotlin:2.13.3"
implementation "com.fasterxml.jackson.core:jackson-annotations:2.13.3"
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
testImplementation "org.junit.jupiter:junit-jupiter-api:5.7.0"
testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:5.7.0"
testImplementation "org.junit.jupiter:junit-jupiter-api:5.7.1"
testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:5.7.1"
}
/**
......
......@@ -7,7 +7,7 @@ plugins {
// use the latest available version:
// https://plugins.gradle.org/plugin/io.github.kobylynskyi.graphql.codegen
id "io.github.kobylynskyi.graphql.codegen" version "5.7.0"
id "io.github.kobylynskyi.graphql.codegen" version "5.7.1"
}
mainClassName = "io.github.kobylynskyi.order.Application"
......@@ -22,7 +22,7 @@ dependencies {
// use the latest available version:
// https://search.maven.org/artifact/io.github.kobylynskyi/graphql-java-codegen
implementation "io.github.kobylynskyi:graphql-java-codegen:5.7.0"
implementation "io.github.kobylynskyi:graphql-java-codegen:5.7.1"
implementation "org.apache.httpcomponents:httpclient:4.5.13"
implementation "javax.validation:validation-api:2.0.1.Final"
......
......@@ -6,7 +6,7 @@ plugins {
//
// use the latest available version:
// https://plugins.gradle.org/plugin/io.github.kobylynskyi.graphql.codegen
id "io.github.kobylynskyi.graphql.codegen" version "5.7.0"
id "io.github.kobylynskyi.graphql.codegen" version "5.7.1"
}
mainClassName = "io.github.kobylynskyi.product.Application"
......
......@@ -16,7 +16,7 @@ apply plugin: "java"
apply plugin: "idea"
apply plugin: "maven-publish"
def graphqlCodegenGradlePluginVersion = '5.7.0' // This variable used in the automatic release process
def graphqlCodegenGradlePluginVersion = '5.7.1' // This variable used in the automatic release process
group = "io.github.kobylynskyi"
version = graphqlCodegenGradlePluginVersion
......
......@@ -134,6 +134,8 @@ public class GraphQLCodegenGradleTask extends DefaultTask implements GraphQLCode
mappingConfig.setPackageName(packageName);
mappingConfig.setCustomTypesMapping(
customTypesMapping != null ? customTypesMapping : new HashMap<>());
mappingConfig.setCustomAnnotationsMapping(
customAnnotationsMapping != null ? customAnnotationsMapping : new HashMap<>());
mappingConfig.setCustomTemplates(
customTemplates != null ? customTemplates : new HashMap<>());
mappingConfig.setDirectiveAnnotationsMapping(
......
......@@ -20,7 +20,7 @@
<plugin>
<groupId>io.github.kobylynskyi</groupId>
<artifactId>graphql-codegen-maven-plugin</artifactId>
<version>5.7.0</version>
<version>5.7.1</version>
<executions>
<execution>
<goals>
......
......@@ -4,7 +4,7 @@
<groupId>io.github.kobylynskyi</groupId>
<artifactId>graphql-codegen-maven-plugin-example-client</artifactId>
<version>5.7.0</version>
<version>5.7.1</version>
<name>graphql-codegen-maven-plugin-example-client</name>
<build>
......
......@@ -4,7 +4,7 @@
<groupId>io.github.kobylynskyi</groupId>
<artifactId>graphql-codegen-maven-plugin-example-server</artifactId>
<version>5.7.0</version>
<version>5.7.1</version>
<name>graphql-codegen-maven-plugin-example-server</name>
<build>
......
......@@ -3,7 +3,7 @@
<groupId>io.github.kobylynskyi</groupId>
<artifactId>graphql-codegen-maven-plugin</artifactId>
<version>5.7.0</version>
<version>5.7.1</version>
<packaging>maven-plugin</packaging>
<name>graphql-codegen-maven-plugin</name>
......@@ -72,7 +72,7 @@
<version.maven-gpg-plugin>3.0.1</version.maven-gpg-plugin>
<version.maven-shared-utils>3.3.4</version.maven-shared-utils>
<version.graphql-java-codegen>5.7.0</version.graphql-java-codegen>
<version.graphql-java-codegen>5.7.1</version.graphql-java-codegen>
</properties>
<dependencies>
......
addSbtPlugin("io.github.jxnu-liguobin" % "graphql-codegen-sbt-plugin" % "5.7.0")
addSbtPlugin("io.github.jxnu-liguobin" % "graphql-codegen-sbt-plugin" % "5.7.1")
addSbtPlugin("io.github.jxnu-liguobin" % "graphql-codegen-sbt-plugin" % "5.7.0")
addSbtPlugin("io.github.jxnu-liguobin" % "graphql-codegen-sbt-plugin" % "5.7.1")
sys.props.get("plugin.version").orElse(Some("5.7.0")) match {
sys.props.get("plugin.version").orElse(Some("5.7.1")) match {
case Some(x) => addSbtPlugin("io.github.jxnu-liguobin" % "graphql-codegen-sbt-plugin" % x)
case _ => sys.error("""|The system property 'plugin.version' is not defined.
|Specify this property using the scriptedLaunchOpts -D.""".stripMargin)
......
ThisBuild / version := "5.7.0"
ThisBuild / version := "5.7.1"
......@@ -76,6 +76,19 @@ class GraphQLCodegenAnnotationsTest {
" private org.joda.time.DateTime createdDateTime;");
}
@Test
void generate_CustomAnnotationMappings_Input() throws Exception {
mappingConfig.setCustomAnnotationsMapping(new HashMap<>(singletonMap("ReproInput.reproField",
singletonList("@com.fasterxml.jackson.annotation.JsonProperty(\"reproField\")"))));
generate("src/test/resources/schemas/input.graphqls");
File[] files = Objects.requireNonNull(outputJavaClassesDir.listFiles());
assertFileContainsElements(files, "ReproInput.java",
" @com.fasterxml.jackson.annotation.JsonProperty(\"reproField\")\n" +
" private java.util.List<String> reproField;");
}
@Test
void generate_CustomAnnotationMappings_Regexp() throws Exception {
mappingConfig.setCustomTypesMapping(new HashMap<>(singletonMap("DateTime", "org.joda.time.DateTime")));
......
schema {
query: Query
}
type Query {
repro(input: ReproInput!): ReproOutput
}
input ReproInput {
reproField: [String!]!
}
type ReproOutput {
id: ID!
}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册