0
0
Fork 0
mirror of https://github.com/renovatebot/renovate.git synced 2025-05-12 15:41:58 +00:00
renovatebot_renovate/lib/modules/datasource
2025-05-12 13:21:04 +00:00
..
__snapshots__ test: migrate to vitest (#34475) 2025-02-26 09:35:54 +00:00
artifactory test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
aws-eks-addon feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
aws-machine-image feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
aws-rds feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
azure-bicep-resource test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
azure-pipelines-tasks feat(datasource/azure-pipelines-tasks): add built-in tasks changelog url (#35325) 2025-04-12 05:21:55 +00:00
bazel feat(bazel): Support local file based bcr (#35273) 2025-04-20 06:36:30 +00:00
bitbucket-server-tags feat(bitbucket-server): add support for changelogs (#34569) 2025-04-09 09:45:32 +00:00
bitbucket-tags test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
bitrise test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
buildpacks-registry test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
cdnjs fix: Add missing memory caching to HTTP requests (#35793) 2025-05-08 05:01:50 +00:00
clojure feat(datasource/maven)!: use latest and release values as tags (#35515) 2025-04-30 10:51:58 +02:00
conan test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
conda chore(deps): update linters (main) (#35113) 2025-04-02 14:28:27 +00:00
cpan chore(deps): update linters (main) (#35113) 2025-04-02 14:28:27 +00:00
crate fix: properly pass configured env (#35835) 2025-05-09 11:31:00 +00:00
custom feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
dart test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
dart-version test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
deb feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
deno test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
devbox test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
docker feat(util): getEnv (#35161) 2025-05-06 18:37:28 +00:00
dotnet-version test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
endoflife-date feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
flutter-version test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
galaxy test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
galaxy-collection test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
git-refs fix: properly pass configured env (#35835) 2025-05-09 11:31:00 +00:00
git-tags test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
gitea-releases test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
gitea-tags test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
github-release-attachments test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
github-releases test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
github-runners feat(datasource/github-runners): mark Windows Server 2019 as deprecated (#35408) 2025-04-16 15:47:33 +00:00
github-tags fix(github): Memory cache for commits request (#35586) 2025-04-27 16:44:39 +00:00
gitlab-packages feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
gitlab-releases feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
gitlab-tags feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
glasskube-packages test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
go feat(util): getEnv (#35161) 2025-05-06 18:37:28 +00:00
golang-version test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
gradle-version test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
hackage test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
helm test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
hermit test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
hex test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
hexpm-bob test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
java-version test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
jenkins-plugins test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
kubernetes-api refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
maven refactor(cache): Rename ttlMinutes to softTtlMinutes for clarity (#35892) 2025-05-12 13:21:04 +00:00
node-version test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
npm refactor: Make package caching params explicit (#35815) 2025-05-09 06:08:17 +00:00
nuget feat(util): getEnv (#35161) 2025-05-06 18:37:28 +00:00
orb test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
packagist test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
pod test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
puppet-forge test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
pypi feat(util): getEnv (#35161) 2025-05-06 18:37:28 +00:00
python-version feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
repology feat(config): managerFilePatterns (#34615) 2025-05-04 08:30:24 +00:00
ruby-version test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
rubygems test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
sbt-package test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
sbt-plugin test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
terraform-module test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
terraform-provider test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
unity3d test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
api.ts feat(bitbucket-server): add support for changelogs (#34569) 2025-04-09 09:45:32 +00:00
common.spec.ts test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
common.ts fix: Handle extractVersion with release post-processing (#32540) 2024-11-16 10:32:33 +00:00
datasource.spec.ts test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
datasource.ts fix: improve coverage (#34667) 2025-03-06 17:05:19 +00:00
index.spec.ts feat(datasource/maven)!: use latest and release values as tags (#35515) 2025-04-30 10:51:58 +02:00
index.ts feat(cache): Clean datasource memory cache after fetch (#35713) 2025-05-06 11:28:04 +00:00
metadata-manual.ts test(lib/data): schemas for changelog and source urls (#32151) 2024-10-30 08:19:48 +00:00
metadata.spec.ts fix(changelogs): support massaging self-hosted gitlab URLs (#35258) 2025-04-08 17:38:39 +00:00
metadata.ts fix(changelogs): support massaging self-hosted gitlab URLs (#35258) 2025-04-08 17:38:39 +00:00
postprocess-release.spec.ts feat: Fetch currentVersionTimestamp via datasource postprocess (#35082) 2025-03-31 13:28:28 +00:00
postprocess-release.ts feat: Fetch currentVersionTimestamp via datasource postprocess (#35082) 2025-03-31 13:28:28 +00:00
readme.md test: migrate to vitest (#34475) 2025-02-26 09:35:54 +00:00
schema.ts fix(datasource/cdnjs): update logic to accomodate api changes (#27212) 2024-02-11 10:57:56 +00:00
types.ts feat: Add bumpedAt field (#34794) 2025-04-14 16:18:30 +00:00
util.ts refactor: refactor Google Auth util (#33486) 2025-01-09 10:35:47 +00:00
utils.spec.ts test: cleanup (#34785) 2025-03-13 17:52:09 +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 Unused HTTP mocks errors in the Vitest 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.