Skip to content

Commit 3e13382

Browse files
committed
jooby-cli: sync with latest 4.0
- fix #3745 - fix #3744 - templates clean up
1 parent a261e78 commit 3e13382

File tree

6 files changed

+19
-14
lines changed

6 files changed

+19
-14
lines changed

modules/jooby-cli/pom.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@
112112
<groupId>org.apache.maven.plugins</groupId>
113113
<artifactId>maven-compiler-plugin</artifactId>
114114
<version>${maven-compiler-plugin.version}</version>
115+
<inherited>false</inherited>
115116
<configuration>
116117
<annotationProcessorPaths>
117118
<path>
@@ -123,6 +124,9 @@
123124
<compilerArgs>
124125
<arg>-Aproject=${project.groupId}/${project.artifactId}</arg>
125126
</compilerArgs>
127+
<source>17</source>
128+
<target>17</target>
129+
<release>17</release>
126130
</configuration>
127131
</plugin>
128132
<plugin>

modules/jooby-cli/src/main/java/io/jooby/cli/CreateCmd.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ private List<Dependency> testDependencies(Map<String, String> dependencyMap, boo
345345
"org.junit.jupiter", "junit-jupiter-engine", dependencyMap.get("junitVersion")));
346346
dependencies.add(new Dependency("io.jooby", "jooby-test", null));
347347
dependencies.add(
348-
new Dependency("com.squareup.okhttp3", "okhttp", dependencyMap.get("okhttpVersion")));
348+
new Dependency("com.squareup.okhttp3", "okhttp-jvm", dependencyMap.get("okhttpVersion")));
349349
return dependencies;
350350
}
351351
}

modules/jooby-cli/src/main/resources/cli/build.gradle.hbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ plugins {
1818
group "{{groupId}}"
1919
version "{{version}}"
2020
mainClassName = "{{package}}.App"
21-
sourceCompatibility = 17
21+
sourceCompatibility = 21
2222

2323
repositories {
2424
mavenLocal()

modules/jooby-cli/src/main/resources/cli/build.gradle.kts.hbs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,12 @@ dependencies {
4343

4444
testImplementation("org.jetbrains.kotlin:kotlin-test")
4545
testImplementation("io.jooby:jooby-test")
46-
testImplementation("com.squareup.okhttp3:okhttp:4.12.0")
46+
testImplementation("com.squareup.okhttp3:okhttp-jvm:5.1.0")
4747
}
4848

4949

5050
kotlin {
51-
jvmToolchain(17)
51+
jvmToolchain(21)
5252

5353
compilerOptions {
5454
javaParameters = true
@@ -59,8 +59,8 @@ tasks {
5959
{{#if kapt}}
6060
kapt {
6161
arguments {
62-
arg("jooby.incremental", true)
63-
arg("jooby.debug", false)
62+
arg("jooby.incremental", "true")
63+
arg("jooby.debug", "false")
6464
}
6565
}
6666
{{/if}}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
javaVersion=17
1+
javaVersion=21
22
{{#if kotlin}}systemProp.kotlinVersion={{kotlinVersion}}{{/if}}
33
systemProp.joobyVersion={{joobyVersion}}

modules/jooby-cli/src/main/resources/cli/pom.xml.hbs

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@
2121
<kotlin.version>{{kotlinVersion}}</kotlin.version>
2222
<kotlin.compiler.incremental>true</kotlin.compiler.incremental>
2323
{{/if}}
24-
<maven.compiler.source>17</maven.compiler.source>
25-
<maven.compiler.target>17</maven.compiler.target>
24+
<maven.compiler.source>21</maven.compiler.source>
25+
<maven.compiler.target>21</maven.compiler.target>
2626
<maven.compiler.parameters>true</maven.compiler.parameters>
2727
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
2828
</properties>
@@ -32,16 +32,20 @@
3232
<dependency>
3333
<groupId>{{groupId}}</groupId>
3434
<artifactId>{{artifactId}}</artifactId>
35-
{{#if version}}<version>{{version}}</version>{{/if}}
35+
{{~#if version~}}<version>{{version}}</version>{{~/if}}
3636
</dependency>
3737
{{/each}}
3838
<!-- Tests -->
3939
{{#each testDependencies}}
4040
<dependency>
4141
<groupId>{{groupId}}</groupId>
4242
<artifactId>{{artifactId}}</artifactId>
43-
{{#if version}}<version>{{version}}</version>{{/if}}
43+
{{#if version}}
44+
<version>{{version}}</version>
4445
<scope>test</scope>
46+
{{else}}
47+
<scope>test</scope>
48+
{{/if}}
4549
</dependency>
4650
{{/each}}
4751
</dependencies>
@@ -130,9 +134,6 @@
130134
<compilerArg>
131135
-Ajooby.debug=false
132136
</compilerArg>
133-
<compilerArg>
134-
-Ajooby.services=true
135-
</compilerArg>
136137
</compilerArgs>
137138
</configuration>
138139
{{/if}}

0 commit comments

Comments
 (0)