Latest Threat Research:SANDWORM_MODE: Shai-Hulud-Style npm Worm Hijacks CI Workflows and Poisons AI Toolchains.Details
Socket
Book a DemoInstallSign in
Socket

napi-postinstall

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

napi-postinstall - npm Package Compare versions

Comparing version
0.3.3
to
0.3.4
+24
-1
lib/helpers.js

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

if (process.arch === 'x64') {
return 'win32-x64-msvc';
const targets = [];
if (process.report.getReport().header?.osName?.startsWith('MINGW')) {
targets.push('win32-x64-gnu');
}
targets.push('win32-x64-msvc');
return targets;
}

@@ -198,2 +203,8 @@ if (process.arch === 'ia32') {

}
if (process.arch === 'loong64') {
if (isMusl()) {
return 'linux-loong64-musl';
}
return 'linux-loong64-gnu';
}
if (process.arch === 'riscv64') {

@@ -213,2 +224,14 @@ if (isMusl()) {

}
case 'openharmony': {
if (process.arch === 'arm64') {
return 'openharmony-arm64';
}
if (process.arch === 'x64') {
return 'openharmony-x64';
}
if (process.arch === 'arm') {
return 'openharmony-arm';
}
break;
}
}

@@ -215,0 +238,0 @@ return [];

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

armv7: 'arm',
loongarch64: 'loong64',
riscv64gc: 'riscv64',

@@ -19,3 +20,5 @@ powerpc64le: 'ppc64',

windows: 'win32',
ohos: 'openharmony',
};
const SUB_SYSTEMS = new Set(['android', 'ohos']);
function parseTriple(rawTriple) {

@@ -48,2 +51,6 @@ if (rawTriple === constants_js_1.WASM32_WASI ||

}
if (abi && SUB_SYSTEMS.has(abi)) {
sys = abi;
abi = null;
}
const platform = SysToNodePlatform[sys] ?? sys;

@@ -50,0 +57,0 @@ const arch = CpuToNodeArch[cpu] ?? cpu;

+1
-1

@@ -29,3 +29,3 @@ export interface Napi {

}
export type Platform = NodeJS.Platform | 'wasi' | 'wasm';
export type Platform = NodeJS.Platform | 'openharmony' | 'wasi' | 'wasm';
export type NodeJSArch = NodeJS.Architecture | 'universal' | 'wasm32' | 'x32';

@@ -32,0 +32,0 @@ export interface Target {

{
"name": "napi-postinstall",
"version": "0.3.3",
"version": "0.3.4",
"type": "commonjs",

@@ -5,0 +5,0 @@ "description": "The `postinstall` script helper for handling native bindings in legacy `npm` versions",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet