Expo Update #46
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Expo Update | |
on: | |
push: | |
branches: | |
- update | |
paths: | |
- 'src/**.ts' | |
- 'src/**.tsx' | |
workflow_dispatch: | |
env: | |
SENTRY_URL: 'https://sentry.io' | |
jobs: | |
update: | |
name: EAS Update | |
runs-on: ubuntu-latest | |
env: | |
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }} | |
steps: | |
- name: π Check for EXPO_TOKEN | |
run: | | |
if [ -z "${{ secrets.SENTRY_AUTH_TOKEN }}" ]; then | |
echo "You must provide an SENTRY_TOKEN secret linked to this project's Sentry account. Learn more: https://docs.expo.dev/guides/using-sentry/#sign-up-for-a-sentry-account-and-create-a-project" | |
fi | |
if [ -z "${{ secrets.EXPO_TOKEN }}" ]; then | |
echo "You must provide an EXPO_TOKEN secret linked to this project's Expo account in this repo's secrets. Learn more: https://docs.expo.dev/eas-update/github-actions" | |
echo "Access tokens: https://expo.dev/accounts/[account]/settings/access-tokens" | |
exit 1 | |
fi | |
- name: π Checkout repository | |
uses: actions/checkout@v3 | |
- name: π Set up corepack | |
run: corepack enable | |
- name: π Setup Node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18.x | |
cache: yarn | |
- name: π Setup EAS | |
uses: expo/expo-github-action@v8 | |
with: | |
eas-version: latest | |
token: ${{ secrets.EXPO_TOKEN }} | |
- name: π¦ Install dependencies | |
run: yarn install | |
- name: π Create update | |
run: eas update --auto --non-interactive --channel production --platform android | |
- name: π Upload Sentry sourcemaps | |
run: npx sentry-expo-upload-sourcemaps dist |