Skip to content

Commit 254f17d

Browse files
author
Vincent Potucek
committed
drop checkstyle
1 parent 352110b commit 254f17d

File tree

72 files changed

+230
-860
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+230
-860
lines changed

.github/actions/main-build/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ inputs:
44
arguments:
55
required: true
66
description: Gradle arguments
7-
default: :platform-tooling-support-tests:test build --no-configuration-cache # Disable configuration cache due to https://github.com/diffplug/spotless/issues/2318
7+
default: :platform-tooling-support-tests:test build
88
encryptionKey:
99
required: true
1010
description: Gradle cache encryption key

.github/workflows/cross-version.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,7 @@ jobs:
6060
-Ptesting.enableJaCoCo=false \
6161
-PjavaToolchain.version=${{ matrix.jdk.version }} \
6262
-Dscan.tag.JDK_${{ matrix.jdk.version }} \
63-
build \
64-
--no-configuration-cache #Disable configuration cache due to https://github.com/diffplug/spotless/issues/2318
63+
build
6564
- uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
6665
if: ${{ always() }}
6766
with:
@@ -102,8 +101,7 @@ jobs:
102101
-PjavaToolchain.implementation=j9 \
103102
-Dscan.tag.JDK_${{ matrix.jdk }} \
104103
-Dscan.tag.OpenJ9 \
105-
build \
106-
--no-configuration-cache # Disable configuration cache due to https://github.com/diffplug/spotless/issues/2318
104+
build
107105
- uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
108106
if: ${{ always() }}
109107
with:

.github/workflows/main.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,7 @@ jobs:
3737
arguments: |
3838
:platform-tooling-support-tests:test \
3939
build \
40-
jacocoRootReport \
41-
--no-configuration-cache # Disable configuration cache due to https://github.com/diffplug/spotless/issues/2318
40+
jacocoRootReport
4241
- name: Upload to Codecov.io
4342
uses: codecov/codecov-action@18283e04ce6e62d37312384ff67231eb8fd56d24 # v5.4.3
4443
with:

.github/workflows/release.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,6 @@ jobs:
201201
encryptionKey: ${{ secrets.GRADLE_ENCRYPTION_KEY }}
202202
arguments: |
203203
--no-build-cache \
204-
--no-configuration-cache \
205204
clean \
206205
gitPublishCopy \
207206
-Pdocumentation.replaceCurrentDocs=${{ contains(inputs.releaseVersion, '-') && 'false' || 'true' }}
@@ -215,7 +214,6 @@ jobs:
215214
encryptionKey: ${{ secrets.GRADLE_ENCRYPTION_KEY }}
216215
arguments: |
217216
--no-build-cache \
218-
--no-configuration-cache \
219217
gitPublishPush \
220218
-Pdocumentation.replaceCurrentDocs=${{ contains(inputs.releaseVersion, '-') && 'false' || 'true' }}
221219
- name: Wait for deployment to GitHub Pages

.github/workflows/reproducible-build.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@ jobs:
2828
with:
2929
encryptionKey: ${{ secrets.GRADLE_ENCRYPTION_KEY }}
3030
arguments: |
31-
--quiet \
32-
--no-configuration-cache # Disable configuration cache due to https://github.com/diffplug/spotless/issues/2318
31+
--quiet
3332
- name: Build and compare checksums
3433
shell: bash
3534
run: ./.github/scripts/checkBuildReproducibility.sh

CONTRIBUTING.md

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -72,22 +72,18 @@ Whenever an acronym is included as part of a field name or parameter name:
7272
- Otherwise, keep the first letter of the acronym uppercase and use lowercase for the
7373
rest of the acronym -- for example, `String defaultUrl;`.
7474

75-
### Formatting
76-
77-
#### Code
78-
79-
Code formatting is enforced using the [Spotless](https://github.com/diffplug/spotless)
80-
Gradle plugin. You can use `gradle spotlessApply` to format new code and add missing
81-
license headers to source files. Formatter and import order settings for Eclipse are
82-
available in the repository under
83-
[junit-eclipse-formatter-settings.xml](gradle/config/eclipse/junit-eclipse-formatter-settings.xml)
84-
and [junit-eclipse.importorder](gradle/config/eclipse/junit-eclipse.importorder),
85-
respectively. For IntelliJ IDEA there's a
86-
[plugin](https://plugins.jetbrains.com/plugin/6546) you can use in conjunction with the
87-
Eclipse settings.
88-
89-
It is forbidden to use _wildcard imports_ (e.g., `import static org.junit.jupiter.api.Assertions.*;`)
90-
in Java code.
75+
### 🚀 Code Convention & Transformation
76+
*(Advanced Refactoring, Modernization, and Bulk Code Changes)*
77+
78+
#### 🔧 Automated rewriting of source code to
79+
- **Refactor** safely (e.g., rename methods, migrate APIs)
80+
- **Modernize** (e.g., Java 8 → Java 17 features)
81+
- **Fix anti-patterns** (e.g., replace `Vector` with `ArrayList`)
82+
- **Enforce conventions** (e.g., JUnit's naming rules)
83+
84+
The build system incorporates [Moderne](https://moderne.io/) rewrite capabilities for automated code transformations. These modifications are environment-driven enlisted in the [junitbuild.java-library-conventions.gradle.kts](gradle/plugins/common/src/main/kotlin/junitbuild.java-library-conventions.gradle.kts)
85+
86+
You can use `gradle rewriteRun` to apply these changes.
9187

9288
#### Documentation
9389

RELEASING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
- [ ] Change release date in Release Notes
88
- [ ] Change release date in `README.MD`
99
- [ ] Commit with message "Release ${VERSION}"
10-
- [ ] Execute `./gradlew --no-build-cache --no-configuration-cache clean build jreleaserDeploy`
10+
- [ ] Execute `./gradlew --no-build-cache clean build jreleaserDeploy`
1111
- [ ] Tag current commit: `git tag -s -m ${VERSION} r${VERSION}`
1212
- [ ] Change `version` in `gradle.properties` on release branch to new development versions and commit with message "Back to snapshots for further development" or similar
1313
- [ ] Push release branch and tag to GitHub: `git push --set-upstream --follow-tags origin HEAD`

build.gradle.kts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import junitbuild.extensions.dependencyProject
33
plugins {
44
id("junitbuild.base-conventions")
55
id("junitbuild.build-metadata")
6-
id("junitbuild.checkstyle-nohttp")
76
id("junitbuild.jacoco-aggregation-conventions")
87
id("junitbuild.maven-central-publishing")
98
id("junitbuild.temp-maven-repo")
@@ -15,7 +14,7 @@ group = "org.junit"
1514
val license by extra(License(
1615
name = "Eclipse Public License v2.0",
1716
url = uri("https://www.eclipse.org/legal/epl-v20.html"),
18-
headerFile = layout.projectDirectory.file("gradle/config/spotless/eclipse-public-license-2.0.java")
17+
headerFile = layout.projectDirectory.file("gradle/config/license/eclipse-public-license-2.0.java")
1918
))
2019

2120
val platformProjects by extra(listOf(

documentation/documentation.gradle.kts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -210,10 +210,6 @@ tasks {
210210
options.release.set(21)
211211
}
212212

213-
named<Checkstyle>("checkstyleTools") {
214-
config = resources.text.fromFile(checkstyle.configDirectory.file("checkstyleMain.xml"))
215-
}
216-
217213
val generateConsoleLauncherOptions by registering(CaptureJavaExecOutput::class) {
218214
classpath.from(standaloneConsoleLauncherClasspath)
219215
mainClass = "org.junit.platform.console.ConsoleLauncher"

documentation/src/test/java/example/ClassTemplateDemo.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,9 @@ void wellKnown() {
5252
}
5353

5454
// end::user_guide[]
55-
static
55+
public
5656
// tag::user_guide[]
57-
public class MyClassTemplateInvocationContextProvider
57+
static class MyClassTemplateInvocationContextProvider
5858
// tag::custom_line_break[]
5959
implements ClassTemplateInvocationContextProvider {
6060

0 commit comments

Comments
 (0)