renovate/lib/manager/npm/index.ts
Rhys Arkins 98d55394e6
feat: transitiveRemediation (#8883)
* save remediations

* enhance and export NpmResponse

* sort branch lists

* transitive remediation init

* update-lockfile not bump

* version not value

* remediate package.json

* isVulnerabilityAlert

* simplify config

* fix circular

* update snapshots

* add config and docs

* TODO

* flatten tests

* remediation -> update

* lots of renames

* improve readability

* refactor

* remove fetch

* more tests

* reduce fiixtures sizes

* more tests

* fix parent null

* remove exec

* explicit false

* fix

* Apply suggestions from code review

Co-authored-by: Michael Kriese <michael.kriese@visualon.de>

* use type-fest PackageJson

* more tests

* coverage

* Update lib/workers/branch/get-updated.ts

Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
2021-03-01 07:59:57 +00:00

23 lines
883 B
TypeScript

import { LANGUAGE_JAVASCRIPT } from '../../constants/languages';
import * as npmVersioning from '../../versioning/npm';
export { extractAllPackageFiles } from './extract';
export {
bumpPackageVersion,
updateDependency,
updateLockedDependency,
} from './update';
export { getRangeStrategy } from './range';
export const language = LANGUAGE_JAVASCRIPT;
export const supportsLockFileMaintenance = true;
export const defaultConfig = {
fileMatch: ['(^|/)package.json$'],
rollbackPrs: true,
versioning: npmVersioning.id,
prBodyDefinitions: {
Change:
"[{{#if displayFrom}}`{{{displayFrom}}}` -> {{else}}{{#if currentValue}}`{{{currentValue}}}` -> {{/if}}{{/if}}{{#if displayTo}}`{{{displayTo}}}`{{else}}`{{{newValue}}}`{{/if}}]({{#if depName}}https://renovatebot.com/diffs/npm/{{replace '/' '%2f' depName}}/{{{currentVersion}}}/{{{newVersion}}}{{/if}})",
},
};