Skip to content

Commit

Permalink
trying to fix npm publish
Browse files Browse the repository at this point in the history
  • Loading branch information
AnalogJ committed May 30, 2024
1 parent ccae282 commit c88d547
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 11 deletions.
13 changes: 8 additions & 5 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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

3 changes: 0 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,3 @@ build-js:
npm install -g typescript
cd js && yarn install
cd js && tsc

publish-js:
cd js && npm run pub
4 changes: 1 addition & 3 deletions js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -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 <[email protected]>",
"dependencies": {
Expand Down

0 comments on commit c88d547

Please sign in to comment.