workaround for SDKMAN getting stuck#8528
Merged
SethTisue merged 1 commit intoscala:2.13.xfrom Nov 6, 2019
Merged
Conversation
c61c14d to
b4cc7da
Compare
Member
Author
|
I got impatient and wiped out the Travis CI cache, so I need to use some other repository to test if this actually fixes this. |
eed3si9n
added a commit
to eed3si9n/io
that referenced
this pull request
Nov 6, 2019
Ref scala/scala#8528 Currently SDKMAN blocks for prompt when there's a new version of SDKMAN. This is an attempted workaround.
This comment has been minimized.
This comment has been minimized.
eed3si9n
added a commit
to eed3si9n/io
that referenced
this pull request
Nov 6, 2019
Ref scala/scala#8528 Currently SDKMAN blocks for prompt when there's a new version of SDKMAN. This is an attempted workaround.
Currently SDKMAN blocks for prompt when there's a new version of SDKMAN. ``` $ sdk list java ... ATTENTION: A new version of SDKMAN is available... The current version is 5.7.4+362, but you have 5.7.3+337. Would you like to upgrade now? (Y/n): ``` This in turn blocks our automated AdoptOpenJDK installation script: ``` sdk install java $(sdk list java | grep -o "$ADOPTOPENJDK\.[0-9\.]*hs-adpt" | head -1) ``` An additional setting `sdkman_auto_selfupdate=true` is needed so it's updated automatically. This also adds `| true` to `sdk install` because it started to return 1 if the same Jave version is already installed.
eed3si9n
commented
Nov 6, 2019
|
|
||
| install: | ||
| - sdk install java $(sdk list java | grep -o "$ADOPTOPENJDK\.[0-9\.]*hs-adpt" | head -1) | ||
| - sdk install java $(sdk list java | grep -o "$ADOPTOPENJDK\.[0-9\.]*hs-adpt" | head -1) | true |
Member
Author
There was a problem hiding this comment.
Note that the latest SDKMAN started failing when the JDK version is already installed, so we need this workaround here.
Contributor
|
Thanks, I used this PR as an example at the office of how knowledge transfer works in an open society. |
Member
Author
|
I should give credits to Marco Vermeulen, SDKMAN himself, who helped me fix this issue via their Slack channel. |
This was referenced Nov 12, 2019
eed3si9n
added a commit
to eed3si9n/zinc
that referenced
this pull request
Dec 28, 2019
eed3si9n
added a commit
to eed3si9n/zinc
that referenced
this pull request
Jan 8, 2020
eed3si9n
added a commit
to eed3si9n/io
that referenced
this pull request
Jan 19, 2020
Ref scala/scala#8528 Currently SDKMAN blocks for prompt when there's a new version of SDKMAN. This is an attempted workaround.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Currently SDKMAN blocks for prompt when there's a new version of SDKMAN.
This in turn blocks our automated AdoptOpenJDK installation script:
An additional setting
sdkman_auto_selfupdate=trueis needed so it's updated automatically.Due to frikke/sdkman-cli@1fe19fe, the latest SDKMAN returns exist code of
1when the desired JDK is already installed. To workaround this, I added| truetosdk installline.