Add sbt-whitesource plugin (#23122)
This commit is contained in:
parent
c9131412fd
commit
cd6b6ffe67
2 changed files with 25 additions and 1 deletions
|
|
@ -10,7 +10,9 @@ import java.util.Properties
|
|||
import akka.TestExtras.JUnitFileReporting
|
||||
import com.typesafe.sbt.pgp.PgpKeys.publishSigned
|
||||
import sbt.Keys._
|
||||
import sbt.{TestResult, _}
|
||||
import sbt._
|
||||
import sbtwhitesource.WhiteSourcePlugin.autoImport._
|
||||
import com.typesafe.sbt.SbtGit.GitKeys._
|
||||
|
||||
object AkkaBuild {
|
||||
|
||||
|
|
@ -105,6 +107,23 @@ object AkkaBuild {
|
|||
ivyLoggingLevel in ThisBuild := UpdateLogging.Quiet,
|
||||
|
||||
licenses := Seq(("Apache License, Version 2.0", url("http://www.apache.org/licenses/LICENSE-2.0"))),
|
||||
// do not change the value of whitesourceProduct
|
||||
whitesourceProduct in ThisBuild := "Lightbend Reactive Platform",
|
||||
whitesourceAggregateProjectName in ThisBuild := {
|
||||
"akka-" + (
|
||||
if (version.value.endsWith("SNAPSHOT"))
|
||||
if (gitCurrentBranch.value == "master") "master"
|
||||
else "adhoc"
|
||||
else majorMinor(version.value).map(_ + "-current").getOrElse("snapshot"))
|
||||
},
|
||||
whitesourceAggregateProjectToken in ThisBuild := {
|
||||
// These are not secrets but integration identifiers:
|
||||
whitesourceAggregateProjectName.value match {
|
||||
case "akka-master" => "d6ca7d74-d8d8-4682-b32c-6d62ea76d26a"
|
||||
case "akka-adhoc" => "754219db-b6ef-4e5d-89af-9594ff654b63"
|
||||
case other => throw new Exception(s"Please add project '$other' to whitesource and record the integration token here")
|
||||
}
|
||||
},
|
||||
homepage := Some(url("http://akka.io/")),
|
||||
|
||||
apiURL := Some(url(s"http://doc.akka.io/api/akka/${version.value}")),
|
||||
|
|
@ -179,4 +198,5 @@ object AkkaBuild {
|
|||
}
|
||||
}
|
||||
|
||||
def majorMinor(version: String): Option[String] ="""\d+\.\d+""".r.findFirstIn(version)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -39,3 +39,7 @@ addSbtPlugin("io.spray" % "sbt-boilerplate" % "0.6.0")
|
|||
addSbtPlugin("com.timushev.sbt" % "sbt-updates" % "0.1.10")
|
||||
|
||||
addSbtPlugin("com.lightbend.akka" % "sbt-paradox-akka" % "0.3")
|
||||
|
||||
addSbtPlugin("com.lightbend" % "sbt-whitesource" % "0.1.1")
|
||||
|
||||
addSbtPlugin("com.typesafe.sbt" % "sbt-git" % "0.9.3")
|
||||
Loading…
Add table
Add a link
Reference in a new issue