Skip to content

Commit 8913212

Browse files
alan-agius4devversion
authored andcommitted
ci: require manual approval for NPM updates on non-main branches
Previously, NPM updates were entirely disabled on branches other than main. This change modifies the Renovate configuration to require manual approval for these updates instead of disabling them. This allows for important bug fixes to be manually selected while preventing automatic updates. Additionally, the rule that groups all non-major dependencies for updates has been updated to explicitly apply only to the main branch.
1 parent 7fa1ab5 commit 8913212

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

renovate-presets/default.json5

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,13 +56,15 @@
5656
matchManagers: ['bazel', 'bazel-module', 'bazelisk'],
5757
},
5858

59-
// Rule to disable NPM updates on branches other than 'main'.
60-
// But allow updating engines and packageManagers.
59+
// Rule to require manual approval for NPM updates on branches other than 'main'.
60+
// This is to prevent auto updates to branches that are not the main branch.
61+
// But, still allows the updates to be manually selected in case of an important bug fix.
62+
// Engines and packageManagers are excluded from this rule.
6163
{
62-
enabled: false,
6364
matchBaseBranches: ['!main'],
64-
matchDepNames: ['!node', '!pnpm', '!npm', '!yarn'],
65+
matchDepNames: ['*', '!node', '!pnpm', '!npm', '!yarn'],
6566
matchManagers: ['npm'],
67+
dependencyDashboardApproval: true,
6668
},
6769

6870
// Group all non-major dependencies together for updates.
@@ -71,6 +73,7 @@
7173
matchDepNames: ['*', '!node', '!pnpm', '!npm', '!yarn'],
7274
matchUpdateTypes: ['digest', 'patch', 'minor'],
7375
matchManagers: ['npm'],
76+
matchBaseBranches: ['main'],
7477
},
7578

7679
// ============================================================================

0 commit comments

Comments
 (0)