From c88d547ea8689499b33e73e8e06bc7f634ddcd23 Mon Sep 17 00:00:00 2001 From: Jason Kulatunga Date: Wed, 29 May 2024 23:38:50 -0700 Subject: [PATCH] trying to fix npm publish --- .github/workflows/release.yaml | 13 ++++++++----- Makefile | 3 --- js/package.json | 4 +--- 3 files changed, 9 insertions(+), 11 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 8c8262c58..56f63f50c 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -55,9 +55,12 @@ jobs: env: # This is necessary in order to push a commit to the repo GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Leave this line unchanged - - name: Publish JS Package + - name: Prepare JS Package run: | - make publish-js - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + cp js/package.json js/dist/package.json + - uses: JS-DevTools/npm-publish@v3 + with: + token: ${{ secrets.NPM_TOKEN }} + package: 'js/dist' + provenance: true + diff --git a/Makefile b/Makefile index 33fd2fa9b..02a6b5bbe 100644 --- a/Makefile +++ b/Makefile @@ -16,6 +16,3 @@ build-js: npm install -g typescript cd js && yarn install cd js && tsc - -publish-js: - cd js && npm run pub diff --git a/js/package.json b/js/package.json index 7c0e66f3d..fac082ca8 100644 --- a/js/package.json +++ b/js/package.json @@ -5,9 +5,7 @@ "main": "index.js", "types": "index.d.ts", "scripts": { - "prepub": "cp package.json dist", - "pub": "cd dist && npm publish", - "postpub": "cd dist && rm package.json" + "test": "echo \"Error: no test specified\" && exit 1" }, "author": "Jason Kulatunga ", "dependencies": {