File tree Expand file tree Collapse file tree 1 file changed +63
-0
lines changed
Expand file tree Collapse file tree 1 file changed +63
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Update Podfile
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+ paths :
8+ - ' package.json'
9+ - ' Example/package.json'
10+ - ' FabricExample/package.json'
11+ jobs :
12+ update_podfile :
13+ runs-on : ubuntu-latest
14+ timeout-minutes : 60
15+ concurrency :
16+ group : ${{ github.workflow }}-${{ github.ref }}
17+ cancel-in-progress : true
18+ steps :
19+ - name : Checkout
20+ uses : actions/checkout@v4
21+ - name : Use Node.js 18
22+ uses : actions/setup-node@v4
23+ with :
24+ node-version : 18
25+ - name : Install CocoaPods
26+ run : sudo gem install cocoapods
27+ - name : Identify changed package.json files
28+ id : changes
29+ run : |
30+ ROOT_CHANGED=false
31+ EXAMPLE_CHANGED=false
32+ FABRIC_CHANGED=false
33+
34+ if git diff-tree --no-commit-id --name-only -r ${{ github.sha }} | grep -q '^package.json'; then
35+ ROOT_CHANGED=true
36+ fi
37+
38+ if git diff-tree --no-commit-id --name-only -r ${{ github.sha }} | grep -q '^Example/package.json'; then
39+ EXAMPLE_CHANGED=true
40+ fi
41+
42+ if git diff-tree --no-commit-id --name-only -r ${{ github.sha }} | grep -q '^FabricExample/package.json'; then
43+ FABRIC_CHANGED=true
44+ fi
45+
46+ echo "ROOT_CHANGED=${ROOT_CHANGED}" >> $GITHUB_ENV
47+ echo "EXAMPLE_CHANGED=${EXAMPLE_CHANGED}" >> $GITHUB_ENV
48+ echo "FABRIC_CHANGED=${FABRIC_CHANGED}" >> $GITHUB_ENV
49+
50+ - name : Update Podfile in Example
51+ if : env.ROOT_CHANGED == 'true' || env.EXAMPLE_CHANGED == 'true'
52+ run : |
53+ cd Example
54+ yarn install
55+ cd ios
56+ pod install
57+ - name : Update Podfile in FabricExample
58+ if : env.ROOT_CHANGED == 'true' || env.FABRIC_CHANGED == 'true'
59+ run : |
60+ cd FabricExample
61+ yarn install
62+ cd ios
63+ pod install
You can’t perform that action at this time.
0 commit comments