-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Expo Build for PRs #246
Open
oudeismetis
wants to merge
12
commits into
main
Choose a base branch
from
expo-build-for-pr
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Expo Build for PRs #246
Changes from 2 commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
59fd7db
Expo Build for PRs
oudeismetis 49e92d1
Choose which platform
oudeismetis 79518dc
Merge branch 'main' into expo-build-for-pr
paribaker 0c5da30
Merge branch 'main' into expo-build-for-pr
paribaker adc448e
Merge branch 'main' into expo-build-for-pr
whusterj f2e894d
Add SENTRY env vars to expo-main.yml update step
whusterj 5654b66
We can remove SENTRY_AUTH_TOKEN from the GH Action config, b/c it sho…
whusterj 7b70cc2
Add SENTRY_PROJECT_NAME and SENTRY_DSN to other GH Action configs
whusterj 5c5dea7
fix for cookiecutter interpolation
whusterj 9aca1f6
Merge in main, resolve conflicts
whusterj 922d3cf
fix typo
whusterj 126ecb4
Merge expo PR build configs and fix some typos
whusterj File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
69 changes: 69 additions & 0 deletions
69
{{cookiecutter.project_slug}}/.github/workflows/expo-pr-app-build.yml
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
name: Expo Publish for test branch | ||
on: | ||
workflow_dispatch: | ||
inputs: | ||
platform: | ||
description: "IOS or Android" | ||
required: true | ||
default: "ios" | ||
type: choice | ||
options: | ||
- ios | ||
- android | ||
- all | ||
|
||
|
||
jobs: | ||
setup: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: jwalton/gh-find-current-pr@v1 | ||
id: findPr | ||
- name: Set name for PR | ||
if: success() && steps.findPr.outputs.number | ||
run: echo "PR=pr-${PR}" >> $GITHUB_ENV | ||
env: | ||
PR: {{ "${{ steps.findPr.outputs.pr }}" }} | ||
outputs: | ||
PR: {{ "${{ env.PR }}" }} | ||
|
||
publish: | ||
runs-on: ubuntu-latest | ||
needs: setup | ||
steps: | ||
- name: 🏗 Setup repo | ||
uses: actions/checkout@v2 | ||
|
||
- name: 🏗 Setup Node | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: 16.x | ||
cache: yarn | ||
cache-dependency-path: ./mobile/yarn.lock | ||
|
||
- name: 🏗 Setup Expo and EAS | ||
uses: expo/expo-github-action@v7 | ||
with: | ||
expo-version: latest | ||
eas-version: latest | ||
token: ${{ secrets.EXPO_TOKEN }} | ||
|
||
- name: 🏗 Get Hash | ||
id: GIT_HASH | ||
run: echo "GIT_HASH=$(git rev-parse --short "$GITHUB_SHA")" >> $GITHUB_ENV | ||
|
||
- name: 📦 Install dependencies | ||
run: cd mobile && yarn install | ||
|
||
- name: 🚀 Build app | ||
run: cd mobile && eas build --platform {{ "${{ inputs.platform }}" }} --profile development --non-interactive | ||
|
||
- name: 🚀 Publish PR Preview | ||
run: cd mobile && eas update --branch={{ "${{ needs.setup.outputs.PR }}" }} --non-interactive --auto | ||
env: | ||
BACKEND_SERVER_URL: {{ "${{ github.event.deployment_status.environment_url }}" }} | ||
ROLLBAR_ACCESS_TOKEN: "" | ||
SENTRY_PROJECT_NAME: "" | ||
SENTRY_DSN: "" | ||
SENTRY_AUTH_TOKEN: "" | ||
|
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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://github.com/thinknimble/tn-spa-bootstrapper/blob/9369901e39a6236be5dd88667c2da4e260edd8de/%7B%7Bcookiecutter.project_slug%7D%7D/clients/mobile/react-native/eas.json#L19C5-L19C27
Instead of development maybe
development_review
since the development eas would hold localhost variables instead?