npm-pkgbuild 7.22.2 → 7.22.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -62,7 +62,7 @@ export async function extractFromPackage(pkg, dir) {
|
|
|
62
62
|
let output = {};
|
|
63
63
|
let arch = new Set();
|
|
64
64
|
|
|
65
|
-
const processPkg = (pkg, dir) => {
|
|
65
|
+
const processPkg = (pkg, dir, modulePath) => {
|
|
66
66
|
if (pkg.cpu) {
|
|
67
67
|
for (const a of asArray(pkg.cpu)) {
|
|
68
68
|
arch.add(npmArchMapping[a]);
|
|
@@ -84,7 +84,7 @@ export async function extractFromPackage(pkg, dir) {
|
|
|
84
84
|
.filter(([k, v]) => typeof v === "string")
|
|
85
85
|
.forEach(([k, v]) => (properties[k] = v));
|
|
86
86
|
|
|
87
|
-
if (pkgbuild.content) {
|
|
87
|
+
if (pkgbuild.content && !modulePath) {
|
|
88
88
|
Object.entries(pkgbuild.content).forEach(
|
|
89
89
|
([destination, definitions]) => {
|
|
90
90
|
for (const definition of asArray(definitions)) {
|
|
@@ -116,7 +116,7 @@ export async function extractFromPackage(pkg, dir) {
|
|
|
116
116
|
|
|
117
117
|
await packageWalker(async (pkg, base, modulePath) => {
|
|
118
118
|
if (modulePath.length > 0) {
|
|
119
|
-
processPkg(pkg, base);
|
|
119
|
+
processPkg(pkg, base, modulePath);
|
|
120
120
|
}
|
|
121
121
|
return true;
|
|
122
122
|
}, dir);
|