From 1055ed797a0275f2a2344806530268a670181d56 Mon Sep 17 00:00:00 2001 From: Dave Shanley Date: Tue, 19 Jul 2022 11:26:19 -0400 Subject: [PATCH] Modified NPM install after testing Signed-off-by: Dave Shanley --- npm-install/config.js | 10 +++++----- npm-install/postinstall.js | 2 ++ package-lock.json | 20 +++----------------- package.json | 5 ++--- 4 files changed, 12 insertions(+), 25 deletions(-) diff --git a/npm-install/config.js b/npm-install/config.js index f1f03656..01247755 100644 --- a/npm-install/config.js +++ b/npm-install/config.js @@ -4,12 +4,12 @@ export const CONFIG = { url: "https://github.com/daveshanley/vacuum/releases/download/v{{version}}/{{bin_name}}_{{version}}_{{platform}}_{{arch}}.tar.gz", }; export const ARCH_MAPPING = { - ia32: "386", - x64: "amd64", + ia32: "i386", + x64: "x86_64", arm64: "arm64", }; export const PLATFORM_MAPPING = { - darwin: "darwin", - linux: "linux", - win32: "windows", + darwin: "Darwin", + linux: "Linux", + win32: "Windows", }; \ No newline at end of file diff --git a/npm-install/postinstall.js b/npm-install/postinstall.js index 62ac2095..a1bb1baa 100644 --- a/npm-install/postinstall.js +++ b/npm-install/postinstall.js @@ -32,6 +32,8 @@ async function install() { url = url.replace(/{{version}}/g, version); url = url.replace(/{{bin_name}}/g, binName); + + console.log('fetching from URL', url) const response = await fetch(url); if (!response.ok) { throw new Error("Failed fetching the binary: " + response.statusText); diff --git a/package-lock.json b/package-lock.json index 644ba905..753d3eca 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,18 +1,17 @@ { - "name": "vacuum", + "name": "@quobix/vacuum", "version": "0.0.12", "lockfileVersion": 2, "requires": true, "packages": { "": { - "name": "vacuum", + "name": "@quobix/vacuum", "version": "0.0.12", "hasInstallScript": true, "license": "MIT", "dependencies": { "node-fetch": "^3.1.0", - "tar": "^6.1.11", - "vacuum": "^0.1.3" + "tar": "^6.1.11" }, "bin": { "vacuum": "bin/vacuum.js" @@ -166,14 +165,6 @@ "node": ">= 10" } }, - "node_modules/vacuum": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/vacuum/-/vacuum-0.1.3.tgz", - "integrity": "sha512-rSmcte8bqlXGIJ+F+c00SYzVQ9e4Wgjeu2T4AiphGEhcIygNbVuvdAQHocmbGDsd1bkQ2qTiEuoVzitvxF3yAw==", - "engines": { - "node": "*" - } - }, "node_modules/web-streams-polyfill": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/web-streams-polyfill/-/web-streams-polyfill-3.2.1.tgz", @@ -274,11 +265,6 @@ "yallist": "^4.0.0" } }, - "vacuum": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/vacuum/-/vacuum-0.1.3.tgz", - "integrity": "sha512-rSmcte8bqlXGIJ+F+c00SYzVQ9e4Wgjeu2T4AiphGEhcIygNbVuvdAQHocmbGDsd1bkQ2qTiEuoVzitvxF3yAw==" - }, "web-streams-polyfill": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/web-streams-polyfill/-/web-streams-polyfill-3.2.1.tgz", diff --git a/package.json b/package.json index 5bc93ad3..148016ef 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@quobix/vacuum", - "version": "0.0.12", + "version": "0.0.13", "description": "The world's fastest, most scalable and complete OpenAPI parser", "type": "module", "author": "Dave Shanley", @@ -24,8 +24,7 @@ ], "dependencies": { "node-fetch": "^3.1.0", - "tar": "^6.1.11", - "vacuum": "^0.1.3" + "tar": "^6.1.11" }, "bugs": { "url": "https://github.com/daveshanley/vacuum/issues"