Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 34 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,37 +4,60 @@ on:
push:
branches:
- main
pull_request:
branches:
- "*"

jobs:
release:
test-and-build:
permissions:
contents: write
pull-requests: write
issues: write
packages: write
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [20.x, 21.x, 22.x]

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Required for semantic-release

- name: Use Node.js
- name: Use Node.js {{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: 20
node-version: ${{ matrix.node-version }}
registry-url: "https://registry.npmjs.org/"

- name: Install dependencies
run: npm ci
- run: npm ci
- run: npm run build
- run: npm run test:badges

- name: Build
run: npm run build
publish:
needs: [test-and-build]
runs-on: ubuntu-latest

if: github.ref == 'refs/heads/main'
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Required for semantic-release

- name: Test and badges
run: npm run test:badges
- name: Use Node.js {{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
registry-url: "https://registry.npmjs.org/"

- name: Run semantic-release
- run: npm ci
- run: npm run build
- run: npm run test:badges
- run: npx semantic-release
- run: npm run semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: npx semantic-release
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
23 changes: 0 additions & 23 deletions .releaserc

This file was deleted.

Loading