forked from expo/expo
-
Notifications
You must be signed in to change notification settings - Fork 0
66 lines (63 loc) · 2.16 KB
/
cli.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
57
58
59
60
61
62
63
64
65
66
name: CLI
on:
push:
branches: [main, 'sdk-*']
paths:
- .github/workflows/cli.yml
- packages/@expo/cli/**
- yarn.lock
pull_request:
paths:
- .github/workflows/cli.yml
- packages/@expo/cli/**
- yarn.lock
schedule:
- cron: 0 14 * * *
concurrency:
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-20.04
steps:
- name: 👀 Checkout
uses: actions/checkout@v3
with:
fetch-depth: 100
- name: ⬇️ Fetch commits from base branch
run: git fetch origin ${{ github.event.before || github.base_ref || 'main' }}:${{ github.event.before || github.base_ref || 'main' }} --depth 100
if: github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch'
- name: ♻️ Restore caches
uses: ./.github/actions/expo-caches
id: expo-caches
with:
yarn-workspace: 'true'
- name: 🧶 Install node modules in root dir
if: steps.expo-caches.outputs.yarn-workspace-hit != 'true'
run: yarn install --frozen-lockfile
- name: 🚨 Lint CLI
run: yarn lint --max-warnings 0
working-directory: packages/@expo/cli
- name: 🔎 Type Check CLI
run: yarn typecheck
working-directory: packages/@expo/cli
- name: 🛠 Build CLI
run: yarn prepare
working-directory: packages/@expo/cli
- name: 🧪 Unit Test CLI
run: yarn test
working-directory: packages/@expo/cli
- name: E2E Test CLI
run: yarn test:e2e
working-directory: packages/@expo/cli
# - name: 🔔 Notify on Slack
# uses: 8398a7/action-slack@v3
# if: failure() && (github.event.ref == 'refs/heads/main' || startsWith(github.event.ref, 'refs/heads/sdk-'))
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# SLACK_WEBHOOK_URL: ${{ secrets.slack_webhook_api }}
# with:
# channel: '#expo-cli'
# status: ${{ job.status }}
# fields: job,message,ref,eventName,author,took
# author_name: Check packages