Skip to content

Releases: google/google-java-format

v1.24.0

04 Oct 17:23
Compare
Choose a tag to compare

This is the last planned release of google-java-format that will support running on JDK 11, see #1159. Using google-java-format to format code that targets earlier versions of the language is still supported, but running the formatter itself on JDK 17 or newer will be required.

Changes:

  • Fix inconsistency in formatting of comments in switch statements (#1127)
  • Improve handling of {@snippet ...} (ebf9b52)
  • Improve handling of /// comments (#1153)
  • Improve error messages for syntax errors (8c652ed)

Full Changelog: v1.23.0...v1.24.0

v1.23.0

30 Jul 20:53
Compare
Choose a tag to compare

Changes:

  • Adjust indentation of line comments inside expression switches (#876)
  • Fix modifier order handling for non-sealed (7fd9300)
  • Handle empty classes with no members that contain semi-colons (b9b6730)
  • Support overlapping ranges in --lines (c4b467d)
  • Remove support for the String Templates preview feature, see https://bugs.openjdk.org/browse/JDK-8329949 (fdf4b29)
  • Improve compatibility with latest JDK early access builds (0b384e3)

Full Changelog: v1.22.0...v1.23.0

v1.22.0

01 Apr 20:59
Compare
Choose a tag to compare

Changes:

  • Improve support for tokens that span multiple lines (9bdae02)
  • Fix an issue with text block formatting, when the text block is the receiver of a method call (#1081)
  • google-java-format-diff.py now parallelizes the calls to the formatter, for better performance (3ee6e2a)

Full Changelog: v1.21.0...v1.22.0

v1.21.0

05 Mar 23:37
Compare
Choose a tag to compare

Formatting changes:

  • Adjust indentation of text blocks (ce3cb59)

Bug fixes:

  • Fix a crash with comments inside string templates (e946e82)
  • Native image -version reports HEAD-SNAPSHOT instead of the correct version (#1068)
  • Improve compatibility with older glibc versions (#1072)

Full Changelog: v1.20.0...v1.21.0

v1.20.0

17 Feb 03:54
Compare
Choose a tag to compare

This release includes GraalVM native-image binaries for google-java-format for windows, linux, and mac. These binaries offer improved startup performance.

Changes:

  • Keep type-use annotation with type when wrapping (03efe44)
  • Handle 'any' patterns (#1037)

Full Changelog: v1.19.2...v1.20.0

v1.19.2

05 Jan 19:50
Compare
Choose a tag to compare

Changes

  • Improve support for string templates (#1010)
  • Handle var in record patterns (#1020)

Full Changelog: v1.19.1...v1.19.2

v1.19.1

19 Dec 17:35
Compare
Choose a tag to compare

Changes

  • Fix support for Java 21 features by enabling JDK 21 for release builds (#1014).

Full Changelog: v1.19.0...v1.19.1

v1.19.0

18 Dec 21:09
Compare
Choose a tag to compare

Changes

This release adds initial support for more Java 21 features, including:

  • String templates (#981)
  • Unnamed variables (#978)
  • Pattern matching and guard clauses in switch expressions (#937, #880, #983, #988)

Other changes:

  • Handle type annotations on method reference qualifiers (53390d9)
  • Avoid reflowing text blocks (#976)

Full Changelog: v1.18.1...v1.19.0

v1.18.1

05 Oct 14:58
Compare
Choose a tag to compare

Changes

  • Fixed version number for Eclipse plugin (#744)

Full Changelog: v1.18.0...v1.18.1

v1.18.0

02 Oct 21:04
Compare
Choose a tag to compare

Changes

Full Changelog: v1.17.0...v1.18.0