Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I have the following lines in my build.sbt file.

resolvers += "specs2 snapshot repo" at "http://scala-tools.org/repo-snapshots"

libraryDependencies += "org.specs2" %% "specs2" % "1.7-SNAPSHOT" % "test"

Now if the snapshot has changed (is this reasonable at all, that a maven SNAPSHOT version changes without its version number changing?), how can I tell sbt to download the new version? Using update does nothing.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
813 views
Welcome To Ask or Share your Answers For Others

1 Answer

you should try :

libraryDependencies += "org.specs2" %% "specs2" % "1.7-SNAPSHOT" % "test" changing()

changing() will specify that the dependency can change and that it ivy must download it on each update.

Maybe you could also try to define your repository using ivyXML. Something like this :

ivyXML :=
  <resolvers>
    ????<ibiblio name="specs2 snapshot repo" changingPattern="*-SNAPSHOT" m2compatible="true" root="http://scala-tools.org/repo-snapshots"/>
  </resolvers>

Hope this will help.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...