ktlint v0.9.0 Release Notes

Release Date: 2017-07-23 // almost 7 years ago
  • โž• Added

    • ๐Ÿ‘• [Reporter](ktlint-core/src/main/kotlin/com/github/shyiko/ktlint/core/Reporter.kt) API.
      ktlint comes with 3 built-in reporters: plain (default; ?group_by_file can be appended to enable grouping by file (shown below)), json and checkstyle. $ ktlint --reporter=plain?group_by_file path/to/file.kt 1:10 Unused import. 2:10 Unnecessary "Unit" return type. path/to/another-file.kt 1:10 Unnecessary semicolon.
    • ๐Ÿ‘• string-template,
      ๐Ÿ‘• no-empty-class-body,
      ๐Ÿ‘• max-line-length (#47),
      final-newline (activated only if insert_final_newline is set in .editorconfig (under [*.{kt,kts}])) rules.
    • --limit CLI option (e.g. use --limit=10 to limit the number of errors to display).
    • ๐Ÿ‘• --relative CLI flag which makes ktlint output file paths relative to working directory (e.g. dir/file.kt instead of /home/269/project/dir/file.kt).

    ๐Ÿ”„ Changed

    • ๐Ÿ’ฅ BREAKING: JDK version to 1.8 (as a result of upgrading kotlin-compiler to 1.1.3-2 (from 1.1.0)).
    • File matching (offloaded to klob).

    ๐Ÿ—„ Deprecated

    • โšก๏ธ --ruleset-repository and --ruleset-update CLI arguments in favour of --repository and --repository-update ๐Ÿšš respectively (--ruleset-* will be removed in 1.0.0).
    • ๐Ÿ‘• ktlint-intellij-idea-integration binary
      ๐Ÿ‘• (Intellij IDEA integration task is now included in ktlint (as ktlint --apply-to-idea)).