Publishing to OSS sonatype
This commit is contained in:
parent
60d19ed4cb
commit
fd3f6447ac
2 changed files with 40 additions and 32 deletions
|
@ -27,37 +27,6 @@ object Build extends sbt.Build {
|
||||||
id = "runtime",
|
id = "runtime",
|
||||||
base = file("runtime")
|
base = file("runtime")
|
||||||
).settings(publishArtifact := true)
|
).settings(publishArtifact := true)
|
||||||
.settings(publishMavenStyle := true)
|
|
||||||
.settings(organization := "org.capnproto")
|
|
||||||
.settings(version := "0.1.0-SNAPSHOT")
|
|
||||||
.settings(autoScalaLibrary := false)
|
|
||||||
.settings(autoScalaLibrary in test := false)
|
|
||||||
.settings(publishTo := {
|
|
||||||
val nexus = "https://oss.sonatype.org/"
|
|
||||||
if (isSnapshot.value)
|
|
||||||
Some("snapshots" at nexus + "content/repositories/snapshots")
|
|
||||||
else
|
|
||||||
Some("releases" at nexus + "service/local/staging/deploy/maven2")
|
|
||||||
})
|
|
||||||
.settings(pomExtra := (
|
|
||||||
<url>https://dwrensha.github.io/capnproto-java/index.html</url>
|
|
||||||
<licenses>
|
|
||||||
<license>
|
|
||||||
<name>MIT</name>
|
|
||||||
<url>http://opensource.org/licenses/MIT</url>
|
|
||||||
<distribution>repo</distribution>
|
|
||||||
</license>
|
|
||||||
</licenses>
|
|
||||||
<scm>
|
|
||||||
<url>git@github.com:dwrensha/capnproto-java.git</url>
|
|
||||||
<connection>scm:git:git@github.com:dwrensha/capnproto-java.git</connection>
|
|
||||||
</scm>
|
|
||||||
<developers>
|
|
||||||
<developer>
|
|
||||||
<id>dwrensha</id>
|
|
||||||
<name>David Renshaw</name>
|
|
||||||
</developer>
|
|
||||||
</developers>))
|
|
||||||
.settings(crossPaths := false) // disable outputting the _<scala-version> suffix
|
.settings(crossPaths := false) // disable outputting the _<scala-version> suffix
|
||||||
|
|
||||||
lazy val examples =
|
lazy val examples =
|
||||||
|
@ -143,8 +112,43 @@ object Shared {
|
||||||
resolvers += Resolver.sonatypeRepo("releases"),
|
resolvers += Resolver.sonatypeRepo("releases"),
|
||||||
shellPrompt := ShellPrompt.buildShellPrompt,
|
shellPrompt := ShellPrompt.buildShellPrompt,
|
||||||
organization := "org.capnproto",
|
organization := "org.capnproto",
|
||||||
publishArtifact := false
|
publishArtifact := false,
|
||||||
|
publishTo := {
|
||||||
|
val nexus = "https://oss.sonatype.org/"
|
||||||
|
if (isSnapshot.value)
|
||||||
|
Some("snapshots" at nexus + "content/repositories/snapshots")
|
||||||
|
else
|
||||||
|
Some("releases" at nexus + "service/local/staging/deploy/maven2")
|
||||||
|
},
|
||||||
|
credentials += Credentials(Path.userHome / ".ivy2" / ".credentials"),
|
||||||
|
publishMavenStyle := true,
|
||||||
|
version := "0.1.0-SNAPSHOT",
|
||||||
|
publishArtifact in Test := false,
|
||||||
|
pomIncludeRepository := { x => false },
|
||||||
|
pomExtra := (
|
||||||
|
<url>https://capnproto.org/</url>
|
||||||
|
<licenses>
|
||||||
|
<license>
|
||||||
|
<name>MIT</name>
|
||||||
|
<url>http://opensource.org/licenses/MIT</url>
|
||||||
|
<distribution>repo</distribution>
|
||||||
|
</license>
|
||||||
|
</licenses>
|
||||||
|
<scm>
|
||||||
|
<url>git@github.com:dwrensha/capnproto-java.git</url>
|
||||||
|
<connection>scm:git@github.com:dwrensha/capnproto-java.git</connection>
|
||||||
|
</scm>
|
||||||
|
<developers>
|
||||||
|
<developer>
|
||||||
|
<id>dwrensha</id>
|
||||||
|
<name>David Renshaw</name>
|
||||||
|
<url>https://github.com/dwrensha</url>
|
||||||
|
</developer>
|
||||||
|
</developers>
|
||||||
|
)
|
||||||
|
|
||||||
)
|
)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
object ShellPrompt {
|
object ShellPrompt {
|
||||||
|
@ -168,3 +172,5 @@ object ShellPrompt {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -2,4 +2,6 @@ addSbtPlugin("com.github.mpeltonen" % "sbt-idea" % "1.5.2")
|
||||||
|
|
||||||
addSbtPlugin("net.virtual-void" % "sbt-dependency-graph" % "0.7.4")
|
addSbtPlugin("net.virtual-void" % "sbt-dependency-graph" % "0.7.4")
|
||||||
|
|
||||||
|
resolvers += Resolver.url("scalasbt", new URL("http://scalasbt.artifactoryonline.com/scalasbt/sbt-plugin-releases")) (Resolver.ivyStylePatterns)
|
||||||
|
|
||||||
addSbtPlugin("com.typesafe.sbt" % "sbt-pgp" % "0.8.3")
|
addSbtPlugin("com.typesafe.sbt" % "sbt-pgp" % "0.8.3")
|
||||||
|
|
Loading…
Reference in a new issue