All notable changes to this project will be documented in this file.
This project adheres to Semantic Versioning.
org.eclipse.aether:aether-*:1.1.0
and org.eclipse.aether:aether-*:1.0.0.v20140518
(#100).--android
(-a
) CLI option (turns on Android Kotlin Style Guide compatibility)ktlint --apply-to-idea
).ktlint --apply-to-idea
to account for indent_size
& continuation_indent_size
in .editorconfig
(if any).ktlint-intellij-idea-integration
binary (deprecated in 0.9.0).component1
..component5
).--reporter
's output
handling (previously parent directory was expected to exist) (#97).no-blank-line-before-rbrace
rule (#65).}
and ::
(curly-spacing).This release contains changes that were meant for 0.11.0 and so it was retagged as such.
}
and [key]
/(...)
(curly-spacing) (#91).ktlint --install-git-pre-commit-hook
to install).--reporter=<name>,output=<path/to/file>
) (#71).indent_size=unset
(.editorconfig
) (#70).( {
formatting( {
and ({
were accepted as correct, while only ({
should be) (curly-spacing
rule) (#80).if\nfn {}\nelse
formatting (curly-spacing
rule).max_line_length=off
& max_line_length=unset
handling (.editorconfig
).kotlin-compiler
version to 1.1.51 (from 1.1.3-2).ktlint --apply-to-idea
to include OPTIMIZE_IMPORTS_ON_THE_FLY=true
.: Unit =
formatting (: Unit
is no longer dropped when =
is used) (#77).${super.toString()}
linting (string-template
rule) (#69).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.
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
).kotlin-compiler
to 1.1.3-2 (from 1.1.0)).--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
binaryktlint
(as ktlint --apply-to-idea
)).setValue
) (#55).get
/set
ter spacing (#56).getValue
) (#54).ktlint --stdin
(#51).indent_size
is honored and only if it's set in [*{kt,kts}]
section).else/catch/finally
on the same line as }
check (now part of “keyword-spacing” rule).ktlint-intellij-idea-integration
binary for easy Intellij IDEA config injection.kotlin-compiler
version to 1.1.0 (from 1.1-M04).super<T>
(#34).}
and !!
(curly-spacing).indent
rule to allow “Method declaration parameters -> Align when multiline” (as this option is (unfortunately) “on” by default in Intellij IDEA) (#26).kotlin-compiler
version to 1.1-M04 (from 1.0.6).*.kts
(script) support.kotlin-compiler
version to 1.0.6 (from 1.0.3).no-wildcard-imports
rule (kotlinx.android.synthetic excluded from check) (#16).curly-spacing
false negative in case of }?.
.ktlint -F
output (it now includes lint errors that cannot be fixed automatically).ktlint -F --debug
error count.