title: Kotlin Gradle Spotless ktlint configuration
body: <p>I currently use the following way to apply ktlint to my projects:</p>
  <pre><code>plugins{
      id(&quot;com.diffplug.spotless&quot;) version &quot;6.7.2&quot;
  }
  
  allprojects {
      apply(plugin = &quot;com.diffplug.gradle.spotless&quot;)
  
      spotless {
          kotlin {
              target(&quot;**/*.kt&quot;)
              ktlint(&quot;0.45.2&quot;)
          }
          kotlinGradle {
              target(&quot;*.gradle.kts&quot;, &quot;additionalScripts/*.gradle.kts&quot;)
              ktlint(&quot;0.45.2&quot;)
          }
      }
  }
  </code></pre>
  <p>I want to tweak some on the configurations so that the linter fits with what we want in the team. for example, set a max line length to 120.</p>
  <p>For this, I found that we can do something like:
  <code>ktlint(&quot;0.30.0&quot;).userData(mapOf(&quot;max_line_length&quot; to &quot;120&quot;))</code>
  in the build.gradle.kts file. However, as we go on adding more tweaks, this becomes very difficult to manage and copy from project to project, and the <code>spotlessApply</code> task fails to format the code and simply raises it as an issue during the build.Is it possible to get it to auto-format in this case?</p>
  <p>ktlint itself supports the <code>.editorconfig</code> file for such configurations. How do I apply that with spotless?</p>