renovate/lib/modules/datasource/go
Sergei Zharinov 9385d488df
fix(go): Use more specific cache key for `getDigest()` (#31168)
2024-09-03 03:59:14 +00:00
..
__fixtures__ fix(go): Detect repository name from the metadata URL instead of module (#30388) 2024-08-02 07:02:08 +00:00
__snapshots__ refactor: exactOptionalPropertyTypes (#20761) 2023-03-19 16:09:46 +00:00
base.spec.ts fix(go): Revert private module URL changes (#31055) 2024-08-27 19:21:13 +00:00
base.ts fix(go): Revert private module URL changes (#31055) 2024-08-27 19:21:13 +00:00
common.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
goproxy-parser.spec.ts refactor(go): Extract GOPROXY and NOPROXY parsing utilities (#27671) 2024-03-01 17:39:35 +00:00
goproxy-parser.ts refactor(go): Extract GOPROXY and NOPROXY parsing utilities (#27671) 2024-03-01 17:39:35 +00:00
index.spec.ts fix(go): Use more specific cache key for `getDigest()` (#31168) 2024-09-03 03:59:14 +00:00
index.ts fix(go): Use more specific cache key for `getDigest()` (#31168) 2024-09-03 03:59:14 +00:00
readme.md fix(datasource/go): use @latest to determine pseudo version (#28708) 2024-04-29 08:32:44 +00:00
releases-direct.spec.ts fix(datasource/go): Generalize submodule filtering logic (#25938) 2023-11-24 06:59:04 +00:00
releases-direct.ts fix(datasource/go): Generalize submodule filtering logic (#25938) 2023-11-24 06:59:04 +00:00
releases-goproxy.spec.ts fix(datasource/go): support go proxy with abortOnError (#29823) 2024-07-15 17:57:14 +00:00
releases-goproxy.ts fix(datasource/go): support go proxy with abortOnError (#29823) 2024-07-15 17:57:14 +00:00
types.ts fix(go)!: Fallback to git-tags instead of github-tags (#18060) 2022-10-23 06:48:35 +02:00

readme.md

The best way to lookup Go Modules is using Go proxies.

GOPROXY settings

This datasource will use default GOPROXY settings of https://proxy.golang.org,direct if the environment variable is unset.

To override this default and use a different proxy in self-hosted environments, configure GOPROXY to an alternative setting in env.

To override this default and stop using any proxy at all, set GOPROXY to the value direct.

Pseudo versions

Go proxies return an empty list of versions when queried (@v/list) for a package which uses pseudo versions, but return the latest pseudo-version when queried for @latest.

If the @latest endpoint returns a pseudo-version, and the release list is empty, then this datasource will return the latest pseudo-version as the only release/version for the package.

Checking for new major releases

When a Go proxy is queried for @v/list it returns only versions for v0 or v1 of a package. Therefore Renovate will also query @v2/list just in case there also exists a v2 of the package. Similarly, if the dependency is already on a higher version such as v5, Renovate will check in case higher major versions exist. You do not need to be worried about any 404 responses which result from such checks - they are the only way for Renovate to know if newer major releases exist.

Fallback to direct lookups

If no result is found from Go proxy lookups then Renovate will fall back to direct lookups.