File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -43,6 +43,22 @@ subprojects {
4343 androidVariant " release"
4444 }
4545 apply plugin : ' org.jlleitschuh.gradle.ktlint'
46+
47+ // Kits include their own `.editorconfig` files (some with `root = true`) which can
48+ // prevent the repository `.editorconfig` from being applied. To keep lint behavior
49+ // consistent without modifying kit repos, we override the relevant ktlint rules here.
50+ if (project. projectDir. toString(). startsWith(" ${ rootProject.projectDir} /kits/" )) {
51+ project. plugins. withId(" org.jlleitschuh.gradle.ktlint" ) {
52+ project. ktlint {
53+ additionalEditorconfig = [
54+ " ktlint_standard_indent" : " disabled" ,
55+ " ktlint_standard_trailing-comma-on-call-site" : " disabled" ,
56+ " ktlint_standard_trailing-comma-on-declaration-site" : " disabled" ,
57+ " ktlint_standard_no-consecutive-blank-lines" : " disabled" ,
58+ ]
59+ }
60+ }
61+ }
4662}
4763
4864allprojects {
You can’t perform that action at this time.
0 commit comments