Add build and qodana badges #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and release | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- v* | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '22' | |
- name: Install dependencies | |
run: npm ci | |
- name: Build executables | |
run: npm run pkg | |
- name: Upload artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: build | |
path: dist | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') | |
with: | |
files: dist/* | |
tag_name: ${{ github.ref }} | |
token: ${{ secrets.GITHUB_TOKEN }} |