Skip to content
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

Move stc from bintray to maven central #89

Merged
merged 2 commits into from
Mar 30, 2021

Conversation

oyvindberg
Copy link
Contributor

Hey there.

Since bintray is shutting down this might be one of many to make this leap. The Scalablytyped converter, stc for short, had to move to maven central.

Do you think this proposed change is enough for coursier to start resolving from maven central if it was already installed from bintray?

Before this PR both maven central and bintray were specified in the channel file. Probably because it was originally resolved in bintray, coursier doesn't descend into the directories in maven central.

(beta30 is on bintray, beta31 is on maven central)

[oyvind:~] 9m54s 1 $ whereis stc
stc: /home/olvind/.local/share/coursier/bin/stc
[oyvind:~] 10m21s 1 $ stc --version
ScalablyTyped Converter (version 1.0.0-beta30)
[oyvind:~] 10m31s 1 $ cs update
... snip
Downloading https://dl.bintray.com/oyvindberg/converter/org/scala-lang/scala-library/maven-metadata.xml
Downloaded https://dl.bintray.com/oyvindberg/converter/org/scala-lang/scala-library/maven-metadata.xml
Downloading https://dl.bintray.com/oyvindberg/converter/org/scala-lang/scala-library/maven-metadata.xml.sha1
Downloaded https://dl.bintray.com/oyvindberg/converter/org/scala-lang/scala-library/maven-metadata.xml.sha1
Checking https://repo1.maven.org/maven2/
Checked https://repo1.maven.org/maven2/
Checking https://repo1.maven.org/maven2/org/
Checked https://repo1.maven.org/maven2/org/
Checking https://repo1.maven.org/maven2/org/scalablytyped/
Checked https://repo1.maven.org/maven2/org/scalablytyped/
Checking https://repo1.maven.org/maven2/org/scalablytyped/converter/
Checked https://repo1.maven.org/maven2/org/scalablytyped/converter/
Checking https://dl.bintray.com/oyvindberg/converter/
Checked https://dl.bintray.com/oyvindberg/converter/
Downloading https://dl.bintray.com/oyvindberg/converter/
Downloaded https://dl.bintray.com/oyvindberg/converter/
Checking https://dl.bintray.com/oyvindberg/converter/org/
Checked https://dl.bintray.com/oyvindberg/converter/org/
Downloading https://dl.bintray.com/oyvindberg/converter/org/
Downloaded https://dl.bintray.com/oyvindberg/converter/org/
Checking https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/
Checked https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/
Downloading https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/
Downloaded https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/
Checking https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/converter/
Checked https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/converter/
Downloading https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/converter/
Downloaded https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/converter/
Checking https://repo1.maven.org/maven2/org/scalablytyped/converter/cli_2.12/maven-metadata.xml
Checked https://repo1.maven.org/maven2/org/scalablytyped/converter/cli_2.12/maven-metadata.xml
Checking https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/converter/cli_2.12/maven-metadata.xml
Checked https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/converter/cli_2.12/maven-metadata.xml
Checking https://repo1.maven.org/maven2/org/scalablytyped/converter/cli_2.12/maven-metadata.xml
Checked https://repo1.maven.org/maven2/org/scalablytyped/converter/cli_2.12/maven-metadata.xml
Checking https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/converter/cli_2.12/maven-metadata.xml
Checked https://dl.bintray.com/oyvindberg/converter/org/scalablytyped/converter/cli_2.12/maven-metadata.xml
[oyvind:~] 10m44s 1 $ stc --version
ScalablyTyped Converter (version 1.0.0-beta30)

I didn't know how to really test the update situation, but with install and this updated channel it works at least

cs install --default-channels=false  --channel ./apps/resources stc
...
Downloading https://repo1.maven.org/maven2/org/scalablytyped/converter/cli_2.12/1.0.0-beta31/cli_2.12-1.0.0-beta31.pom

@oyvindberg
Copy link
Contributor Author

(a good idea for future improvement is to validate that all the json files are valid - my first commit was forgot to remove a , and the build was green)

Copy link
Member

@alexarchambault alexarchambault left a comment

Choose a reason for hiding this comment

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

Thanks @oyvindberg!

@alexarchambault alexarchambault merged commit 02ce30a into coursier:master Mar 30, 2021
@alexarchambault
Copy link
Member

I believe it should still have worked with the former descriptor, that's odd. Might be a bug.

It's better nonetheless to remove the bintray repo from the descriptor, as it's useless now.

@alexarchambault
Copy link
Member

I agree about validating the JSON files here. Ideally, we should check that they conform to the app descriptor schema, with no superfluous fields.

We could also require some new fields, like a description or a home page, or fill up home page ourselves from the CI here, using what's in the main dependency POM.

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.

2 participants