<commit_before>package org.scalafmt.sbt

import org.scalafmt.config.{Config, ScalafmtConfig}
import org.scalafmt.{Formatted, Scalafmt}
import sbt.Keys._
import sbt.{Def, _}
import complete.DefaultParsers._
import metaconfig.Configured
import sbt.util.Logger

import scala.meta.internal.tokenizers.PlatformTokenizerCache
import scala.util.{Failure, Success, Try}
import org.scalafmt.util.{FormattingCache, StyleCache}

object ScalafmtPlugin extends AutoPlugin {
  override def trigger: PluginTrigger = allRequirements

  object autoImport {
    val scalafmt = taskKey[Unit]("Format Scala sources with scalafmt.")
    val scalafmtCheck =
      taskKey[Boolean](
        "Fails if a Scala source is mis-formatted. Does not write to files.")
    val scalafmtOnCompile =
      settingKey[Boolean](
        "Format Scala source files on compile, off by default. " +
          "BEWARE. This task is not incremental, every file in the " +
          "project is re-formatted on every compile. " +
          "See https://github.com/scalameta/scalafmt/issues/1091")
    val scalafmtConfig = taskKey[Option[File]](
      "Optional location of .scalafmt.conf file. " +
        "If None the default config is used.")
    val scalafmtSbt = taskKey[Unit](
      "Format *.sbt and project/*.scala files for this sbt build.")
    val scalafmtSbtCheck =
      taskKey[Boolean](
        "Fails if a *.sbt or project/*.scala source is mis-formatted. " +
          "Does not write to files.")
    val scalafmtOnly = inputKey[Unit]("Format a single given file.")
  }
  import autoImport._

  private val scalafmtDoFormatOnCompile =<commit_msg>Remove obsolete warning<commit_after>package org.scalafmt.sbt

import org.scalafmt.config.{Config, ScalafmtConfig}
import org.scalafmt.{Formatted, Scalafmt}
import sbt.Keys._
import sbt.{Def, _}
import complete.DefaultParsers._
import metaconfig.Configured
import sbt.util.Logger

import scala.meta.internal.tokenizers.PlatformTokenizerCache
import scala.util.{Failure, Success, Try}
import org.scalafmt.util.{FormattingCache, StyleCache}

object ScalafmtPlugin extends AutoPlugin {
  override def trigger: PluginTrigger = allRequirements

  object autoImport {
    val scalafmt = taskKey[Unit]("Format Scala sources with scalafmt.")
    val scalafmtCheck =
      taskKey[Boolean](
        "Fails if a Scala source is mis-formatted. Does not write to files.")
    val scalafmtOnCompile =
      settingKey[Boolean](
        "Format Scala source files on compile, off by default.")
    val scalafmtConfig = taskKey[Option[File]](
      "Optional location of .scalafmt.conf file. " +
        "If None the default config is used.")
    val scalafmtSbt = taskKey[Unit](
      "Format *.sbt and project/*.scala files for this sbt build.")
    val scalafmtSbtCheck =
      taskKey[Boolean](
        "Fails if a *.sbt or project/*.scala source is mis-formatted. " +
          "Does not write to files.")
    val scalafmtOnly = inputKey[Unit]("Format a single given file.")
  }
  import autoImport._

  private val scalafmtDoFormatOnCompile =
{'fraction_non_alphanumeric': 0.09335080248935473, 'fraction_numerical': 0.0013101867016049786, 'mean_word_length': 3.5244444444444443, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3872180', 'n_tokens_mistral': 939, 'n_tokens_neox': 916, 'n_words': 276}