nginx-binaries
Version:
A downloader for nginx and njs standalone binaries.
22 lines • 575 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.normalizeArch = void 0;
const OS = require("node:os");
const mapping = {
arm: 'armv7',
arm64: 'aarch64',
x32: 'x86',
x64: 'x86_64',
};
/**
* Normalizes the given architecture name to an Alpine architecture name or
* macOS architecture name.
*/
function normalizeArch(arch) {
if (arch === 'arm64' && OS.platform() === 'darwin') {
return arch;
}
return mapping[arch] || arch;
}
exports.normalizeArch = normalizeArch;
//# sourceMappingURL=archName.js.map