Skip to content

Commit

Permalink
Add preinstall script to try to fix eas build issues
Browse files Browse the repository at this point in the history
EAS build complains that it can't scandir ../web/dist, even though that was already built on the Github runner.
But EAS build --local is to simulat e an EAS cloud run. It doesn't run in the current directory, rather it runs in a temp directory /tmp/runner/eas-build-local-nodejs/b5b2f922-e43d-427b-aa00-d516325d63b0/build/packages/mobile

(As opposed to in /home/runner/work/BloomReader-Lite/BloomReader-Lite/packages/mobile)
  • Loading branch information
jsubloom committed Sep 8, 2023
1 parent 3001657 commit 327305a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/mobile/TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,5 @@ How packages/mobile consumes packages/web

It'd be nice to be able to run multiple variants on the same device.
Follow the instructions here: https://docs.expo.dev/build-reference/variants/

If this yarn preinstall works (allows alpha/beta builds to succeed), then you should refactor build-local.yml to cut out the steps that build shared and web.
1 change: 1 addition & 0 deletions packages/mobile/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"web": "expo start --web",
"build:ios": "yarn && eas build --platform ios --profile development",
"build:ios:prod": "yarn && eas build --platform ios --profile production",
"preinstall": "cd ../shared && yarn && yarn build && cd ../web && yarn && yarn build && cd ../mobile",
"postinstallComments": "// Runs automatically after running 'yarn' or 'yarn install'",
"postinstall": "yarn copy:web",
"copy:web": "ts-node scripts/copyWebDist.ts"
Expand Down

0 comments on commit 327305a

Please sign in to comment.