From eceab5e6494ec2a4b01dad49bf127644cd627d25 Mon Sep 17 00:00:00 2001 From: cenfun Date: Sun, 5 Mar 2023 11:41:33 +0800 Subject: [PATCH] 4.0.1 --- CHANGELOG.md | 3 +++ lib/index.js | 9 ++++++--- package.json | 4 ++-- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d64db78..568d278 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # Changelog +* 4.0.1 + * fixed peerDependencies + * 4.0.0 * refactor diff --git a/lib/index.js b/lib/index.js index 61a34c1..cbe5f37 100644 --- a/lib/index.js +++ b/lib/index.js @@ -81,8 +81,11 @@ class NMLS { // module subs infoList.forEach((moduleInfo) => { - // dependencies group - const groups = this.getModuleGroups(moduleInfo); + // dependencies group, add dev for link + const groups = this.getModuleGroups(moduleInfo, moduleInfo.isLink); + if (moduleInfo.isLink && !this.options.prod) { + Util.log(`[nmls] "${EC.yellow(moduleInfo.name)}" is a symbolic link, only calculate prod dependencies`); + } if (groups) { groups.forEach((group) => { @@ -194,7 +197,7 @@ class NMLS { } const packagesInfo = { - name: 'packages', + name: 'packages in workspaces', version: '', size: '', files: '', diff --git a/package.json b/package.json index 4422740..73bd4cf 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "nmls", - "version": "4.0.0", + "version": "4.0.1", "description": "An analysis tool to Node Modules List", "main": "./lib/index.js", "bin": { @@ -29,4 +29,4 @@ "eslint": "^8.35.0", "eslint-config-plus": "^1.0.6" } -} +} \ No newline at end of file