-
Notifications
You must be signed in to change notification settings - Fork 2.2k
52 lines (41 loc) · 1.49 KB
/
bridge-ui--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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: Bridge UI Build and Checks
on: workflow_call
jobs:
build:
runs-on: [arc-runner-set]
steps:
- name: Cancel previous runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Install Git
run: sudo apt-get update && sudo apt-get install -y git
- name: Checkout repository
uses: actions/checkout@v4
- name: Install pnpm dependencies
uses: ./.github/actions/install-pnpm-dependencies
# This step is needed because the .env file is not committed to the repository
# and the Svelte check complains about not finding the exports from $env/static/public,
# which will be generated based on the .env file when running `svelte-kit sync`
- name: Copy .env.example to .env
working-directory: ./packages/bridge-ui
run: cp .env.example .env
- name: Export config to .env
working-directory: ./packages/bridge-ui
run: pnpm export:config
- name: Build Svelte app
env:
SKIP_ENV_VALIDATION: "true"
working-directory: ./packages/bridge-ui
run: pnpm build
- name: Svelte check
working-directory: ./packages/bridge-ui
run: pnpm svelte:check
- name: Linting
working-directory: ./packages/bridge-ui
run: pnpm lint
- name: Unit tests
env:
SKIP_ENV_VALIDATION: "true"
working-directory: ./packages/bridge-ui
run: pnpm test:unit