mirror of https://github.com/renovatebot/renovate
136 lines
5.4 KiB
TypeScript
136 lines
5.4 KiB
TypeScript
import type { Preset } from '../types';
|
|
|
|
/* eslint sort-keys: ["error", "asc", {caseSensitive: false, natural: true}] */
|
|
|
|
export const presets: Record<string, Preset> = {
|
|
biomeVersions: {
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
datasourceTemplate: 'npm',
|
|
depNameTemplate: '@biomejs/biome',
|
|
fileMatch: ['(^|/)biome.jsonc?$'],
|
|
matchStrings: [
|
|
'"https://biomejs.dev/schemas/(?<currentValue>[^"]+)/schema.json"',
|
|
],
|
|
},
|
|
],
|
|
description:
|
|
'Update `$schema` version in `biome.json` configuration files.',
|
|
},
|
|
bitbucketPipelinesVersions: {
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
fileMatch: ['(^|/)bitbucket-pipelines\\.ya?ml$'],
|
|
matchStrings: [
|
|
'# renovate: datasource=(?<datasource>[a-z-.]+?) depName=(?<depName>[^\\s]+?)(?: (lookupName|packageName)=(?<packageName>[^\\s]+?))?(?: versioning=(?<versioning>[^\\s]+?))?(?: extractVersion=(?<extractVersion>[^\\s]+?))?(?: registryUrl=(?<registryUrl>[^\\s]+?))?\\s+.*\\s+[A-Za-z0-9_]+?_VERSION[ =:]\\s?["\']?(?<currentValue>.+?)["\']?\\s',
|
|
],
|
|
},
|
|
],
|
|
description: 'Update `_VERSION` variables in Bitbucket Pipelines',
|
|
},
|
|
dockerfileVersions: {
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
fileMatch: [
|
|
'(^|/|\\.)([Dd]ocker|[Cc]ontainer)file$',
|
|
'(^|/)([Dd]ocker|[Cc]ontainer)file[^/]*$',
|
|
],
|
|
matchStrings: [
|
|
'# renovate: datasource=(?<datasource>[a-z-.]+?) depName=(?<depName>[^\\s]+?)(?: (lookupName|packageName)=(?<packageName>[^\\s]+?))?(?: versioning=(?<versioning>[^\\s]+?))?(?: extractVersion=(?<extractVersion>[^\\s]+?))?(?: registryUrl=(?<registryUrl>[^\\s]+?))?\\s(?:ENV|ARG)\\s+[A-Za-z0-9_]+?_VERSION[ =]["\']?(?<currentValue>.+?)["\']?\\s',
|
|
],
|
|
},
|
|
],
|
|
description: 'Update `_VERSION` variables in Dockerfiles.',
|
|
},
|
|
githubActionsVersions: {
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
fileMatch: [
|
|
'(^|/)(workflow-templates|\\.(?:github|gitea|forgejo)/(?:workflows|actions))/.+\\.ya?ml$',
|
|
'(^|/)action\\.ya?ml$',
|
|
],
|
|
matchStrings: [
|
|
'# renovate: datasource=(?<datasource>[a-z-.]+?) depName=(?<depName>[^\\s]+?)(?: (?:lookupName|packageName)=(?<packageName>[^\\s]+?))?(?: versioning=(?<versioning>[^\\s]+?))?(?: extractVersion=(?<extractVersion>[^\\s]+?))?\\s+[A-Za-z0-9_]+?_VERSION\\s*:\\s*["\']?(?<currentValue>.+?)["\']?\\s',
|
|
],
|
|
},
|
|
],
|
|
description:
|
|
'Update `_VERSION` environment variables in GitHub Action files.',
|
|
},
|
|
gitlabPipelineVersions: {
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
fileMatch: ['\\.gitlab-ci\\.ya?ml$'],
|
|
matchStrings: [
|
|
'# renovate: datasource=(?<datasource>[a-z-.]+?) depName=(?<depName>[^\\s]+?)(?: (?:packageName)=(?<packageName>[^\\s]+?))?(?: versioning=(?<versioning>[^\\s]+?))?(?: extractVersion=(?<extractVersion>[^\\s]+?))?(?: registryUrl=(?<registryUrl>[^\\s]+?))?\\s+[A-Za-z0-9_]+?_VERSION\\s*:\\s*["\']?(?<currentValue>.+?)["\']?\\s',
|
|
],
|
|
},
|
|
],
|
|
description:
|
|
'Update `_VERSION` environment variables in GitLab pipeline file.',
|
|
},
|
|
helmChartYamlAppVersions: {
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
datasourceTemplate: 'docker',
|
|
fileMatch: ['(^|/)Chart\\.yaml$'],
|
|
matchStrings: [
|
|
'#\\s*renovate: image=(?<depName>.*?)\\s+appVersion:\\s*["\']?(?<currentValue>[\\w+\\.\\-]*)',
|
|
],
|
|
},
|
|
],
|
|
description: 'Update `appVersion` value in Helm chart `Chart.yaml`.',
|
|
},
|
|
makefileVersions: {
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
fileMatch: [
|
|
'(^|/)Makefile$',
|
|
'(^|/)makefile$',
|
|
'(^|/)GNUMakefile$',
|
|
'\\.mk$',
|
|
],
|
|
matchStrings: [
|
|
'# renovate: datasource=(?<datasource>[a-z-.]+?) depName=(?<depName>[^\\s]+?)(?: (?:packageName)=(?<packageName>[^\\s]+?))?(?: versioning=(?<versioning>[^\\s]+?))?(?: extractVersion=(?<extractVersion>[^\\s]+?))?(?: registryUrl=(?<registryUrl>[^\\s]+?))?\\s+[A-Za-z0-9_]+?_VERSION\\s*:*\\??=\\s*["\']?(?<currentValue>.+?)["\']?\\s',
|
|
],
|
|
},
|
|
],
|
|
description: 'Update `_VERSION` variables in Makefiles.',
|
|
},
|
|
mavenPropertyVersions: {
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
datasourceTemplate:
|
|
'{{#if datasource}}{{{datasource}}}{{else}}maven{{/if}}',
|
|
fileMatch: ['(^|/)pom\\.xml$'],
|
|
matchStrings: [
|
|
'<!--\\s?renovate:( datasource=(?<datasource>[a-z-.]+?))? depName=(?<depName>[^\\s]+?)(?: packageName=(?<packageName>[^\\s]+?))?(?: versioning=(?<versioning>[^\\s]+?))?(?: extractVersion=(?<extractVersion>[^\\s]+?))?\\s+-->\\s+<.+\\.version>(?<currentValue>.+)<\\/.+\\.version>',
|
|
],
|
|
versioningTemplate: '{{#if versioning}}{{{versioning}}}{{/if}}',
|
|
},
|
|
],
|
|
description: 'Update `*.version` properties in `pom.xml` files.',
|
|
},
|
|
tfvarsVersions: {
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
fileMatch: ['.+\\.tfvars$'],
|
|
matchStrings: [
|
|
'#\\s*renovate: datasource=(?<datasource>.*?) depName=(?<depName>.*?)( versioning=(?<versioning>.*?))?(?: extractVersion=(?<extractVersion>.*?))?\\s.*?_version\\s*=\\s*"(?<currentValue>.*)"',
|
|
],
|
|
versioningTemplate: '{{#if versioning}}{{{versioning}}}{{/if}}',
|
|
},
|
|
],
|
|
description: 'Update `*_version` variables in `.tfvars` files.',
|
|
},
|
|
};
|