Add GitHub Actions for library and example apps #3
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 dependencies | |
run: yarn install --immutable | |
- name: Install parser dependencies | |
working-directory: parser | |
run: npm ci | |
- name: Install WebExample dependencies | |
working-directory: WebExample | |
run: npm ci | |
- 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 |