mirror of
https://github.com/tenrok/axios.git
synced 2026-06-17 19:21:29 +03:00
ebf3036932
* fix(ci): use OIDC for npm publish instead of token auth * Change permissions from write to read for contents --------- Co-authored-by: Jay <jasonsaayman@gmail.com>
30 lines
610 B
YAML
30 lines
610 B
YAML
name: Publish package to NPM
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- 'v1.*.*'
|
|
|
|
permissions:
|
|
contents: read
|
|
id-token: write
|
|
|
|
jobs:
|
|
publish:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repo
|
|
uses: actions/checkout@v6
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v6
|
|
with:
|
|
node-version: 24.x
|
|
cache: npm
|
|
registry-url: 'https://registry.npmjs.org'
|
|
- name: Install dependencies
|
|
run: npm ci
|
|
- name: Build project
|
|
run: npm run build
|
|
- name: Publish to NPM
|
|
run: npm publish --provenance --access public
|