-
Notifications
You must be signed in to change notification settings - Fork 59
56 lines (46 loc) · 1.38 KB
/
check.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
54
55
56
name: Typecheck, lint and test
on:
pull_request:
merge_group:
branches:
- main
push:
branches:
- main
jobs:
check:
if: github.repository == 'Expensify/react-native-live-markdown'
runs-on: ubuntu-latest
concurrency:
group: check-root-${{ github.ref }}
cancel-in-progress: true
steps:
- name: Check out Git repository
uses: actions/checkout@v4
- name: Use Node.js 18
uses: actions/setup-node@v4
with:
node-version: 18
- name: Install node_modules
run: yarn install --immutable
- name: Verify there's no parser diff
working-directory: parser
run: |
yarn build
if ! git diff --name-only --exit-code; then
# shellcheck disable=SC2016
echo 'Error: Parser diff detected! Please run `cd parser && yarn build` and commit the changes.'
exit 1
fi
- name: Typecheck library
run: yarn tsc --project tsconfig.json --noEmit
- name: Typecheck parser
run: yarn tsc --project parser/tsconfig.json --noEmit
- name: Typecheck example app
run: yarn tsc --project example/tsconfig.json --noEmit
- name: Typecheck WebExample app
run: yarn tsc --project WebExample/tsconfig.json --noEmit
- name: Lint
run: yarn lint
- name: Test
run: yarn test