@huextrat/github-expo-build-cache-provider
v1.0.0
Published
Build cache provider for Expo CLI using GitHub Releases
Readme
github-build-cache-provider
A remote build cache provider for Expo CLI that uses GitHub Releases to cache and retrieve build artifacts. This helps speed up local development by reusing builds across machines and CI environments.
What is this?
This package implements the Expo Build Cache Provider Plugin interface and uses GitHub Releases as a backend for storing and resolving cached builds. When you run npx expo run:ios or npx expo run:android, the plugin checks if a build with a matching fingerprint exists on GitHub Releases. If found, it downloads and uses the cached build; otherwise, it uploads the new build for future use.
Installation
Install the provider as a dev dependency:
yarn add -D github-expo-build-cache-providerConfiguration
Add the following to your Expo project's app.json:
{
"expo": {
// ...
"experiments": {
"remoteBuildCache": {
"provider": {
"plugin": "@huextrat/github-expo-build-cache-provider",
"options": {
"owner": "<YOUR_GITHUB_USERNAME>",
"repo": "<YOUR_REPO_NAME>"
}
}
}
}
}
}- Replace
<YOUR_GITHUB_USERNAME>and<YOUR_REPO_NAME>with your GitHub username and repository name.
Set your GitHub personal access token (with repo permissions) in your environment:
export GITHUB_TOKEN=ghp_xxxYourTokenHerexxxSecurity
- Never commit your
GITHUB_TOKENto source control. - Use a token with the minimum required permissions.
- Artifacts are uploaded as GitHub Release assets and are accessible to anyone with access to the repository.
References
This project is not officially affiliated with Expo or GitHub. Use at your own risk.
