github ktlint/ktlint 2.0.0-ALPHA-4

pre-release7 hours ago

IMPORTANT: This project is no longer maintained by Pinterest. As a result the Maven coordinates of the project have changed from com.pinterest.ktlint to io.github.ktlint. Read more in the documentation.

Note: Earlier alpha versions are not available as GitHub, nor as Maven Central download due to problems in fixing the release pipeline.

🆕 Features

  • Execute all rules on same AST Node before proceeding to next AST Node (possibly breaking change) - #3252, by @paul-dingemans
    Due to changing the order in which rules are executed, this is a potentially breaking change when rules are not well written. Normal rules only manipulate the AST for nodes that have not yet been visited. In case a rule for a given AST Node decides to manipulate an AST Node that already has been visited before, this might result in a failure.

  • Add RuleV2 to enforce autocorrect approve visitor - #3241, by @paul-dingemans

  • Add rule call-expression-wrapping, and improve wrapping in chain-method-continuation and function-literal - #3253, by @paul-dingemans

  • Add blank line check between package and import statements - #3266, by @maheen8q

  • Add experimental rule lambda-return - #3274, by @paul-dingemans

  • Update kotlin to v2.4.0 / set java compilation to 26 - #3316, by @paul-dingemans

  • Enable rule blank-line-before-declaration by default for android_studio - #3318, by @paul-dingemans

  • Add experimental rules for blank lines between sections - #3319, by @paul-dingemans

  • feat: add GraalVM native-image binaries to release (linux, macOS, Windows) - #3284, by @zeitlinger

  • Add experimental rule no-blank-line-at-start-of-file - #3361, by @paul-dingemans

🔧 Fixes

📦 Dependencies

  • chore(deps): update ffurrer2/extract-release-notes action to v3 - #3196, by @renovate[bot]

  • fix(deps): update dependency org.ec4j.core:ec4j-core to v1.2.0 - #3197, by @renovate[bot]

  • fix(deps): update dependency com.github.ajalt.clikt:clikt to v5.1.0 - #3224, by @renovate[bot]

  • fix(deps): update dependency org.assertj:assertj-core to v3.27.7 - #3229, by @renovate[bot]

  • fix(deps): update dependency io.github.hakky54:logcaptor to v2.12.6 - #3273, by @renovate[bot]

  • chore(deps): update gradle/actions action to v6 - #3275, by @renovate[bot]

  • fix(deps): update dependency org.jetbrains.dokka:dokka-gradle-plugin to v2.2.0 - autoclosed - #3277, by @renovate[bot]

  • Update dependency io.github.detekt.sarif4k:sarif4k to v0.7.0 - #3285, by @renovate[bot]

  • Configure Renovate - #3304, by @renovate[bot]

  • Update softprops/action-gh-release action to v3 - #3283, by @renovate[bot]

  • Update dependency io.github.oshai:kotlin-logging-jvm to v8.0.4 - #3292, by @renovate[bot]

  • Update dependency org.slf4j:slf4j-simple to v2.0.18 - #3294, by @renovate[bot]

  • Update logback monorepo to v1.5.34 - #3310, by @renovate[bot]

  • Update dependency dev.drewhamilton.poko:poko-gradle-plugin to v0.23.1 - #3320, by @renovate[bot]

  • Update dependency com.vanniktech:gradle-maven-publish-plugin to v0.37.0 - #3327, by @renovate[bot]

  • Update plugin com.gradle.develocity to v4.5.0 - #3332, by @renovate[bot]

  • Update mislav/bump-homebrew-formula-action action to v4.2 - #3339, by @renovate[bot]

  • Update kotlin monorepo to v2.4.10 - #3340, by @renovate[bot]

  • Update plugin shadow to v9.6.1 - #3341, by @renovate[bot]

  • Update actions/setup-python action to v7 - #3342, by @renovate[bot]

  • Update actions/checkout action to v7 - #3347, by @renovate[bot]

  • Update Gradle to v9.7.0 - #3352, by @renovate[bot]

  • Update junit-framework monorepo to v6.1.3 - #3354, by @renovate[bot]

  • Update dependency ch.qos.logback:logback-classic to v1.6.3 - #3360, by @renovate[bot]

  • Override outdated log4j dependencies provided via logcaptor 2.12.6 - #3366, by @paul-dingemans

💬 Other

Don't miss a new ktlint release

NewReleases is sending notifications on new releases.