Skip to content

Commit

Permalink
Changed project organization to com.xebialabs.
Browse files Browse the repository at this point in the history
Changed publishing method since we have to publish to private nexus repository
  • Loading branch information
ilx committed Aug 9, 2024
1 parent 1dfc84f commit c32a6b3
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 3 deletions.
28 changes: 26 additions & 2 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def scalaVersionSpecificFolders(srcBaseDir: java.io.File, scalaVersion: String):
}

val sharedSettings = Seq(
organization := "com.twitter",
organization := "com.xebialabs.chill",
scalaVersion := "2.13.13",
crossScalaVersions := Seq("2.11.12", "2.12.17", "2.13.13"),
scalacOptions ++= Seq("-unchecked", "-deprecation"),
Expand Down Expand Up @@ -54,7 +54,7 @@ val sharedSettings = Seq(
"com.esotericsoftware" % "kryo5" % kryoVersion
),
Test / parallelExecution := true,
pomExtra := <url>https://github.com/twitter/chill</url>
pomExtra := <url>https://github.com/xebialabs/chill</url>
<licenses>
<license>
<name>Apache 2</name>
Expand Down Expand Up @@ -235,3 +235,27 @@ lazy val chillAlgebird = module("algebird")
)
)
.dependsOn(chill)

ThisBuild / dynverSeparator := "-"
ThisBuild / dynverSonatypeSnapshots := true
ThisBuild / publishMavenStyle := true
ThisBuild / credentials += {
(sys.env.get("NEXUS_HOST"), sys.env.get("NEXUS_USERNAME"), sys.env.get("NEXUS_PASSWORD")) match {
case (Some(host), Some(user), Some(password)) =>
Credentials("Sonatype Nexus Repository Manager", host, user, password)
case _ =>
val credentialsFile = Path.userHome / ".sbt" / ".chill-credentials"
if (credentialsFile.exists()) {
Credentials(credentialsFile)
} else {
throw new IllegalStateException("~/.sbt/.chill-credentials file does not exist and NEXUS_ variables are not provided")
}
}
}
ThisBuild / publishTo := {
val nexus = "https://nexus.xebialabs.com/nexus/content/"
if (isSnapshot.value)
Some("snapshots".at(nexus + "repositories/snapshots"))
else
Some("releases".at(nexus + "repositories/releases"))
}
4 changes: 3 additions & 1 deletion project/plugins.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
addSbtPlugin("org.scoverage" % "sbt-scoverage" % "2.1.0")
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.0")
addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.10.4")
addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.5.11")
// https://github.com/sbt/sbt-dynver
addSbtPlugin("com.github.sbt" % "sbt-dynver" % "5.0.1")
//addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.5.12")
addSbtPlugin("com.thesamet" % "sbt-protoc" % "1.0.6")

libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.11.13"

0 comments on commit c32a6b3

Please sign in to comment.