<commit_before>import sbt._
import Keys._
import com.typesafe.sbt._
import com.typesafe.sbt.osgi._


object Build extends Build {
  import Dependencies._

  // configure prompt to show current project
  override lazy val settings = super.settings :+ {
    shellPrompt := { s => Project.extract(s).currentProject.id + " > " }
  }

  val basicSettings = SbtPgp.settings ++ seq(
    version               := "1.1.6",
    scalaVersion          := "2.10.2",
    homepage              := Some(new URL("http://parboiled.org")),
    organization          := "org.parboiled",
    organizationHomepage  := Some(new URL("http://parboiled.org")),
    description           := "Elegant parsing in Java and Scala - lightweight, easy-to-use, powerful",
    startYear             := Some(2009),
    licenses              := Seq("Apache 2" -> new URL("http://www.apache.org/licenses/LICENSE-2.0.txt")),
    resolvers             ++= resolutionRepos,

    javacOptions          ++= Seq(
      "-deprecation",
      "-target", "1.5",
      "-source", "1.5",
      "-encoding", "utf8",
      "-Xlint:unchecked"
    ),
    scalacOptions         <<= scalaVersion map {
      case x if x startsWith "2.9" =>
        Seq("-unchecked", "-deprecation", "-encoding", "utf8")
      case x if x startsWith "2.10" =>
        Seq("-feature", "-language:implicitConversions", "-unchecked", "-deprecation", "-encoding", "utf8")
    },

    libraryDependencies   ++= test(testNG, scalatest),

    // scaladoc settings
    (scalacOptions in doc) <++= (name, version).map { (n, v) => Seq("-doc-title", n, "-doc-version", v) },

    // publishing
    crossScalaVersions := Seq("2.9.3", "2.10.2"),
    scalaBinaryVersion <<= scalaVersion(sV => if (CrossVersion.isStable(sV)) CrossVersion.binaryScalaVersion(sV) else sV),
    publishMavenStyle := true,
    publishArtifact in Test := false,
    pomIncludeRepository := { _ => false },
    SbtPgp.useGpg := true,
    publishTo <<= version { v: String =>
      val nexus = "https://oss.sonatype.org/"
      if (v.trim.endsWith("SNAPSHOT")) Some("snapshots" at nexus + "content/repositories/snapshots")
      else                             Some("releases" at nexus + "service/local/staging/deploy/maven2")
    },
    pomExtra :=
      <scm>
        <url><EMAIL>:sirthias/parboiled.git</url>
        <connection>scm:git:<EMAIL>:sirthias/parboiled.git</connection>
      </scm>
      <developers>
        <developer>
          <id>sirthias</id><commit_msg>Switch to sbt 0.13 syntax for setting scalacOptions<commit_after>import sbt._
import Keys._
import com.typesafe.sbt._
import com.typesafe.sbt.osgi._


object Build extends Build {
  import Dependencies._

  // configure prompt to show current project
  override lazy val settings = super.settings :+ {
    shellPrompt := { s => Project.extract(s).currentProject.id + " > " }
  }

  val basicSettings = SbtPgp.settings ++ seq(
    version               := "1.1.6",
    scalaVersion          := "2.10.2",
    homepage              := Some(new URL("http://parboiled.org")),
    organization          := "org.parboiled",
    organizationHomepage  := Some(new URL("http://parboiled.org")),
    description           := "Elegant parsing in Java and Scala - lightweight, easy-to-use, powerful",
    startYear             := Some(2009),
    licenses              := Seq("Apache 2" -> new URL("http://www.apache.org/licenses/LICENSE-2.0.txt")),
    resolvers             ++= resolutionRepos,

    javacOptions          ++= Seq(
      "-deprecation",
      "-target", "1.5",
      "-source", "1.5",
      "-encoding", "utf8",
      "-Xlint:unchecked"
    ),
    scalacOptions ++= {
      if (scalaVersion.value startsWith "2.9")
        Seq("-unchecked", "-deprecation", "-encoding", "utf8")
      else if (scalaVersion.value startsWith "2.10")
        Seq("-feature", "-language:implicitConversions", "-unchecked", "-deprecation", "-encoding", "utf8")
      else Seq.empty
    },

    libraryDependencies   ++= test(testNG, scalatest),

    // scaladoc settings
    (scalacOptions in doc) <++= (name, version).map { (n, v) => Seq("-doc-title", n, "-doc-version", v) },

    // publishing
    crossScalaVersions := Seq("2.9.3", "2.10.2"),
    scalaBinaryVersion <<= scalaVersion(sV => if (CrossVersion.isStable(sV)) CrossVersion.binaryScalaVersion(sV) else sV),
    publishMavenStyle := true,
    publishArtifact in Test := false,
    pomIncludeRepository := { _ => false },
    SbtPgp.useGpg := true,
    publishTo <<= version { v: String =>
      val nexus = "https://oss.sonatype.org/"
      if (v.trim.endsWith("SNAPSHOT")) Some("snapshots" at nexus + "content/repositories/snapshots")
      else                             Some("releases" at nexus + "service/local/staging/deploy/maven2")
    },
    pomExtra :=
      <scm>
        <url><EMAIL>:sirthias/parboiled.git</url>
        <connection>scm:git:<EMAIL>:sirthias/parboiled.git</connection>
      </scm>
      <developers>
        <developer>
          <id>sirthias</id>
{'fraction_non_alphanumeric': 0.1600802407221665, 'fraction_numerical': 0.01424272818455366, 'mean_word_length': 2.503865073787772, 'pattern_counts': {'":': 0, '<': 39, '<?xml version=': 0, '>': 43, 'https://': 2, 'lorem ipsum': 0, 'www.': 2, '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': '7087756', 'n_tokens_mistral': 1655, 'n_tokens_neox': 1590, 'n_words': 325}