Usage — Examples — Caveats — Changelog
Warning
This sub action is experimental and might change without notice. Use it at your own risk
Configuration options
This action is customizable through variables defined in the action.yml.
Here is a summary of all the input options you can use.
| variable | default | description |
|---|---|---|
| github-token | github.token |
A GitHub token to use when commenting on PR (read more) |
Example workflows
Before diving into the workflow examples, you should know the basics of GitHub Actions. You can read more about this in the GitHub Actions documentation.
Run the eas build command via an issue comment
This workflow listens to the issue_comment event and run the eas build command to start a build at Expo.
on:
issue_comment:
types: [created, edited]
concurrency:
# Limit the max concurrency to only 1 active action per pull
group: expo-bot-${{ github.event.issue.number }}
cancel-in-progress: true
jobs:
bot:
runs-on: ubuntu-latest
# Only trigger from comments on pulls
if: ${{ github.event.issue.pull_request }}
# Allow the bot to comment on pulls
permissions:
pull-requests: write
steps:
- name: 🏗 Setup repo
uses: actions/checkout@v3
with:
# Checkout the repo on the pull
ref: refs/pull/${{ github.event.issue.number }}/merge
- name: 🏗 Setup Node
uses: actions/setup-node@v3
with:
node-version: 18.x
cache: yarn
- name: 🏗 Setup Expo
uses: expo/expo-github-action@v8
with:
eas-version: latest
expo-version: latest
token: ${{ secrets.EXPO_TOKEN }}
- name: 📦 Install dependencies
run: yarn install
- name: 🤖 Run expo bot
uses: expo/expo-github-action/command@v8
Things to know
GitHub tokens
When using the GitHub API, you always need to be authenticated.
This action tries to auto-authenticate using the Automatic token authentication from GitHub.
You can overwrite the token by adding the GITHUB_TOKEN environment variable, or add the github-token input.