👷 chore(ci): add build workflow file

This commit is contained in:
2024-02-17 18:27:16 +01:00
parent 0baa40c518
commit 9afa2c9bfa
2 changed files with 37 additions and 1 deletions
+35
View File
@@ -0,0 +1,35 @@
name: build
on:
push:
branches: ['master']
pull_request: {}
workflow_call: {}
workflow_dispatch: {}
jobs:
build:
runs-on: ubuntu-latest
name: Build
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 'lts/*'
cache: 'npm'
- name: Install dependecies
run: npm ci
- name: Build
run: npm run build
- name: Test and generate coverage report
run: npm run test:coverage
# TODO: upload coverage report to codecov
# - name: Upload coverage report to Codecov
# uses: codecov/codecov-action@v3
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
+2 -1
View File
@@ -12,7 +12,8 @@
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0", "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
"lint:fix": "npm run lint -- --fix", "lint:fix": "npm run lint -- --fix",
"preview": "vite preview", "preview": "vite preview",
"test": "vitest" "test": "vitest",
"test:coverage": "npm run test -- --coverage"
}, },
"dependencies": { "dependencies": {
"@emotion/react": "^11.11.3", "@emotion/react": "^11.11.3",