Writting maven plugin using Kotlin.

If you are a Java developer you must be familiar with maven - a widely used Java build system. Maven has simple and reliable execution lifecycle: it runs several consecutive phases (like compile, test, package or deploy), and during each phase a set of plugins can be run, for example javac via maven-compiler-plugin during phase ‘compile’.

For a particular plugin one declares a <plugin> section in pom.xml, and each plugin can have several executions. Each execution is bound to a particular phase of build lifecycle, and it may include several goals. Goal is a particular action the plugin can execute, for example compile source code or run tests or check code style.

We are developing diktat - an automatic kotlin code style checker and formatter, which is intended to be used as CI/CD tool that constantly checks quality of code that developers are adding to their projects. To provide a convenient way to run it for all developers we support run from CLI and are preparing to release a dedicated maven plugin to run diktat directly from maven.

Gradle plugin: tips and tricks.

This article is describing our experience and problems that we have faced when we were creating Gradle plugin for our diktat project.

Kotlin Linters: which should I choose?

This article will make a brief comparison of existing opensource linters and static analyzers for Kotlin and introduce a new Kotlin linter (checker&fixer) called diKTat.