SpinalHDL 的发布不外乎是这几类
- 发布到maven官方仓, 一般用户不涉及, 由charles 发布
- 发布到私服
- 发布到~/.ivy2,
sbt publishLocal
- 发布到~/.m2,
sbt publishM2
- 发布到指定路径 , 这样方便大家共享
sbt publish
前提是需要指定发布路径:
打开SpinalHDL, 编辑build.sbt
publishTo := {
val v = version.value
val nexus = "https://oss.sonatype.org/"
val miyetxnexus = "http://xxxxxx.com:8081/"
if (isSnapshot.value)
// Some(("releases" at miyetxnexus + "reposity/maven-snapshot").withAllowInsecureProtocol(true))
Some(Resolver.file("local-ivy", file("/pubxxxxxx/cache/.m2/repository"))) //本地共享路径
else
Some("releases" at nexus + "service/local/staging/deploy/maven2")
}
另外 用户的~/.sbt/repositories 中需要指定
[repositories]
local
yellow-nexus : http://xxxxxxx:8081/repository/maven-public/, allowInsecureProtocol
yello-local: file:///pubxxxxxx/cache/.m2/repository