mirror of
https://github.com/renovatebot/renovate.git
synced 2025-01-12 06:56:24 +00:00
feat: workarounds presets (#7695)
This commit is contained in:
parent
5118ae9956
commit
e0bf8814ac
4 changed files with 24 additions and 0 deletions
|
@ -95,6 +95,7 @@ export function parsePreset(input: string): ParsedPreset {
|
||||||
'packages',
|
'packages',
|
||||||
'preview',
|
'preview',
|
||||||
'schedule',
|
'schedule',
|
||||||
|
'workarounds',
|
||||||
];
|
];
|
||||||
if (
|
if (
|
||||||
presetsPackages.some((presetPackage) => str.startsWith(`${presetPackage}:`))
|
presetsPackages.some((presetPackage) => str.startsWith(`${presetPackage}:`))
|
||||||
|
|
|
@ -18,6 +18,7 @@ export const presets: Record<string, Preset> = {
|
||||||
'group:monorepos',
|
'group:monorepos',
|
||||||
'group:recommended',
|
'group:recommended',
|
||||||
'helpers:disableTypesNodeMajor',
|
'helpers:disableTypesNodeMajor',
|
||||||
|
'workarounds:all',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
'base-js': {
|
'base-js': {
|
||||||
|
|
|
@ -8,6 +8,7 @@ import * as monorepoPreset from './monorepo';
|
||||||
import * as packagesPreset from './packages';
|
import * as packagesPreset from './packages';
|
||||||
import * as previewPreset from './preview';
|
import * as previewPreset from './preview';
|
||||||
import * as schedulePreset from './schedule';
|
import * as schedulePreset from './schedule';
|
||||||
|
import * as workaroundsPreset from './workarounds';
|
||||||
|
|
||||||
export const groups: Record<string, Record<string, Preset>> = {
|
export const groups: Record<string, Record<string, Preset>> = {
|
||||||
config: configPreset.presets,
|
config: configPreset.presets,
|
||||||
|
@ -19,6 +20,7 @@ export const groups: Record<string, Record<string, Preset>> = {
|
||||||
packages: packagesPreset.presets,
|
packages: packagesPreset.presets,
|
||||||
preview: previewPreset.presets,
|
preview: previewPreset.presets,
|
||||||
schedule: schedulePreset.presets,
|
schedule: schedulePreset.presets,
|
||||||
|
workarounds: workaroundsPreset.presets,
|
||||||
};
|
};
|
||||||
|
|
||||||
export function getPreset({
|
export function getPreset({
|
||||||
|
|
20
lib/config/presets/internal/workarounds.ts
Normal file
20
lib/config/presets/internal/workarounds.ts
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
import { Preset } from '../common';
|
||||||
|
|
||||||
|
export const presets: Record<string, Preset> = {
|
||||||
|
all: {
|
||||||
|
description: [
|
||||||
|
'A collection of workarounds for known problems with packages',
|
||||||
|
],
|
||||||
|
extends: ['workarounds:unstableV2SetupNodeActions'],
|
||||||
|
},
|
||||||
|
unstableV2SetupNodeActions: {
|
||||||
|
description: 'Ignore wrongly tagged actions/setup-node v2 releases',
|
||||||
|
packageRules: [
|
||||||
|
{
|
||||||
|
datasources: ['github-tags', 'github-releases'],
|
||||||
|
packageNames: ['actions/setup-node'],
|
||||||
|
allowedVersions: '<2.1.1 || > 2.1.1',
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
};
|
Loading…
Reference in a new issue