# Shared editor + ktlint config. The repo stores LF (.gitattributes `* text=auto eol=lf`).
root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
indent_style = space
indent_size = 4

[*.{kt,kts}]
ktlint_code_style = android_studio
# Line length is intentionally NOT gated: several deliberate long lines (the achievement/data-table
# rows in data/achievements/Achievements.kt, descriptive copy) would otherwise force ugly reflows.
# detekt's MaxLineLength is likewise disabled (see config/detekt/detekt.yml).
ktlint_standard_max-line-length = disabled
# @Composable functions are PascalCase by Compose convention — exempt them from function-naming.
ktlint_function_naming_ignore_when_annotated_with = Composable
# Keep the codebase's deliberate trailing commas (cleaner diffs) — ktlint adds/preserves them.
ij_kotlin_allow_trailing_comma = true
ij_kotlin_allow_trailing_comma_on_call_site = true

[*.{yml,yaml,xml,json}]
indent_size = 2

[*.bat]
end_of_line = crlf
