Skip to content

chore: add workflow for publishing package to npm #5

chore: add workflow for publishing package to npm

chore: add workflow for publishing package to npm #5

name: Quality Check (Lint, Test, Sonarcloud)
on:
push:
branches:
- main
pull_request:
branches:
- main
- develop
workflow_dispatch:
workflow_call:
jobs:
test:
runs-on: ubuntu-22.04
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
- name: Install dependencies
run: npm ci
- name: Run Linting
run: npm run lint
- name: Run Tests
run: npm run coverage
- name: Run SonarCloud Scan
uses: SonarSource/sonarcloud-github-action@master
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}