66 COMMIT_SHORT_SHA : ${{ github.sha }}
77
88jobs :
9- # 基础构建 job - 处理共同的依赖安装和包构建
10- build_base :
9+ build_expo :
1110 runs-on : ubuntu-latest
1211 steps :
1312 - uses : actions/checkout@v3
1413
14+ - name : Get short commit SHA
15+ run : echo "COMMIT_SHORT_SHA=${GITHUB_SHA:0:7}" >> $GITHUB_ENV
16+
1517 - name : Setup Node.js
1618 uses : actions/setup-node@v3
1719 with :
1820 node-version : ' 22'
1921 registry-url : ' https://registry.npmjs.org'
20-
2122 - name : Install Dependencies
2223 run : |
2324 yarn
2425 yarn bootstrap
25-
2626 - name : Build All Packages
2727 run : yarn build
28-
29- - name : Upload Built Packages
30- uses : actions/upload-artifact@v4
31- with :
32- name : built-packages
33- path : |
34- packages/*/lib
35- packages/*/dist
36- packages/*/build
37- node_modules
38- retention-days : 1
39-
40- build_expo :
41- runs-on : ubuntu-latest
42- needs : build_base
43- steps :
44- - uses : actions/checkout@v3
45-
46- - name : Get short commit SHA
47- run : echo "COMMIT_SHORT_SHA=${GITHUB_SHA:0:7}" >> $GITHUB_ENV
48-
49- - name : Setup Node.js
50- uses : actions/setup-node@v3
51- with :
52- node-version : ' 22'
53- registry-url : ' https://registry.npmjs.org'
54-
55- - name : Download Built Packages
56- uses : actions/download-artifact@v4
57- with :
58- name : built-packages
59- path : .
60-
6128 - name : Build Expo Example
6229 run : EXPO_PUBLIC_COMMIT_SHA=${{ env.COMMIT_SHORT_SHA }} yarn expo export:web
6330 working-directory : packages/connect-examples/expo-example
8754
8855 build_new_example :
8956 runs-on : ubuntu-latest
90- needs : build_base
9157 steps :
9258 - uses : actions/checkout@v3
9359
@@ -99,17 +65,15 @@ jobs:
9965 with :
10066 node-version : ' 22'
10167 registry-url : ' https://registry.npmjs.org'
102-
103- - name : Download Built Packages
104- uses : actions/download-artifact@v4
105- with :
106- name : built-packages
107- path : .
108-
68+ - name : Install Dependencies
69+ run : |
70+ yarn
71+ yarn bootstrap
72+ - name : Build All Packages
73+ run : yarn build
10974 - name : Build New Example
11075 run : COMMIT_SHA=${{ env.COMMIT_SHORT_SHA }} yarn build
11176 working-directory : packages/connect-examples/expo-playground
112-
11377 - name : Upload Artifact
11478 uses : actions/upload-artifact@v4
11579 with :
0 commit comments