Skip to content

Workaround #77 use maven central over http (fix #77) #79

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ scala:
- 2.12.6
- 2.13.0-M4
jdk:
- openjdk7
- openjdk6
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think we still need the explicit jdk_switcher command, no? f43e772#diff-354f30a63fb0907d4ad57269548329e3L48

- oraclejdk8
env:
global:
Expand All @@ -23,10 +23,10 @@ env:
matrix:
exclude:
# > 2.12 requires jdk8
- jdk: openjdk7
- jdk: openjdk6
scala: 2.12.6

- jdk: openjdk7
- jdk: openjdk6
scala: 2.13.0-M4

# ?
Expand All @@ -45,9 +45,9 @@ matrix:

# | jdk | scala | scala target | scala target version | scalafix test |
# | ----------- | --------- | ------------ | -------------------- |---------------|
# | openjdk7 | 2.11.12 | jvm | | |
# | openjdk7 | 2.11.12 | js | 0.6.23 | |
# | openjdk7 | 2.11.12 | js | 1.0.0-M3 | |
# | openjdk6 | 2.11.12 | jvm | | |
# | openjdk6 | 2.11.12 | js | 0.6.23 | |
# | openjdk6 | 2.11.12 | js | 1.0.0-M3 | |
# | oraclejdk8 | 2.12.6 | jvm | | |
# | oraclejdk8 | 2.12.6 | js | 0.6.23 | |
# | oraclejdk8 | 2.12.6 | js | 1.0.0-M3 | |
Expand Down
6 changes: 6 additions & 0 deletions admin/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,12 @@ set -e

RELEASE_COMBO=true

if [[ "$TRAVIS_JDK_VERSION" == "openjdk6" ]]; then
# https://github.com/sbt/sbt/blob/3972b7a3fcc8ea2e4c987e6c1adc13468f49e0be/launch/src/main/input_resources/sbt/sbt.boot.properties#L13-L19
mkdir -p ~/.sbt
cp admin/repositories-jdk6 ~/.sbt/repositories
fi

if [ "$SCALAJS_VERSION" = "" ]; then
if [[ "$TEST_SCALAFIX" == "true" ]]; then
projectPrefix="scalafixRules"
Expand Down
7 changes: 7 additions & 0 deletions admin/repositories-jdk6
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[repositories]
local
local-preloaded-ivy: file:///${sbt.preloaded-${sbt.global.base-${user.home}/.sbt}/preloaded/}, [organization]/[module]/[revision]/[type]s/[artifact](-[classifier]).[ext]
local-preloaded: file:///${sbt.preloaded-${sbt.global.base-${user.home}/.sbt}/preloaded/}
maven-central-over-http: http://repo1.maven.org/maven2/
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so there's also an issue with downloading from maven central, which is worked around here? this doesn't fix publishing to sonatype, right? could you explain in the commit message?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct, we should also change the publishTo to http.

https://github.com/scala/sbt-scala-module/blob/5c7c76c003cf681ca8d3199bec4cc8b8477942eb/src/main/scala/ScalaModulePlugin.scala#L117-L119

It's using:

> show compat/publishTo
[info] Some(sonatype-snapshots: https://oss.sonatype.org/content/repositories/snapshots)

However, this would be a security vulnerability. I will close this PR. The other solution to use jdk8 for sbt but use annother jdk forking makes sense.

typesafe-ivy-releases: https://repo.typesafe.com/typesafe/ivy-releases/, [organization]/[module]/[revision]/[type]s/[artifact](-[classifier]).[ext], bootOnly
sbt-ivy-snapshots: https://repo.scala-sbt.org/scalasbt/ivy-snapshots/, [organization]/[module]/[revision]/[type]s/[artifact](-[classifier]).[ext], bootOnly