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

Change golang datasource to read data from go.dev instead of github #27105

Open
viceice opened this issue Feb 7, 2024 · 1 comment
Open

Change golang datasource to read data from go.dev instead of github #27105

viceice opened this issue Feb 7, 2024 · 1 comment
Labels
breaking Breaking change, requires major version bump datasource:golang-version Golang versions datasource priority-3-medium Default priority, "should be done" but isn't prioritised ahead of others type:feature Feature (new functionality)

Comments

@viceice
Copy link
Member

viceice commented Feb 7, 2024

Describe the proposed change(s).

read from here https://go.dev/dl/?mode=json&include=all

That way we can ensure binaries are available.

@viceice viceice added type:feature Feature (new functionality) priority-3-medium Default priority, "should be done" but isn't prioritised ahead of others breaking Breaking change, requires major version bump datasource:go datasource:golang-version Golang versions datasource and removed datasource:go labels Feb 7, 2024
@mikaello
Copy link
Contributor

mikaello commented Apr 19, 2024

JSONata for those wanting to try the go.dev datasource:

{
  "releases": $[stable = true].{ "version": $split(version, "go")[1] },
  "sourceUrl": "https://github.com/golang/go",
  "homepage": "https://go.dev/",
  "changelogUrl": "https://go.dev/doc/devel/release"
}

(see playground for result: https://try.jsonata.org/FuOjg91Vm)

Add this to your Renovate config to make it available as a custom datasource with name custom.golang-version:

  "customDatasources": {
    "golang-version": {
      "defaultRegistryUrlTemplate": "https://go.dev/dl/?mode=json&include=all",
      "transformTemplates": [
        "{ \"releases\": $[stable = true].{ \"version\": $split(version, \"go\")[1] }, \"sourceUrl\": \"https://github.com/golang/go\", \"homepage\": \"https://go.dev/\", \"changelogUrl\": \"https://go.dev/doc/devel/release\" }"
      ]
    }
  }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking Breaking change, requires major version bump datasource:golang-version Golang versions datasource priority-3-medium Default priority, "should be done" but isn't prioritised ahead of others type:feature Feature (new functionality)
Projects
None yet
Development

No branches or pull requests

3 participants
@viceice @mikaello and others