You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

@monorepo-utils/package-utils

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@monorepo-utils/package-utils - npm Package Compare versions

Comparing version
2.8.1
to
2.9.0
+9
-0
lib/get-packages.js

@@ -10,2 +10,3 @@ "use strict";

var fs = require("fs");
var yaml = require("yaml");
var loadPackage = function (packagePath) {

@@ -66,2 +67,10 @@ var pkgJsonPath = path.join(packagePath, "package.json");

}
var pnpmYamlPath = path.join(rootDirectory, "pnpm-workspace.yaml");
if (fs.existsSync(pnpmYamlPath)) {
var contents = fs.readFileSync(pnpmYamlPath, "utf8");
var pnpmConfig = yaml.parse(contents);
if ("packages" in pnpmConfig && Array.isArray(pnpmConfig.packages)) {
return (0, exports.findPackages)(pnpmConfig.packages, rootDirectory);
}
}
// Bail if we don't find any packages

@@ -68,0 +77,0 @@ return [];

+4
-3
{
"name": "@monorepo-utils/package-utils",
"version": "2.8.1",
"version": "2.9.0",
"description": "Package utility for monorepo.",

@@ -66,3 +66,4 @@ "keywords": [

"load-json-file": "^6.2.0",
"upath": "^2.0.1"
"upath": "^2.0.1",
"yaml": "^2.1.3"
},

@@ -83,3 +84,3 @@ "devDependencies": {

},
"gitHead": "1d2dedf099ee79cf02fd80feeb4d3ff22aa4eeba"
"gitHead": "77d7d3a5daf5a67dbc8de45017b8898100945b16"
}

@@ -8,2 +8,3 @@ "use strict";

import * as fs from "fs";
import * as yaml from "yaml";

@@ -78,4 +79,14 @@ const loadPackage = (packagePath: string): object => {

const pnpmYamlPath = path.join(rootDirectory, "pnpm-workspace.yaml");
if (fs.existsSync(pnpmYamlPath)) {
const contents = fs.readFileSync(pnpmYamlPath, "utf8");
const pnpmConfig = yaml.parse(contents);
if ("packages" in pnpmConfig && Array.isArray(pnpmConfig.packages)) {
return findPackages(pnpmConfig.packages, rootDirectory);
}
}
// Bail if we don't find any packages
return [];
};

Sorry, the diff of this file is not supported yet