Kotlin code auto format


Is there a way to automatically format kotlin code (e.g. fix indentation)?


IntelliJ IDEA has action for it: Code -> Reformat Code... (Ctrl+Alt+L / Cmd+Alt+L) It works not only for Kotlin, but also for any language supported by the IDE.




But IntelliJ doesn’t work on termux on Android.
I’ve installed openjdk 9 in it.