Skip to content

Say the Gradle plugin carries the formatter and needs no root repository - #13

Merged
abashev merged 1 commit into
mainfrom
gradle-plugin-bundled-formatter
Nov 8, 2026
Merged

abashev merged 1 commit into
mainfrom
gradle-plugin-bundled-formatter

Conversation

@abashev

@abashev abashev commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

The Gradle plugin now carries the formatter's jars inside it (openjavaformat/open-java-format#20): a build declares nothing for the formatter and needs no repository for it. The native binary is resolved by each project that formats, through its own repositories, so the root project of a multi-project build needs none, and parallel builds work.

  • Gradle page: the formatter comes inside the plugin; the native binary comes from Maven Central, or a mirror of it, through the project's repositories and runs from ~/.gradle/open-java-format-caches; the multi-project example declares its repositories in the subprojects; new sections Build cache and Another formatter version.
  • Spotless page: the native property no longer depends on the Java version, a build without the --add-exports flags now fails spotlessJava, and the --rerun-tasks advice stays for versions up to 21.0.1.

zensical build --clean --strict reports no issues.

To merge with the release that has these changes: until then the pages would promise what the published plugin does not do.

The Gradle plugin now carries the formatter's jars inside it
(openjavaformat/open-java-format#20): a build declares nothing for the
formatter and needs no repository for it. The native binary is
resolved by each project that formats, through its own repositories,
so the root project of a multi-project build needs none, and parallel
builds work. The multi-project example declares its repositories in
the subprojects to show that.

The Gradle page gains a Build cache section, spotlessJava's key changes
with the formatter and holds across directories and machines, and a
section on declaring another formatter version in palantirJavaFormat.
The Spotless page no longer ties the native property to Java 21, says
that a build without the --add-exports flags now fails spotlessJava,
and keeps the --rerun-tasks advice for versions up to 21.0.1.

To merge with the release that has these changes: until then the pages
would promise what the published plugin does not do.
@abashev
abashev merged commit 8a18b7d into main Nov 8, 2026
2 checks passed
@abashev
abashev deleted the gradle-plugin-bundled-formatter branch November 8, 2026 18:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant