Skip to content

Commit a1f677d

Browse files
committed
Added OSGi settings to build.
1 parent c64f5e7 commit a1f677d

File tree

3 files changed

+33
-1
lines changed

3 files changed

+33
-1
lines changed

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,10 @@
11
# ScalaTest + JUnit
22
ScalaTest + JUnit provides integration support between ScalaTest and JUnit.
3+
4+
**Publishing**
5+
6+
Please use the following commands to publish to Sonatype:
7+
8+
```
9+
$ sbt +publishSigned
10+
```

build.sbt

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name := "scalatestplus-junit"
22

33
organization := "org.scalatestplus"
44

5-
version := "1.0.0-SNAP3"
5+
version := "1.0.0-SNAP4"
66

77
homepage := Some(url("https://github.com/scalatest/scalatestplus-junit"))
88

@@ -36,6 +36,28 @@ testOptions in Test :=
3636
"-m", "org.scalatestplus.junit",
3737
))
3838

39+
enablePlugins(SbtOsgi)
40+
41+
osgiSettings
42+
43+
OsgiKeys.exportPackage := Seq(
44+
"org.scalatestplus.junit.*"
45+
)
46+
47+
OsgiKeys.importPackage := Seq(
48+
"org.scalatest.*",
49+
"org.scalactic.*",
50+
"scala.*;version=\"$<range;[==,=+);$<replace;"+scalaBinaryVersion.value+";-;.>>\"",
51+
"*;resolution:=optional"
52+
)
53+
54+
OsgiKeys.additionalHeaders:= Map(
55+
"Bundle-Name" -> "ScalaTestPlusJUnit",
56+
"Bundle-Description" -> "ScalaTest+JUnit is an open-source integration library between ScalaTest and JUnit for Scala projects.",
57+
"Bundle-DocURL" -> "http://www.scalatest.org/",
58+
"Bundle-Vendor" -> "Artima, Inc."
59+
)
60+
3961
publishTo := {
4062
val nexus = "https://oss.sonatype.org/"
4163
Some("publish-releases" at nexus + "service/local/staging/deploy/maven2")

project/plugins.sbt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
addSbtPlugin("com.jsuereth" % "sbt-pgp" % "1.1.1")
22

33
addSbtPlugin("com.geirsson" % "sbt-ci-release" % "1.2.2")
4+
5+
addSbtPlugin("com.typesafe.sbt" % "sbt-osgi" % "0.9.4")

0 commit comments

Comments
 (0)