Skip to content

Commit

Permalink
chore(renovate): migrate matchDepPatterns deprecated syntax and minor…
Browse files Browse the repository at this point in the history
… polish

see #74
  • Loading branch information
o-orand committed Aug 19, 2024
1 parent 504a281 commit 4e553fd
Showing 1 changed file with 31 additions and 26 deletions.
57 changes: 31 additions & 26 deletions renovate.json5
Original file line number Diff line number Diff line change
Expand Up @@ -6,79 +6,84 @@
'github>orange-cloudfoundry/renovate-public-presets:boshreleases-default.json5'
],
enabledManagers: [
"github-actions",
"vendir",
"custom.regex"
'github-actions',
'vendir',
'custom.regex',
],
ignorePaths: [
'packages/**',
'releases/**',
'manifests/**',
'jobs/**'
'jobs/**',
],
baseBranches: [
// don't run on renovate branches
"$default"
'$default',
// See https://docs.renovatebot.com/configuration-options/#basebranches
// baseBranches supports Regular Expressions that must begin and end with /
], //See also possible support for multiple base branches, one per K8S minor version https://docs.renovatebot.com/configuration-options/#basebranches
packageRules: [
{
description: "Add common labels",
matchDepPatterns: ["*"],
description: 'Add common labels',
addLabels: [
// See full list of fields available at https://docs.renovatebot.com/templates/#other-available-fields
"datasource/{{datasource}}",
"depName/{{depNameSanitized}}",
"manager/{{manager}}"
]
'datasource/{{datasource}}',
'depName/{{depNameSanitized}}',
'manager/{{manager}}',
],
matchDepNames: [
'/*/',
],
},
{
description: 'Auto-merge patch releases, e.g. from 1.28.1 to 1.28.2',
matchPackageNames: [
'kubernetes/kubernetes',
'orange-cloudfoundry/create-bosh-release-action'
'orange-cloudfoundry/create-bosh-release-action',
],
//see https://docs.renovatebot.com/key-concepts/automerge/#automerge-non-major-updates
matchUpdateTypes: [
'patch'
'patch',
],
matchCurrentVersion: '!/-rc/',
automerge: true,
//see https://docs.renovatebot.com/key-concepts/automerge/#absence-of-tests
ignoreTests: true
ignoreTests: true,
},
{
description: 'Kubectl: Get distinct branches for each minor, e.g. 1.28.x and 1.29.x. See https://docs.renovatebot.com/presets-default/#separatepatchreleases and https://docs.renovatebot.com/faq/#separate-patch-releases-from-minor-releases',
matchPackageNames: [
'kubernetes/kubernetes'
'kubernetes/kubernetes',
],
separateMinorPatch: true,
addLabels: [
'depName/kubernetes-kubectl' //override common labels for kubectl, as we have to scan kubernetes releases
'depName/kubernetes-kubectl', //override common labels for kubectl, as we have to scan kubernetes releases
],
separateMultipleMinor: true // https://github.com/renovatebot/renovate/pull/24538 is effective
separateMultipleMinor: true, // https://github.com/renovatebot/renovate/pull/24538 is effective
},
{
description: 'Use to bump CLIs managed by jaxxstorm/action-install-gh-release',
matchFileNames: [ '.github/workflows/*.yml'],
matchFileNames: [
'.github/workflows/*.yml',
],
matchManagers: 'custom.regex',
addLabels: [
'cli-managed-by-jaxxstorm'
]
}
'cli-managed-by-jaxxstorm',
],
},
],
customManagers: [
{
description: 'Use to bump CLIs managed by jaxxstorm/action-install-gh-release',
customType: "regex",
fileMatch: [ '\.github/workflows/.+\.yml$'],
customType: 'regex',
fileMatch: [
'.github/workflows/.+.yml$',
],
matchStrings: [
// https://regex101.com/r/Hajw59/2
' +uses: jaxxstorm\\/action-install-gh-release.*\\n.*\\n +repo: (?<depName>[a-z0-9\\.\\/\\-]*?)\\n +tag: (?<currentValue>[a-z0-9\\.\\/\\-\\+]*?) *\\n',
],
datasourceTemplate: 'github-releases',

}
]
},
],
}

0 comments on commit 4e553fd

Please sign in to comment.