diffplug / diffplug/spotless

Support `java { toolchain { languageVersion`

Aperta
#724 8 commenti 26 reazioni 0 assegnatari Vedi su GitHub
enhancement
Lingua principale
Java
Stelle
5.6k
Fork
559
Merge medio
1g 14h
PR unite (30g)
43

Descrizione

Currently, the spotless invocation is inlined into the task execution itself.

https://github.com/diffplug/spotless/blob/main/plugin-gradle/src/main/java/com/diffplug/gradle/spotless/SpotlessTaskImpl.java#L50

Is it possible to instead run a separate main file in `JavaExec`? Gradle has introduced toolchain feature to allow build to control the Java version used for compile and execution which works very well to allow any user's Java version to run the build with a specific one. But unfortunately, this currently doesn't affect Spotless which runs in Gradle itself - for example, this means that a build must become unbuildable on Java 8 to upgrade to the latest googleJavaFormat since it requires higher Java version. It would be nice if this could be avoided.

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Start with plugin-gradle/src/main/java/com/diffplug/gradle/spotless/SpotlessTaskImpl.java at line 50, where Spotless invocation is inlined into task execution. Investigate how Gradle JavaExec and toolchains can run a separate main file. Done means Spotless uses the configured Java toolchain for execution without making the build depend on the JVM running Gradle.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
java
Ambito
build-system
Tipo di issue
Funzionalità
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.