Skip to content

Releases: ZacSweers/redacted-compiler-plugin

1.12.0

21 Dec 03:34
Compare
Choose a tag to compare
  • Fix FIR diagnostics rendering in the IDE. Note this only works in the K2 Kotlin IDE plugin + setting the IntelliJ kotlin.k2.only.bundled.compiler.plugins.enabled registry key to false.
  • When custom annotations are defined, report those names in FIR error messages.
  • Support multiple custom annotations.
    • For Gradle configuration, the singular *Annotation properties are deprecated in favor of plural*Annotations SetProperty types.
    • For CLI consumers, the redactedAnnotation and unredactedAnnotation properties are now redactedAnnotations and unredactedAnnotations.
  • Build against Gradle 8.12.
  • Only report errors in FIR now. Removes the validateIr plugin option.
  • No longer support K1.
  • Raise Gradle plugin Kotlin target to 1.9.

This release goes all in on FIR for in-IDE error reporting!

image

What's Changed

Full Changelog: 1.11.0...1.12.0

1.11.0

29 Nov 04:22
Compare
Choose a tag to compare
  • Update to Kotlin 2.1.0. This plugin now requires 2.1.0 or later.
  • Build against Gradle 8.11.1.

What's Changed

Full Changelog: 1.10.0...1.11.0

1.10.0

23 Aug 02:49
Compare
Choose a tag to compare
  • Update to Kotlin 2.0.20.
  • Build against Gradle 8.10.

What's Changed

Full Changelog: 1.9.0...1.10.0

1.9.0

22 May 20:01
Compare
Choose a tag to compare
  • Update to Kotlin 2.0.0 (aka K2). This plugin now assumes 2.0, but can be used with Kotlin 1.9.x as well.
  • Fully implement validation checks in FIR, allowing the plugin to report errors earlier and also (eventually) have errors appear automatically in the IDE.
    • The IR plugin no longer validates by default.
    • At the time of writing, I'm not able to get errors to appear in the IDE even if non-bundled plugins are force-enabled. Follow KTIJ-29248 for more info.
  • The enabled compiler option is no longer required and just defaults to true.
  • Omit the stdlib from transitive dependencies on the compiler plugin and Gradle plugin artifacts. Both kotlinc and Gradle impose their own versions on the classpath.

What's Changed

Full Changelog: 1.8.1...1.9.0

1.8.1

26 Apr 19:42
Compare
Choose a tag to compare
  • Allow @Unredacted to be applied to a class, only when a supertype is @Redacted
  • Allow @Redacted supertypes to be inherited by objects, only when the child does not implement a custom toString method
  • Fail compilation when @Unredacted and @Redacted are applied to the same class

Special thanks to @DrewCarlson for contributing to this release!

What's Changed

Full Changelog: 1.8.0...1.8.1

1.8.0

23 Apr 19:04
Compare
Choose a tag to compare
  • New: Support for annotating interfaces and non-final classes as @Redacted. In this event, all data/value subclasses will be treated as @Redacted.
  • New: Support for @Unredacted to explicitly opt out of redacting specific properties in otherwise-redacted classes.
    @Redacted
    data class User(
      @Unredacted val name: String,
      val phoneNumber: String
    )
    
    // This will redact `phoneNumber` but not `name`
    // User(name=Bob, phoneNumber=██)
  • Update Kotlin to 1.9.23.

Special thanks to @DrewCarlson for contributing to this release!

What's Changed

Full Changelog: 1.7.1...1.8.0

1.7.1

26 Nov 19:01
Compare
Choose a tag to compare
  • Update Kotlin to 1.9.21.

1.7.0

31 Oct 20:29
Compare
Choose a tag to compare
  • Update to Kotlin 1.9.20. This plugin now requires 1.9.20.
  • Update wasm target to wasmJs.

What's Changed

Full Changelog: 1.6.1...1.7.0

1.6.1

03 Sep 03:18
Compare
Choose a tag to compare
  • Enhancement: Simplify lookup of KotlinCompilation's implementation configuration name in the Gradle plugin when using the default annotation.
  • Update to Kotlin 1.9.10.
  • Build against Gradle 8.3.

What's Changed

Full Changelog: 1.6.0...1.6.1

1.6.0

08 Jul 21:32
Compare
Choose a tag to compare
  • New: Support value class types. Note that only annotating the class is supported, as annotating the property would be redundant.

What's Changed

Full Changelog: 1.5.0...1.6.0