Formatting Android code with Ktlint and Git Hooks

Barros
2 min readApr 30, 2022
Photo by Oskar Yildiz on Unsplash

How many times did it bother you to see unformatted code during a code review? Or how many times did you ask your colleagues to respect the same guideline when they are coding to make the review easier?

It is a solution for this problem, with ktlint and git hooks we can check if code is correctly formatted and avoid discrepancies between authors.

--

--