pockethub / PocketHub

PocketHub Android App
Apache License 2.0
9.39k stars 3.46k forks source link

Use a code style tool for Kotlin #1200

Closed veyndan closed 5 years ago

veyndan commented 6 years ago

This is kind of related to #1199.

As we are gradually migrating over to Kotlin, it'd be good to enforce a certain code styling. I've briefly looked around and ktlint seems like a good option as it enforces the official Kotlin styleguide and is popular among the Kotlin community.

As ktlint is bound to gradle check, it should integrate easily with Travis CI.

Meisolsson commented 6 years ago

Yeah, I've been looking at Klint and Detekt. But I think Detekt is only gonna be useful later when we are actually fully moved to Kotlin. Klint also tries to implement the Android Kotlin Style guide so it should be a nice fit.

So Klint is the way to go in my opinion.