Socket
Socket
Sign inDemoInstall

@lerna/project

Package Overview
Dependencies
Maintainers
2
Versions
76
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@lerna/project - npm Package Compare versions

Comparing version 3.7.2 to 3.8.5

12

CHANGELOG.md

@@ -6,2 +6,14 @@ # Change Log

## [3.8.5](https://github.com/lerna/lerna/compare/v3.8.4...v3.8.5) (2019-01-05)
### Bug Fixes
* **project:** Deprecate root-level config keys as well, prioritizing nested ([7a65a87](https://github.com/lerna/lerna/commit/7a65a87))
* **publish:** Deprecate `--npm-tag`, replaced by `--dist-tag` ([196d663](https://github.com/lerna/lerna/commit/196d663))
## [3.7.2](https://github.com/lerna/lerna/compare/v3.7.1...v3.7.2) (2018-12-21)

@@ -8,0 +20,0 @@

34

lib/deprecate-config.js

@@ -9,3 +9,4 @@ "use strict";

// add new predicates HERE
remap("command.publish.cdVersion", "command.publish.bump"),
remap("command.publish.npmTag", "command.publish.distTag", { alsoRoot: true }),
remap("command.publish.cdVersion", "command.publish.bump", { alsoRoot: true }),
remap("command.publish.ignore", "command.publish.ignoreChanges"),

@@ -21,17 +22,28 @@ remap("commands", "command"),

* @param {String} search Path to deprecated option
* @param {String} replace Path of renamed option
* @param {String} target Path of renamed option
* @param {Object} opts Optional configuration object
* @param {Boolean} opts.alsoRoot Whether to check root config as well
* @return {Function} predicate accepting (config, filepath)
*/
function remap(search, replace) {
function remap(search, target, { alsoRoot } = {}) {
const pathsToSearch = [search];
if (alsoRoot) {
// root config is overwritten by "more specific" nested config
pathsToSearch.unshift(search.split(".").pop());
}
return obj => {
if (dotProp.has(obj.config, search)) {
const localPath = path.relative(".", obj.filepath);
for (const searchPath of pathsToSearch) {
if (dotProp.has(obj.config, searchPath)) {
const localPath = path.relative(".", obj.filepath);
log.warn(
"project",
`Deprecated key "${search}" found in ${localPath}\nPlease rename "${search}" => "${replace}"`
);
log.warn(
"project",
`Deprecated key "${searchPath}" found in ${localPath}\nPlease rename "${searchPath}" => "${target}"`
);
dotProp.set(obj.config, replace, dotProp.get(obj.config, search));
dotProp.delete(obj.config, search);
dotProp.set(obj.config, target, dotProp.get(obj.config, searchPath));
dotProp.delete(obj.config, searchPath);
}
}

@@ -38,0 +50,0 @@

{
"name": "@lerna/project",
"version": "3.7.2",
"version": "3.8.5",
"description": "Lerna project configuration",

@@ -47,3 +47,3 @@ "keywords": [

},
"gitHead": "52796f674ad3f2642270e942e96443437c54ff72"
"gitHead": "9f5c824b2f15119c10003dcc709f3ca0da99a5fe"
}

@@ -16,2 +16,3 @@ # `@lerna/project`

```
```json

@@ -18,0 +19,0 @@ {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc