Skip to content

ci(publish): add missing permissions #12

ci(publish): add missing permissions

ci(publish): add missing permissions #12

Workflow file for this run

name: publish
on:
workflow_dispatch
push:

Check failure on line 5 in .github/workflows/publish.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/publish.yml

Invalid workflow file

You have an error in your yaml syntax on line 5
tags:
- v*
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20.18
registry-url: https://registry.npmjs.org
- uses: actions/cache@v4
with:
path: node_modules
key: ${{ hashFiles('package-lock.json') }}
- uses: cachix/install-nix-action@v27
with:
nix_path: nixpkgs=channel:nixos-24.11
enable_kvm: true
- run: nix-shell --run 'npm ci'
- run: nix-shell --run 'npm run build'
- run: nix-shell --run 'npm publish --provenance'
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}