-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathbuild.sbt
111 lines (99 loc) · 3.45 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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
import com.amazonaws.services.s3.model.Region
import com.amazonaws.auth.profile.ProfileCredentialsProvider
import com.amazonaws.auth.{EnvironmentVariableCredentialsProvider, InstanceProfileCredentialsProvider}
import sbt.Def
import ohnosequences.sbt.SbtS3Resolver.autoImport.{s3 => ss33, _}
lazy val ossBucket: String =
sys.env.getOrElse("AMBIATA_IVY_OSS", "ambiata-oss")
lazy val standardSettings: Seq[Def.Setting[_]] =
Defaults.coreDefaultSettings ++ promulgateSettings
lazy val promulgateSettings: Seq[Def.Setting[_]] = Seq(
organization := "com.ambiata"
, sbtPlugin := true
, version in ThisBuild := "0.12.0"
, scalaVersion := "2.10.7"
, scalacOptions := Seq(
"-deprecation"
, "-unchecked"
, "-optimise"
// , "-Ywarn-all"
, "-Xlint"
, "-Xfatal-warnings"
, "-feature"
, "-language:_"
)
, publishMavenStyle := false
, publishArtifact in Test := false
, pomIncludeRepository := { _ => false }
, awsProfile := "default"
, s3region := Region.AP_Sydney
, s3overwrite := false
, s3acl := com.amazonaws.services.s3.model.CannedAccessControlList.BucketOwnerFullControl
, s3sse := false
, s3credentials := new EnvironmentVariableCredentialsProvider() |
InstanceProfileCredentialsProvider.getInstance() |
new ProfileCredentialsProvider(awsProfile.value)
, publishTo := Some(s3resolver.value("ambiata-oss-publish", ss33(ossBucket)).withIvyPatterns)
)
lazy val promulgate = (project in file("."))
.settings(
name := "promulgate"
, standardSettings
, version in ThisBuild := "0.12.0"
, VersionPlugin.uniqueVersionSettings
)
.aggregate(source, info, notify_, assembly, s3, version_, project_)
.dependsOn(source)
.dependsOn(info)
.dependsOn(notify_)
.dependsOn(assembly)
.dependsOn(s3)
.dependsOn(version_)
.dependsOn(project_)
lazy val source = (project in file("promulgate-source"))
.settings(
standardSettings
, name := "promulgate-source"
)
lazy val info = (project in file("promulgate-info"))
.settings(
standardSettings
, name := "promulgate-info"
).dependsOn(version_)
lazy val assembly = (project in file("promulgate-assembly"))
.settings(
standardSettings
, name := "promulgate-assembly"
, addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.11.2")
)
lazy val s3 = (project in file("promulgate-s3"))
.settings(
standardSettings
, name := "promulgate-s3"
, resolvers += "Era7 maven releases" at "http://releases.era7.com.s3.amazonaws.com"
, libraryDependencies ++= Seq("joda-time" % "joda-time" % "2.2")
, resolvers += Resolver.url("sbts3 ivy resolver", url("https://dl.bintray.com/emersonloureiro/sbt-plugins"))(Resolver.ivyStylePatterns)
, addSbtPlugin(("cf.janga" % "sbts3" % "0.10") exclude("joda-time", "joda-time"))
, addSbtPlugin(("ohnosequences" % "sbt-s3-resolver" % "0.16.0") exclude("joda-time", "joda-time"))
).dependsOn(assembly)
lazy val notify_ = (project in file("promulgate-notify"))
.settings(
standardSettings
, name := "promulgate-notify"
, libraryDependencies := Seq("net.databinder.dispatch" %% "dispatch-core" % "0.11.0")
)
lazy val version_ = (project in file("promulgate-version"))
.settings(
standardSettings
, name := "promulgate-version"
)
lazy val project_ = (project in file("promulgate-project"))
.settings(
standardSettings
, name := "promulgate-project"
).dependsOn(source)
.dependsOn(info)
.dependsOn(notify_)
.dependsOn(assembly)
.dependsOn(s3)
.dependsOn(version_)