This repository has been archived by the owner on Feb 28, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 53
/
build.sbt
71 lines (65 loc) · 2.52 KB
/
build.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
lazy val unusedWarnings = Seq("-Ywarn-unused-import", "-Ywarn-unused")
ThisBuild / organization := "org.foundweekends"
ThisBuild / homepage := Some(url("https://github.com/sbt/sbt-bintray"))
ThisBuild / licenses := Seq("MIT" ->
url(s"https://github.com/sbt/${name.value}/blob/${version.value}/LICENSE"))
ThisBuild / description := "package publisher for bintray.com"
ThisBuild / developers := List(
Developer("softprops", "Doug Tangren", "@softprops", url("https://github.com/softprops"))
)
ThisBuild / scmInfo := Some(ScmInfo(url(s"https://github.com/sbt/${name.value}"), s"git@github.com:sbt/${name.value}.git"))
ThisBuild / scalaVersion := "2.12.12"
lazy val commonSettings: Seq[Setting[_]] = Seq(
scalacOptions ++= Seq(Opts.compile.deprecation, "-Xlint", "-feature"),
scalacOptions ++= PartialFunction.condOpt(CrossVersion.partialVersion(scalaVersion.value)){
case Some((2, v)) if v >= 11 => unusedWarnings
}.toList.flatten,
publishArtifact in Test := false,
bintrayRepository := "sbt-plugin-releases",
bintrayOrganization := Some("sbt"),
bintrayPackage := "sbt-bintray",
scriptedBufferLog := true,
scriptedLaunchOpts ++= Seq(
"-Xmx1024M",
"-XX:MaxPermSize=256M",
"-Dbintray.user=username",
"-Dbintray.pass=password",
"-Dplugin.version=" + version.value
),
) ++ Seq(Compile, Test).flatMap(c =>
scalacOptions in (c, console) --= unusedWarnings
)
lazy val root = (project in file("."))
.aggregate(core, sbtBintray, sbtBintrayRemoteCache)
.settings(
publish / skip := true,
)
lazy val core = (project in file("core"))
.enablePlugins(SbtPlugin)
.settings(commonSettings)
.settings(
name := "sbt-bintray-core",
libraryDependencies ++= Seq(
"org.foundweekends" %% "bintry" % "0.6.0",
"org.slf4j" % "slf4j-nop" % "1.7.28", // https://github.com/sbt/sbt-bintray/issues/26
"com.eed3si9n.verify" %% "verify" % "0.2.0" % Test,
),
testFrameworks += new TestFramework("verify.runner.Framework"),
resolvers += Resolver.sonatypeRepo("releases"),
)
lazy val sbtBintray = (project in file("sbt-bintray"))
.enablePlugins(SbtPlugin)
.dependsOn(core)
.settings(commonSettings)
.settings(
name := "sbt-bintray",
pluginCrossBuild / sbtVersion := "1.0.0",
)
lazy val sbtBintrayRemoteCache = (project in file("sbt-bintray-remote-cache"))
.enablePlugins(SbtPlugin)
.dependsOn(core)
.settings(commonSettings)
.settings(
name := "sbt-bintray-remote-cache",
pluginCrossBuild / sbtVersion := "1.4.2",
)