mirror of
https://github.com/pnpm/pnpm.git
synced 2026-03-31 05:22:00 -04:00
feat: save 'deprecated' messages in shrinkwrap.yaml
This commit is contained in:
@@ -308,12 +308,12 @@ async function install (
|
||||
throw err
|
||||
}
|
||||
}
|
||||
if (pkg['deprecated']) {
|
||||
if (pkg.deprecated) {
|
||||
deprecationLogger.warn({
|
||||
pkgName: pkg.name,
|
||||
pkgVersion: pkg.version,
|
||||
pkgId: fetchedPkg.id,
|
||||
deprecated: pkg['deprecated'],
|
||||
deprecated: pkg.deprecated,
|
||||
depth: options.currentDepth,
|
||||
})
|
||||
}
|
||||
|
||||
@@ -116,6 +116,9 @@ function toShrDependency (
|
||||
if (pkg.bundledDependencies || pkg.bundleDependencies) {
|
||||
result['bundledDependencies'] = pkg.bundledDependencies || pkg.bundleDependencies
|
||||
}
|
||||
if (pkg.deprecated) {
|
||||
result['deprecated'] = pkg.deprecated
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
|
||||
@@ -166,4 +166,8 @@ export type Package = {
|
||||
},
|
||||
cpu?: string[],
|
||||
os?: string[],
|
||||
// TODO: create a separate type called PackageManifest that will have `deprecated`
|
||||
// and won't have `scripts`, `config` and other fields that are not returned by
|
||||
// the registry
|
||||
deprecated?: string,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user