gantsign / ktlint-maven-plugin

Maven plugin for ktlint the Kotlin linter
http://gantsign.com/ktlint-maven-plugin/
MIT License
60 stars 17 forks source link

Feature request: option to skip some rules #275

Closed energister closed 5 years ago

energister commented 5 years ago

It seems that ktlint-maven-plugin doesn't have an option to disable some rules (disabled_rules analogue of the ktlint)

freemanjp commented 5 years ago

@energister thanks for raising this feature request.

It's true that this Maven plugin doesn't have a configuration parameter for disabled_rules. However, It does support disabled_rules in .editorconfig files in the same way as the ktlint CLI.

Frankly, I think the .editorconfig files are a more appropriate place for this configuration than the Maven pom.xml. It also ensures other tools using ktlint use the same rules as Maven.

So unless you can provide a compelling use case for using a plugin configuration parameter instead of the .editorconfig file, I'm not inclined to implement this feature.