-
Notifications
You must be signed in to change notification settings - Fork 16
37 lines (35 loc) · 1.05 KB
/
frontend-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Frontend CI (Vue3/TS)
on:
push:
branches: [main]
paths: ["frontend/**"]
pull_request:
branches: [main]
paths: ["frontend/**"]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: build container
run: |
make docker-compose.yml
docker compose build vite --pull --no-cache
docker compose up vite -d
- name: Lint
run: docker compose exec vite npm run lint
- name: Check formatting
if: ${{ success() || failure() }}
run: docker compose exec vite npm run style
- name: Unit tests
if: ${{ success() || failure() }}
run: docker compose exec vite npm run test
- name: Type check
if: ${{ success() || failure() }}
run: docker compose exec vite npm run type-check
- name: Build for production
if: ${{ success() || failure() }}
run: docker compose exec vite npm run build
- name: bring down container
if: ${{ always() }}
run: docker compose down