sbt 不解决依赖;路径正确,除了 ${package.type} 扩展名 [英] sbt not resolving dependency; path correct except ${package.type} extension
问题描述
sbt (0.13.8) 无法解析以下极其简单的 build.sbt
中的依赖项:
sbt (0.13.8) is failing to resolve the dependency in the following extremely simple build.sbt
:
organization := "edu.umass.cs.iesl"
name := "nn-depparse"
version := "0.1-SNAPSHOT"
scalaVersion := "2.11.7"
resolvers += "IESL snapshot repository" at "https://dev-iesl.cs.umass.edu/nexus/content/repositories/snapshots/"
libraryDependencies += "cc.factorie" %% "factorie" % "1.2-SNAPSHOT"
parallelExecution := true
出于某种原因,它解析了以下路径:
For some reason it resolves the following path:
https://dev-iesl.cs.umass.edu/nexus/content/repositories/snapshots/cc/factorie/factorie_2.11/1.2-SNAPSHOT/factorie_2.11-1.2-20151007.170205-28.${package.type}
https://dev-iesl.cs.umass.edu/nexus/content/repositories/snapshots/cc/factorie/factorie_2.11/1.2-SNAPSHOT/factorie_2.11-1.2-20151007.170205-28.${package.type}
而不是jar的正确路径:
Rather than the correct path to the jar:
似乎 ${package.type}
被解释为文字文件扩展名,而不是变量 package.type
的任何内容,但我有不知道为什么;我正在使用最简单的构建配置!据我所知,我没有任何奇怪的 sbt 配置(或根本没有——我检查了 ~/.sbt
,并且我尝试在多台机器上运行).>
It seems as though ${package.type}
is being interpreted as a literal file extension rather than whatever the contents of the variable package.type
, but I have no idea why; I am using the simplest possible build configuration! As far as I know, I don't have any weird sbt configurations lying around (or any at all -- I checked ~/.sbt
, and I have tried running on multiple machines).
推荐答案
在 factorie_2.11-1.2-20151007.170205-28.pom>
<packaging>${package.type}</packaging>
我想 sbt 使用此设置来获取工件.
I suppose sbt uses this setting to get the artifact.
在之前的 .pom 文件,它有:
<packaging>jar</packaging>
所以,也许这是一个损坏的构建.
So, maybe it's a broken build.
这篇关于sbt 不解决依赖;路径正确,除了 ${package.type} 扩展名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!