|
8 | 8 | if: github.event.pull_request.head.repo.full_name == 'callstack/react-native-paper'
|
9 | 9 | steps:
|
10 | 10 | - name: Checkout
|
11 |
| - uses: actions/checkout@v1 |
| 11 | + uses: actions/checkout@v4 |
12 | 12 |
|
13 | 13 | - name: Setup Node.js
|
14 |
| - uses: actions/setup-node@v1 |
| 14 | + uses: actions/setup-node@v4 |
15 | 15 | with:
|
16 |
| - node-version: 16.x |
| 16 | + node-version-file: .nvmrc |
17 | 17 |
|
18 | 18 | - name: Setup Expo
|
19 | 19 | uses: expo/expo-github-action@v7
|
20 | 20 | with:
|
21 | 21 | eas-version: latest
|
22 | 22 | token: ${{ secrets.EXPO_TOKEN }}
|
23 | 23 |
|
24 |
| - - name: Get yarn cache |
| 24 | + - name: Restore dependencies |
25 | 25 | id: yarn-cache
|
26 |
| - run: echo "::set-output name=dir::$(yarn cache dir)" |
27 |
| - |
28 |
| - - name: Check yarn cache |
29 |
| - uses: actions/cache@v1 |
| 26 | + uses: actions/cache/restore@v4 |
30 | 27 | with:
|
31 |
| - path: ${{ steps.yarn-cache.outputs.dir }} |
32 |
| - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} |
| 28 | + path: '**/node_modules' |
| 29 | + key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}-${{ hashFiles('**/package.json', '!node_modules/**') }} |
33 | 30 | restore-keys: |
|
| 31 | + ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }} |
34 | 32 | ${{ runner.os }}-yarn-
|
35 | 33 |
|
36 | 34 | - name: Install dependencies
|
37 |
| - run: yarn |
| 35 | + if: steps.yarn-cache.outputs.cache-hit != 'true' |
| 36 | + run: | |
| 37 | + sudo corepack enable |
| 38 | + yarn --cwd example --immutable |
| 39 | + yarn --immutable |
| 40 | +
|
| 41 | + - name: Cache dependencies |
| 42 | + if: steps.yarn-cache.outputs.cache-hit != 'true' |
| 43 | + uses: actions/cache/save@v4 |
| 44 | + with: |
| 45 | + path: '**/node_modules' |
| 46 | + key: ${{ steps.yarn-cache.outputs.cache-primary-key }} |
38 | 47 |
|
39 | 48 | - name: Publish Expo app
|
40 | 49 | working-directory: ./example
|
|
46 | 55 | run: echo "EXPO_CONFIG=$(npx expo config --json)" >> $GITHUB_OUTPUT
|
47 | 56 |
|
48 | 57 | - name: Comment on PR
|
49 |
| - uses: actions/github-script@v3 |
| 58 | + uses: actions/github-script@v7 |
50 | 59 | with:
|
51 | 60 | github-token: ${{ secrets.GITHUB_TOKEN }}
|
52 | 61 | script: |
|
|
62 | 71 | <a href="${url}"><img src="https://qr.expo.dev/eas-update?appScheme=exp&projectId=${projectId}&channel=${channel}&runtimeVersion=exposdk:${sdkVersion}&host=u.expo.dev" height="200px" width="200px"></a>
|
63 | 72 | `;
|
64 | 73 |
|
65 |
| - const comments = await github.issues.listComments({ |
| 74 | + const comments = await github.rest.issues.listComments({ |
66 | 75 | issue_number: context.issue.number,
|
67 | 76 | owner: context.repo.owner,
|
68 | 77 | repo: context.repo.repo,
|
|
72 | 81 | return;
|
73 | 82 | }
|
74 | 83 |
|
75 |
| - github.issues.createComment({ |
| 84 | + github.rest.issues.createComment({ |
76 | 85 | issue_number: context.issue.number,
|
77 | 86 | owner: context.repo.owner,
|
78 | 87 | repo: context.repo.repo,
|
|
0 commit comments