Skip to content

[NO MERGE] Force deleting sources/javadoc to fix sbt/sbt#1750#15

Closed
dwijnand wants to merge 4 commits intosbt:2.3.x-sbtfrom
dwijnand:issue/sbt/gh1750/updateClassifiers/SNAPSHOT
Closed

[NO MERGE] Force deleting sources/javadoc to fix sbt/sbt#1750#15
dwijnand wants to merge 4 commits intosbt:2.3.x-sbtfrom
dwijnand:issue/sbt/gh1750/updateClassifiers/SNAPSHOT

Conversation

@dwijnand
Copy link
Member

@dwijnand dwijnand commented Aug 8, 2015

This is an attempt fix sbt/sbt#1750 by forcing the deletion of any sources, src or javadoc present if a POM was updated (ie. new SNAPSHOT release).

But I can't seem to change sbt to use this updated version to finish testing it works.

Can anyone try please?

The last commit is just for debugging my problem with updating, intended to be dropped.

@jsuereth
Copy link
Member

jsuereth commented Aug 8, 2015

@dwijnand For some reason this test is failing: [junit] Test org.apache.ivy.plugins.circular.WarnCircularDependencyStrategyTest FAILED

@dwijnand
Copy link
Member Author

dwijnand commented Aug 9, 2015

Passes locally. I'll restart it (the cheaty way).

@dwijnand dwijnand closed this Aug 9, 2015
@dwijnand dwijnand reopened this Aug 9, 2015
@dwijnand
Copy link
Member Author

Btw, the setup for testing sbt's 1750 is:

  • Stock Nexus installed with homebrew
  • sbt-gh1750-bippy, the SNAPSHOT dependency
  • sbt-gh1750-myapp, the project trying to get updated SNAPSHOT sources
  • Tweak bippy, and publish to Nexus
  • Run updateClassifiers in myapp, see if it downloads the sources jar
  • As a second test, check the contents bippy:
unzip -c ~/.ivy2/cache/com.dwijnand/sbt-gh1750-bippy_2.11/srcs/sbt-gh1750-bippy_2.11-0.1.0-SNAPSHOT-sources.jar Bippy.scala
// sbt-gh1750-bippy/build.sbt

organization := "com.dwijnand"
        name := "sbt-gh1750-bippy"
     version := "0.1.0-SNAPSHOT"
scalaVersion := "2.11.7"

val localNexusReleases  = "local-nexus-releases"  at "http://localhost:8081/nexus/content/repositories/releases"
val localNexusSnapshots = "local-nexus-snapshots" at "http://localhost:8081/nexus/content/repositories/snapshots"
val localNexusCreds = Credentials("Sonatype Nexus Repository Manager", "localhost", "admin", "admin123")

publishTo := Some(if (isSnapshot.value) localNexusSnapshots else localNexusReleases)
credentials := Seq(localNexusCreds)
// sbt-gh1750-myapp/build.sbt
organization := "com.dwijnand"
        name := "sbt-gh1750-myapp"
     version := "0.1.0-SNAPSHOT"
scalaVersion := "2.11.7"

val localNexusReleases  = "local-nexus-releases"  at "http://localhost:8081/nexus/content/repositories/releases"
val localNexusSnapshots = "local-nexus-snapshots" at "http://localhost:8081/nexus/content/repositories/snapshots"

resolvers += localNexusReleases
resolvers += localNexusSnapshots

libraryDependencies += "com.dwijnand" %% "sbt-gh1750-bippy" % "0.1.0-SNAPSHOT"

@dwijnand
Copy link
Member Author

@eed3si9n Confirmed and help me confirm that I was in fact updating Ivy version.

Confirmation can be found via

> reload plugins
> show externalDependencyClasspath

Remote debugging in IntelliJ was just confused. Along with being confused I might've not refreshed IntelliJ with the build changes.

Proper PR in #17.

@dwijnand dwijnand closed this Aug 17, 2015
@dwijnand dwijnand deleted the issue/sbt/gh1750/updateClassifiers/SNAPSHOT branch August 17, 2015 15:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

updateClassifiers doesn't download sources and docs for updated snapshot dependencies

2 participants