From 22dec522e32b80381b96c12ecd89c3c48a2c8fd4 Mon Sep 17 00:00:00 2001 From: Jeremiah Gowdy Date: Wed, 4 Oct 2023 10:46:07 -0700 Subject: [PATCH 1/5] Attempt to fix package.json --- package.json | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 57d1b63..bb825d0 100644 --- a/package.json +++ b/package.json @@ -2,15 +2,14 @@ "name": "asherah", "version": "0.0.0", "description": "Asherah envelope encryption and key rotation library", - "main": "dist/asherah.js", + "main": "dist/asherah", "repository": { "type": "git", "url": "https://github.com/jgowdy/asherah-cobhan.git" }, "scripts": { - "build": "node-gyp build && mkdir -p dist/ && cp build/Release/asherah.node dist/asherah.node && cp src/asherah.d.ts dist/asherah.d.ts", "preinstall": "scripts/download-libraries.sh", - "install": "CFLAGS=-fexceptions CXXFLAGS=-fexceptions node-gyp rebuild", + "install": "node-gyp configure && node-gyp build && mkdir -p dist/ && cp build/Release/asherah.node dist/asherah.node && cp src/asherah.d.ts dist/asherah.d.ts", "test:mocha": "mocha", "test": "nyc npm run test:mocha", "posttest": "npm run lint", From f873bc47a71bbfb71a1522fd9c6a94cbecd48b9c Mon Sep 17 00:00:00 2001 From: Jeremiah Gowdy Date: Wed, 4 Oct 2023 10:56:11 -0700 Subject: [PATCH 2/5] Fix GitHub Actions --- .github/workflows/publish.yml | 4 +--- .github/workflows/test.yml | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 1139828..8ee3eae 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -14,9 +14,7 @@ jobs: steps: - uses: actions/checkout@v2 - name: Install packages - run: npm i - - name: Build - run: npm run build + run: npm install - name: Test run: npm test - name: Set version to match tag diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e619358..c678300 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -31,9 +31,7 @@ jobs: steps: - uses: actions/checkout@v2 - name: Install npm packages - run: npm i - - name: Build TypeScript - run: npm run build + run: npm install - name: Unit Test run: npm test - name: Initialize RDBMS based metastore From 059771f5bf7d5c9b365d912ab45fd67251c7a493 Mon Sep 17 00:00:00 2001 From: Jeremiah Gowdy Date: Wed, 4 Oct 2023 11:30:22 -0700 Subject: [PATCH 3/5] Set main to dist/asherah.node --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index bb825d0..3b60e0a 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "asherah", "version": "0.0.0", "description": "Asherah envelope encryption and key rotation library", - "main": "dist/asherah", + "main": "dist/asherah.node", "repository": { "type": "git", "url": "https://github.com/jgowdy/asherah-cobhan.git" From ccbce66a816bea7ffe5dfe0043948c99d31a9ba8 Mon Sep 17 00:00:00 2001 From: Jeremiah Gowdy Date: Wed, 4 Oct 2023 11:39:58 -0700 Subject: [PATCH 4/5] Add stub --- package.json | 5 +++-- src/asherah.js | 0 2 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 src/asherah.js diff --git a/package.json b/package.json index 3b60e0a..7e1bada 100644 --- a/package.json +++ b/package.json @@ -2,14 +2,14 @@ "name": "asherah", "version": "0.0.0", "description": "Asherah envelope encryption and key rotation library", - "main": "dist/asherah.node", + "main": "dist/asherah.js", "repository": { "type": "git", "url": "https://github.com/jgowdy/asherah-cobhan.git" }, "scripts": { "preinstall": "scripts/download-libraries.sh", - "install": "node-gyp configure && node-gyp build && mkdir -p dist/ && cp build/Release/asherah.node dist/asherah.node && cp src/asherah.d.ts dist/asherah.d.ts", + "install": "node-gyp configure && node-gyp build && mkdir -p dist/ && cp build/Release/asherah.node dist/asherah.node && cp src/asherah.d.ts dist/asherah.d.ts && cp src/asherah.js dist/asherah.js", "test:mocha": "mocha", "test": "nyc npm run test:mocha", "posttest": "npm run lint", @@ -22,6 +22,7 @@ "binding.gyp", "src/asherah.cc", "dist/asherah.d.ts", + "dist/asherah.js", "scripts/download-libraries.sh", "SHA256SUMS", "SHA256SUMS-darwin", diff --git a/src/asherah.js b/src/asherah.js new file mode 100644 index 0000000..e69de29 From 3f94411b0a57d8e55ebe4b5e2971bd3d5dc5fc88 Mon Sep 17 00:00:00 2001 From: Jeremiah Gowdy Date: Wed, 4 Oct 2023 11:43:30 -0700 Subject: [PATCH 5/5] Avoid conflicting with asherah.node name --- package.json | 6 +++--- src/{asherah.js => main.js} | 0 2 files changed, 3 insertions(+), 3 deletions(-) rename src/{asherah.js => main.js} (100%) diff --git a/package.json b/package.json index 7e1bada..430cf5f 100644 --- a/package.json +++ b/package.json @@ -2,14 +2,14 @@ "name": "asherah", "version": "0.0.0", "description": "Asherah envelope encryption and key rotation library", - "main": "dist/asherah.js", + "main": "dist/main.js", "repository": { "type": "git", "url": "https://github.com/jgowdy/asherah-cobhan.git" }, "scripts": { "preinstall": "scripts/download-libraries.sh", - "install": "node-gyp configure && node-gyp build && mkdir -p dist/ && cp build/Release/asherah.node dist/asherah.node && cp src/asherah.d.ts dist/asherah.d.ts && cp src/asherah.js dist/asherah.js", + "install": "node-gyp configure && node-gyp build && mkdir -p dist/ && cp build/Release/asherah.node dist/asherah.node && cp src/asherah.d.ts dist/asherah.d.ts && cp src/main.js dist/main.js", "test:mocha": "mocha", "test": "nyc npm run test:mocha", "posttest": "npm run lint", @@ -22,7 +22,7 @@ "binding.gyp", "src/asherah.cc", "dist/asherah.d.ts", - "dist/asherah.js", + "dist/main.js", "scripts/download-libraries.sh", "SHA256SUMS", "SHA256SUMS-darwin", diff --git a/src/asherah.js b/src/main.js similarity index 100% rename from src/asherah.js rename to src/main.js