This repository was archived by the owner on Jul 7, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
135 lines (110 loc) · 3.72 KB
/
Copy pathCI.yml
File metadata and controls
135 lines (110 loc) · 3.72 KB
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
name: CI
on:
pull_request:
jobs:
install:
name: Install
runs-on: ubuntu-18.04
continue-on-error: false
steps:
- name: Checkout
uses: actions/checkout@v3
with:
token: ${{ secrets.GIT_TOKEN || github.token }}
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Cache yarn files
uses: actions/cache@v3
id: yarn-cache-files
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-files-${{ hashFiles('**/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-files-
- name: Setup yarn access
run: |
git config --global url."https://${{ secrets.GIT_TOKEN || github.token }}:[email protected]/".insteadOf "https://github.com/"
sed -i "s|Builder/|git+https://github.com/Money-Flow/|" package.json
- name: Install JS dependencies
run: yarn install
- name: Pack artifact
run: tar czf /tmp/artifact.tar.gz .
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: frontend-artifact
path: /tmp/artifact.tar.gz
retention-days: 1
test:
name: Test
needs: [install]
runs-on: ubuntu-latest
steps:
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: frontend-artifact
- name: Unpack artifact
run: tar xf artifact.tar.gz
- name: Run tests
run: yarn test
eslint:
name: Eslint
needs: [install]
runs-on: ubuntu-latest
continue-on-error: false
steps:
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: frontend-artifact
- name: Unpack artifact
run: tar xf artifact.tar.gz
- name: Setup problem matcher for eslint
run: echo "::add-matcher::.github/configs/eslint.json"
- name: Run eslint
run: yarn eslint
stylelint:
name: Stylelint
needs: [install]
runs-on: ubuntu-latest
continue-on-error: false
steps:
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: frontend-artifact
- name: Unpack artifact
run: tar xf artifact.tar.gz
- name: Run stylelint
run: yarn stylelint
typescript:
name: Typescript
needs: [install]
runs-on: ubuntu-latest
continue-on-error: false
steps:
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: frontend-artifact
- name: Unpack artifact
run: tar xf artifact.tar.gz
- name: Run typescript compile
run: yarn tsc --noEmit
build:
name: Build
needs: [install]
runs-on: ubuntu-latest
continue-on-error: false
steps:
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: frontend-artifact
- name: Unpack artifact
run: tar xf artifact.tar.gz
- name: Setup problem matcher for eslint
run: echo "::add-matcher::.github/configs/eslint.json"
- name: Build TS application
run: yarn build