Skip to content

Commit 5e6ab47

Browse files
authored
Update requirement docs for Java 17 (#2566)
2 parents 42de333 + b6d8dc0 commit 5e6ab47

File tree

7 files changed

+14
-14
lines changed

7 files changed

+14
-14
lines changed

CHANGES.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ We adhere to the [keepachangelog](https://keepachangelog.com/en/1.0.0/) format (
1414
* **BREAKING** Bump the required Java to `17`. ([#2375](https://github.com/diffplug/spotless/issues/2375), [#2540](https://github.com/diffplug/spotless/pull/2540))
1515
* Bump JGit from `6.10.1` to `7.3.0` ([#2257](https://github.com/diffplug/spotless/pull/2257))
1616
* Adds support for worktrees (fixes [#1765](https://github.com/diffplug/spotless/issues/1765))
17-
* Should improve the search for system-global git config.
1817
* Bump default `google-java-format` version to latest `1.24.0` -> `1.28.0`. ([#2345](https://github.com/diffplug/spotless/pull/2345))
1918

2019
## [3.3.1] - 2025-07-21

lib-extra/build.gradle

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -77,12 +77,10 @@ tasks.withType(Test).configureEach {
7777

7878
apply plugin: 'dev.equo.p2deps'
7979
p2deps {
80-
if (JavaVersion.current().isCompatibleWith(JavaVersion.VERSION_17)) {
81-
into 'cdtCompileOnly', {
82-
p2repo 'https://download.eclipse.org/eclipse/updates/4.26/'
83-
p2repo 'https://download.eclipse.org/tools/cdt/releases/11.0/'
84-
install 'org.eclipse.cdt.core'
85-
}
80+
into 'cdtCompileOnly', {
81+
p2repo 'https://download.eclipse.org/eclipse/updates/4.26/'
82+
p2repo 'https://download.eclipse.org/tools/cdt/releases/11.0/'
83+
install 'org.eclipse.cdt.core'
8684
}
8785
into 'groovyCompileOnly', {
8886
p2repo 'https://download.eclipse.org/eclipse/updates/4.26/'

lib-extra/src/main/java/com/diffplug/spotless/extra/GitAttributesLineEndings.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,8 +192,10 @@ static class RuntimeInit {
192192
/////////////////////////////////
193193
// USER AND SYSTEM-WIDE VALUES //
194194
/////////////////////////////////
195-
FS.DETECTED.setGitSystemConfig(new File("no-global-git-config-for-spotless")); // this fixes a problem
196-
// that was only occurring on Java 11. If we remove support for Java 11, we could probably remove it.
195+
FS.DETECTED.setGitSystemConfig(new File("no-global-git-config-for-spotless"));
196+
// ^^^ fixes a problem that was only occurring on Java 11. If we remove support for Java 11, we could probably remove it.
197+
// EDIT: Wrong, when Java 17 became the baseline it only happens on Java 17. https://github.com/diffplug/spotless/issues/2375#issuecomment-2573885902
198+
197199
systemConfig = SystemReader.getInstance().openSystemConfig(null, FS.DETECTED);
198200
Errors.log().run(systemConfig::load);
199201
userConfig = SystemReader.getInstance().openUserConfig(systemConfig, FS.DETECTED);

plugin-gradle/CHANGES.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ We adhere to the [keepachangelog](https://keepachangelog.com/en/1.0.0/) format (
77
* **BREAKING** Bump the required Gradle to `7.3` and required Java to `17`. ([#2375](https://github.com/diffplug/spotless/issues/2375), [#2540](https://github.com/diffplug/spotless/pull/2540))
88
* Bump JGit from `6.10.1` to `7.3.0` ([#2257](https://github.com/diffplug/spotless/pull/2257))
99
* Adds support for worktrees (fixes [#1765](https://github.com/diffplug/spotless/issues/1765))
10-
* Should improve the search for system-global git config.
1110
* Bump default `google-java-format` version to latest `1.24.0` -> `1.28.0`. ([#2345](https://github.com/diffplug/spotless/pull/2345))
1211

1312
## [7.2.1] - 2025-07-21

plugin-gradle/README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,10 +137,11 @@ All the generic steps live in [`FormatExtension`](https://javadoc.io/doc/com.dif
137137

138138
### Requirements
139139

140-
Spotless requires JRE 11+ and Gradle 6.1.1 or newer.
140+
Spotless requires JRE 17+ and Gradle 7.3 or newer.
141141

142+
- If you're stuck on JRE 11, use [`id 'com.diffplug.spotless' version '7.2.1'` or older](https://github.com/diffplug/spotless/blob/main/plugin-gradle/CHANGES.md#721---2025-07-21).
142143
- If you're stuck on JRE 8, use [`id 'com.diffplug.spotless' version '6.13.0'` or older](https://github.com/diffplug/spotless/blob/main/plugin-gradle/CHANGES.md#6130---2023-01-14).
143-
- If you're stuck on an older version of Gradle, [`id 'com.diffplug.gradle.spotless' version '4.5.1'` supports all the way back to Gradle 2.x](https://github.com/diffplug/spotless/blob/main/plugin-gradle/CHANGES.md#451---2020-07-04).
144+
- If you're stuck on a very old version of Gradle, [`id 'com.diffplug.gradle.spotless' version '4.5.1'` supports all the way back to Gradle 2.x](https://github.com/diffplug/spotless/blob/main/plugin-gradle/CHANGES.md#451---2020-07-04).
144145

145146
### Git hook
146147

plugin-maven/CHANGES.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ We adhere to the [keepachangelog](https://keepachangelog.com/en/1.0.0/) format (
77
* **BREAKING** Bump the required Java to `17`. ([#2375](https://github.com/diffplug/spotless/issues/2375), [#2540](https://github.com/diffplug/spotless/pull/2540))
88
* Bump JGit from `6.10.1` to `7.3.0` ([#2257](https://github.com/diffplug/spotless/pull/2257))
99
* Adds support for worktrees (fixes [#1765](https://github.com/diffplug/spotless/issues/1765))
10-
* Should improve the search for system-global git config.
1110
* Bump default `google-java-format` version to latest `1.24.0` -> `1.28.0`. ([#2345](https://github.com/diffplug/spotless/pull/2345))
1211

1312
## [2.46.1] - 2025-07-21

plugin-maven/README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,8 +144,10 @@ Spotless consists of a list of formats (in the example above, `misc` and `java`)
144144

145145
### Requirements
146146

147-
Spotless requires Maven to be running on JRE 11+. To use JRE 8, go back to [`2.30.0` or older](https://github.com/diffplug/spotless/blob/main/plugin-maven/CHANGES.md#2300---2023-01-13).
147+
Spotless requires Maven to be running on JRE 17+.
148148

149+
- If you're stuck on JRE 11, use [`2.46.1`](https://github.com/diffplug/spotless/blob/main/plugin-maven/CHANGES.md#2461---2025-07-21).
150+
- If you're stuck on JRE 8, go back to [`2.30.0` or older](https://github.com/diffplug/spotless/blob/main/plugin-maven/CHANGES.md#2300---2023-01-13).
149151

150152
### Git hook
151153

0 commit comments

Comments
 (0)