Skip to content

Commit e6a4168

Browse files
committed
chore(renovate): improve Renovate config for better package grouping and parsing
Refined grouping rules for Config Baker container image dependencies and enhanced regex for version extraction. Adjusted default versioning template to prioritize semantic versioning when unspecified. These changes ensure more accurate and maintainable update tracking.
1 parent d74eb32 commit e6a4168

1 file changed

Lines changed: 5 additions & 6 deletions

File tree

renovate.json5

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,9 @@
2828

2929
packageRules: [
3030
{
31-
description: "Group Alpine Package Manager dependencies for the Config Baker Container Image",
32-
matchFileNames: ["modules/container-configbaker/**/Dockerfile"],
33-
matchDatasources: ["repology"],
34-
groupName: "Config Baker Container - APK packages"
31+
description: "Group package updates for the Config Baker Container Image",
32+
matchFileNames: ["modules/container-configbaker/**/*[dD]ockerfile"],
33+
groupName: "Config Baker Container Packages"
3534
},
3635
],
3736

@@ -44,9 +43,9 @@
4443
"/(^|/)Dockerfile\\.[^/]*$/"
4544
],
4645
matchStrings: [
47-
"#\\s*renovate:\\s*datasource=(?<datasource>.*?) depName=(?<depName>.*?)\\sENV .*?_VERSION=\"(?<currentValue>.*)\"\\s"
46+
"# renovate: datasource=(?<datasource>[a-zA-Z0-9-._]+?) 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"
4847
],
49-
versioningTemplate: "loose"
48+
versioningTemplate: '{{#if versioning}}{{{versioning}}}{{else}}semver{{/if}}'
5049
}
5150
]
5251
}

0 commit comments

Comments
 (0)