Skip to content

Commit

Permalink
ci: shift npm audit signatures to prepublish script
Browse files Browse the repository at this point in the history
  • Loading branch information
duddu committed May 3, 2024
1 parent d85a17a commit 20258ce
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 10 deletions.
8 changes: 2 additions & 6 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ jobs:
pull-requests: write
id-token: write
actions: write
env:
GH_TOKEN: ${{ github.token }}

steps:
- name: Checkout
Expand All @@ -36,14 +34,12 @@ jobs:
- name: Install dependencies
run: npm clean-install

- name: Verify dependencies signatures
run: npm audit signatures

- name: Release
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ github.token }}
GH_TOKEN: ${{ github.token }}
run: |
npx semantic-release \
| grep --color -Ei "the next release version is|$" \
|| gh run cancel ${{ github.run_id }} && sleep 5
|| gh run cancel ${{ github.run_id }} && sleep 3
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@
"main": "dist/index.js",
"scripts": {
"lint": "eslint src/**/*.ts",
"prettier": "prettier -w .",
"typedoc": "typedoc",
"test": "jest --verbose",
"convertSchema": "./bin/convertSchema.sh",
"bundle": "rimraf ./dist && tsc && cp -R ./src/bin ./dist",
"build": "npm run convertSchema && npm run bundle",
"link": "npm run build && npm link",
"watch": "npm run link && nodemon",
"test": "jest --verbose",
"prepublishOnly": "npm run lint && npm run test && npm run build"
"prettier": "prettier -w .",
"typedoc": "typedoc",
"prepublishOnly": "npm audit signatures && npm run lint && npm run test && npm run build"
},
"devDependencies": {
"@jest/globals": "^29.7.0",
Expand Down

0 comments on commit 20258ce

Please sign in to comment.