Search Gradle plugins

Add this plugin to your build using the plugins DSL:

plugins {
  id("org.jlleitschuh.gradle.ktlint") version "2.2.1"
}

See also:

  • The legacy method of plugin application.
    buildscript {
      repositories {
        gradlePluginPortal()
      }
      dependencies {
        classpath("gradle.plugin.org.jlleitschuh.gradle:ktlint-gradle:2.2.1")
      }
    }
    
    apply(plugin = "org.jlleitschuh.gradle.ktlint")
  • Applying plugins to all subprojects .