renovate/lib/modules/datasource
2024-01-08 11:34:55 +00:00
..
__snapshots__ test: use jest v29 (#17151) 2022-08-16 14:22:29 +02:00
artifactory build(deps): update dependency node-html-parser to v6.1.12 (#26465) 2024-01-04 07:43:36 +00:00
aws-machine-image refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
aws-rds refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
azure-bicep-resource refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
azure-pipelines-tasks refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
bazel fix(bazel): use bazel-module versioning for bazel datasource (#25649) 2023-11-08 15:42:36 +00:00
bitbucket-tags refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
cdnjs refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
clojure refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
conan refactor(util/yaml): rename load and loadAll to parseSingleYaml and parseYaml (#26084) 2023-12-01 20:13:01 +00:00
conda refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
cpan build(deps): update dependency prettier to v3 (#23627) 2023-11-07 17:12:01 +00:00
crate refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
custom fix(datasource/custom): fix local registry path (#26142) 2023-12-05 17:25:45 +00:00
dart feat(dart): allow custom registryUrls (#25987) 2023-11-27 15:09:26 +00:00
dart-version refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
deno refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
docker fix(datasource/docker): add cache decorator to getDockerHubTags (#26546) 2024-01-08 11:34:55 +00:00
dotnet-version fix(datasource/dotnet-version): use sdks property to find all sdk version (#26031) 2023-11-29 13:19:33 +00:00
endoflife-date refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
flutter-version refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
galaxy fix(datasource/galaxy): loosen schema (#25712) 2023-11-13 03:38:14 +00:00
galaxy-collection feat(datasource/galaxy-collection): support ansible automation hub (#25675) 2023-11-27 14:02:54 +00:00
git-refs docs: use relative links (#26044) 2023-11-29 18:10:17 +00:00
git-tags refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
gitea-releases refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
gitea-tags refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
github-release-attachments refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
github-releases refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
github-runners refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
github-tags refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
gitlab-packages docs: use relative links (#26044) 2023-11-29 18:10:17 +00:00
gitlab-releases docs: use relative links (#26044) 2023-11-29 18:10:17 +00:00
gitlab-tags docs: use relative links (#26044) 2023-11-29 18:10:17 +00:00
go fix(datasource/go): Generalize submodule filtering logic (#25938) 2023-11-24 06:59:04 +00:00
golang-version refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
gradle-version refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
helm refactor(util/yaml): rename load and loadAll to parseSingleYaml and parseYaml (#26084) 2023-12-01 20:13:01 +00:00
hermit refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
hex feat(datasource/hex): extract deprecated versions (#26392) 2023-12-21 17:56:41 +00:00
hexpm-bob refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
java-version refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
jenkins-plugins feat(datasource/jenkins-plugins): support constraints filtering (#26155) 2023-12-06 09:52:55 +00:00
kubernetes-api refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
maven fix(datasource/maven): restore registryStrategy=merge (#26013) 2023-11-28 15:42:27 +00:00
node-version refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
npm refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
nuget feat(datasource/nuget): extract latest tag (#26351) 2023-12-19 12:11:40 +00:00
orb refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
packagist refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
pod refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
puppet-forge refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
pypi refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
repology docs: use relative links (#26044) 2023-11-29 18:10:17 +00:00
ruby-version refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
rubygems refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
sbt-package refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
sbt-plugin refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
terraform-module refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
terraform-provider build(deps): update dependency prettier to v3 (#23627) 2023-11-07 17:12:01 +00:00
api.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
common.spec.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
common.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
datasource.spec.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
datasource.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
index.spec.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
index.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
metadata-manual.ts feat: override docker and helm package metadata (#19901) 2023-09-23 07:21:24 +00:00
metadata.spec.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
metadata.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
readme.md docs: improve datasource readme (#23653) 2023-08-03 18:09:19 +00:00
schema.ts refactor(cdnjs): Use zod schema and Result class (#23588) 2023-07-29 17:54:49 +00:00
types.ts feat: versionCompatibility (#24717) 2023-10-02 09:55:01 +00:00
util.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
utils.spec.ts refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00

Datasources

Datasources are used in Renovate primarily to fetch released versions of packages.

Follow the class-based programming style

New datasources must follow the class-based programming style. Use the java-version datasource as a reference.

Add the datasource to the API in api.ts so that the new datasource is usable. If you find Pending mocks! errors in the Jest tests and your mocked URLs are correct, make sure the datasource is correctly registered.

getReleases

The minimum exported interface for a datasource is a function called getReleases that takes a lookup config as input.

The config has:

  • packageName: the package's full name including scope if present (e.g. @foo/bar)
  • registryUrls: an array of registry URLs to try

getReleases should return an object having:

  • releases: an array of strings of matched versions. This is the only mandatory field
  • deprecationMessage: a string description of the package's deprecation notice, if applicable
  • sourceUrl: a HTTP URL pointing to the source code (for example on GitHub)
  • homepage: a HTTP URL for the package's homepage. Ideally should be empty if the homepage and sourceUrl are the same
  • changelogUrl: a URL pointing to the package's changelog (could be a Markdown file, for example). If not present then Renovate will search the sourceUrl for a changelog file
  • tags: an object mapping tag -> version, for example tags: { latest: '3.0.0' }. This is only used by the followTags function

getDigest

Datasources that support digests (like Docker digests and Git commit hashes) can export a getDigest function.

The getDigest function has two inputs:

  • config: the Renovate config for the package being updated, has the same fields as getReleases
  • newValue: the version or value to retrieve the digest for

The getDigest function returns a string output representing the digest value. If no digest is found, the getDigest function should return null.