package-manager-manager
Advanced tools
Comparing version 0.1.0 to 0.1.1-55062d6
{ | ||
"name": "package-manager-manager", | ||
"version": "0.1.0", | ||
"version": "0.1.1-55062d6", | ||
"description": "Utilities for managing package managers.", | ||
@@ -54,2 +54,5 @@ "license": "MIT", | ||
}, | ||
"versionMetadata": { | ||
"type": "BETA" | ||
}, | ||
"scripts": { | ||
@@ -56,0 +59,0 @@ "build": "vite build", |
@@ -1,9 +0,10 @@ | ||
import e from "shellac"; | ||
function s(o) { | ||
import s from "shellac"; | ||
function u(e) { | ||
return async (...[n]) => { | ||
var t, o; | ||
try { | ||
const t = JSON.parse( | ||
(await e`$ ${o} list --depth=0 --json`).stdout | ||
), r = (o === "npm" ? t : t[0]).dependencies[n]; | ||
return r ? { name: n, version: r.version } : null; | ||
const r = JSON.parse( | ||
(await s`$ ${e} list --depth=0 --json`).stdout | ||
), c = e === "npm" ? r : r[0], i = ((t = c.dependencies) == null ? void 0 : t[n]) ?? ((o = c.devDependencies) == null ? void 0 : o[n]); | ||
return i ? { name: n, version: i.version } : null; | ||
} catch { | ||
@@ -15,4 +16,4 @@ throw new Error(`An error occurred while gathering the package info of "${n}"`); | ||
export { | ||
s as getNpmOrPnpmGetPackageInfoFunction | ||
u as getNpmOrPnpmGetPackageInfoFunction | ||
}; | ||
//# sourceMappingURL=shared.js.map |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
125154
919
0