Skip to content

Commit 086f1af

Browse files
author
etienne-sf
committed
Ready for release 2.0RC1
1 parent c3569c0 commit 086f1af

File tree

8 files changed

+38
-26
lines changed

8 files changed

+38
-26
lines changed

Diff for: build.gradle

+1-17
Original file line numberDiff line numberDiff line change
@@ -75,20 +75,4 @@ subprojects {
7575
mustRunAfter cleanSamplesCode
7676
}
7777
}
78-
}
79-
80-
81-
82-
/*
83-
//Let's include the documentation in the distribution archive
84-
distZip {
85-
from project(':graphql-gradle-plugin-docs').asciidoctor, {
86-
into "${project.name}-${version}"
87-
}
88-
}
89-
distTar {
90-
from project(':graphql-gradle-plugin-docs').asciidoctor, {
91-
into "${project.name}-${version}"
92-
}
93-
}
94-
*/
78+
}

Diff for: graphql-gradle-plugin-samples-Forum-client/build.gradle

+5-3
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,15 @@ buildscript {
1616
}
1717

1818
plugins {
19-
id 'java-library'
19+
id 'java'
2020
id 'application'
2121
id 'com.graphql_java_generator.graphql-gradle-plugin'
2222
id 'org.springframework.boot' version "${spring3_springBootVersion}"
2323
id 'io.spring.dependency-management' version "${spring3_DependencyManagementPluginVersion}"
2424
}
2525
sourceCompatibility = '17'
26-
26+
mainClassName = 'com.graphql_java_generator.samples.forum.SpringMain'
27+
2728
repositories {
2829
mavenCentral()
2930
// The plugin depends on the graphql-maven-plugin, whose snapshot versions are on the local maven repository.
@@ -34,7 +35,7 @@ repositories {
3435
dependencies {
3536
implementation 'org.springframework.boot:spring-boot-starter-graphql'
3637
// The graphql-java-client-dependencies module agregates all dependencies for the generated code
37-
implementation "com.graphql-java-generator:graphql-java-client-dependencies:${project.version}"
38+
implementation "com.graphql-java-generator:graphql-java-client-runtime:${project.version}"
3839

3940
// Dependencies for tests
4041
testImplementation "org.springframework.boot:spring-boot-starter-test"
@@ -46,6 +47,7 @@ sourceSets.main.java.srcDirs += '/build/generated/sources/graphqlGradlePlugin'
4647
// Let's configure the GraphQL Gradle Plugin
4748
// (the plugin will automatically add it as a dependency to compileJava and processResources)
4849
graphql {
50+
copyRuntimeSources = false
4951
mode = "client" //This line is here only for the demo, as client is the default mode
5052
packageName = "com.graphql_java_generator.samples.forum.client.graphql.forum.client"
5153
skipGenerationIfSchemaHasNotChanged = true

Diff for: graphql-gradle-plugin-samples-Forum-server/build.gradle

+2-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ buildscript {
2222

2323
plugins {
2424
id 'java-library'
25-
id 'application'
25+
// id 'application'
2626
id 'com.graphql_java_generator.graphql-gradle-plugin'
2727
id 'org.springframework.boot' version "${spring3_springBootVersion}"
2828
id 'io.spring.dependency-management' version "${spring3_DependencyManagementPluginVersion}"
@@ -64,6 +64,7 @@ generateServerCodeConf {
6464
scanBasePackages = "org.forum.server.jpa , org.forum.server.specific_code"
6565
schemaPersonalizationFile = "src/main/graphql/forum_personalization.json"
6666
skipGenerationIfSchemaHasNotChanged = true
67+
useJakartaEE9 = true
6768
customScalars = [ [
6869
graphQLTypeName: "Date",
6970
javaType: "java.util.Date",

Diff for: graphql-gradle-plugin-samples-allGraphQLCases-pojo-client-jackson/build.gradle

+10-1
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,19 @@ buildscript {
1717

1818
plugins {
1919
id 'java-library'
20-
id 'application'
2120
id 'com.graphql_java_generator.graphql-gradle-plugin'
2221
id 'org.springframework.boot' version "${springBootVersion}"
2322
id 'io.spring.dependency-management' version "${springDependencyManagementPluginVersion}"
2423
}
2524

25+
// The two configurations below are mandatory, as there is no main class in this module
26+
bootJar {
27+
enabled = false
28+
}
29+
jar {
30+
enabled = true
31+
}
32+
2633
repositories {
2734
mavenCentral()
2835
// The plugin depends on the graphql-maven-plugin, whose snapshot versions are on the local maven repository.
@@ -33,6 +40,8 @@ repositories {
3340
dependencies {
3441
// And the Jackson annotations
3542
implementation "com.fasterxml.jackson.core:jackson-databind"
43+
// This project uses some custom scalars from the graphql-java-extended-scalars module
44+
implementation "com.graphql-java:graphql-java-extended-scalars:${graphqlJavaExtendedScalarsVersion}"
3645

3746
// Dependencies for tests
3847
testImplementation "org.springframework.boot:spring-boot-starter-test"

Diff for: graphql-gradle-plugin-samples-allGraphQLCases-pojo-client/build.gradle

+8-1
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,19 @@ buildscript {
1717

1818
plugins {
1919
id 'java-library'
20-
id 'application'
2120
id 'com.graphql_java_generator.graphql-gradle-plugin'
2221
id 'org.springframework.boot' version "${springBootVersion}"
2322
id 'io.spring.dependency-management' version "${springDependencyManagementPluginVersion}"
2423
}
2524

25+
// The two configurations below are mandatory, as there is no main class in this module
26+
bootJar {
27+
enabled = false
28+
}
29+
jar {
30+
enabled = true
31+
}
32+
2633
repositories {
2734
mavenCentral()
2835
// The plugin depends on the graphql-maven-plugin, whose snapshot versions are on the local maven repository.

Diff for: graphql-gradle-plugin-samples-allGraphQLCases-pojo-server/build.gradle

+10-1
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,19 @@ buildscript {
1717

1818
plugins {
1919
id 'java-library'
20-
id 'application'
2120
id 'com.graphql_java_generator.graphql-gradle-plugin'
2221
id 'org.springframework.boot' version "${springBootVersion}"
2322
id 'io.spring.dependency-management' version "${springDependencyManagementPluginVersion}"
2423
}
2524

25+
// The two configurations below are mandatory, as there is no main class in this module
26+
bootJar {
27+
enabled = false
28+
}
29+
jar {
30+
enabled = true
31+
}
32+
2633
repositories {
2734
mavenCentral()
2835
// The plugin depends on the graphql-maven-plugin, whose snapshot versions are on the local maven repository.
@@ -31,6 +38,8 @@ repositories {
3138
}
3239

3340
dependencies {
41+
// This project uses some custom scalars from the graphql-java-extended-scalars module
42+
implementation "com.graphql-java:graphql-java-extended-scalars:${graphqlJavaExtendedScalarsVersion}"
3443

3544
// Dependencies for tests
3645
testImplementation "org.springframework.boot:spring-boot-starter-test"

Diff for: graphql-gradle-plugin/src/main/java/com/graphql_java_generator/gradleplugin/GenerateCodeCommonExtension.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ public class GenerateCodeCommonExtension extends CommonExtension implements Gene
145145
* (since 2.0RC) If false, it uses jakarta EE8 imports (that begins by javax.). If true, it uses jakarta EE8 imports
146146
* (that begins by jakarta.).
147147
*/
148-
protected boolean useJakartaEE9;
148+
protected boolean useJakartaEE9 = GenerateCodeCommonConfiguration.DEFAULT_USE_JAKARTA_EE9.equals("true");
149149

150150
public GenerateCodeCommonExtension(Project project) {
151151
super(project);

Diff for: graphql-gradle-plugin/src/main/java/com/graphql_java_generator/gradleplugin/GenerateCodeCommonTask.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ public class GenerateCodeCommonTask extends CommonTask implements GenerateCodeCo
159159
* (since 2.0RC) If false, it uses jakarta EE8 imports (that begins by javax.). If true, it uses jakarta EE8 imports
160160
* (that begins by jakarta.).
161161
*/
162-
protected boolean useJakartaEE9;
162+
protected Boolean useJakartaEE9;
163163

164164
@Inject
165165
public GenerateCodeCommonTask(Class<? extends GenerateCodeCommonExtension> extensionClazz) {

0 commit comments

Comments
 (0)