-
Notifications
You must be signed in to change notification settings - Fork 1
54 lines (48 loc) · 1.34 KB
/
on_push_branch_execute_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
53
name: frontend_on_push_branch_execute_ci_cd
on:
push:
branches: [main]
# See https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#onpushpull_requestbranchestags
pull_request:
# Only branches and tags on the base are evaluated
branches: [main]
env:
NODE_VERSION: "20.12"
jobs:
yarn_cache:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: 'yarn'
- run: yarn install --frozen-lockfile
yarn_test:
runs-on: ubuntu-latest
needs: yarn_cache
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: 'yarn'
- run: yarn install --frozen-lockfile
- run: yarn test:ci
yarn_lint:
runs-on: ubuntu-latest
needs: yarn_cache
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: 'yarn'
- run: yarn install --frozen-lockfile
- run: yarn lint