Hey guys having a problem with ktlint in my androi...
# ktlint
p
Hey guys having a problem with ktlint in my android project, I posted it on SO, any help is appreciated 👐 https://stackoverflow.com/questions/59304531/ktlint-error-in-android-build-with-multiple-flavors
t
have you checked the generated reports?
most probably you will see errors in code style there
p
Yeah I have errors in the code style, but it is supposed to throw that error? It is kinda of confusing... also it was throwing the error when running ktlintFormat so that didnt make sense for me. I probably have to add custom rules or exclusions, for things ktlint cant auto correct ( for example, not allowing wildcard imports, or , imports must be order lexicographically)
or is there a way to make ktlint able to auto correct that stuff?
t
Yes, the exception is expected. ktlint format could correct some style violations, but not all
plugin itself invokes
ktlint
as
JavaExec
task
p
hm ok makes sense! yeah i checked the source code to check the runLint method
just saying a human readable error would be less frustrating 😅
t
please open an issue in
ktlint-gradle
project 🙂
p
👍 is it ktlint or plugin specific?
t
It is plugin specific
p
ok, thanks Yahor 👍
done @tapchicoma, thanks for your contributions to the project, i created an issue here https://github.com/JLLeitschuh/ktlint-gradle/issues/313. Any suggestions to improve the issue description or to help are welcome
👍 1