使用 EAS 工作流发布预览更新

了解如何使用 EAS 工作流发布预览更新。


一旦你对项目进行了更改,你可以通过发布预览更新与团队分享你的更改预览。当你想在不拉取最新更改并本地运行的情况下与团队一起审查更改时,这非常有用。

🌐 Once you've made changes to your project, you can share a preview of your changes with your team by publishing a preview update. This is useful when you want to review changes with your team without pulling the latest changes and running them locally.

你可以在开发版本的界面中以及通过 EAS 仪表板上的可扫描二维码访问预览更新。当在每次提交时发布预览时,你的团队可以在不拉取最新更改和本地运行的情况下审查更改。

🌐 You can access preview updates in the development build UI and through scannable QR codes on the EAS dashboard. When publishing a preview on every commit, your team can review changes without pulling the latest changes and running them locally.

Expo Golden 工作流程:与团队分享预览更新
Expo Golden 工作流程:与团队分享预览更新

开始使用

🌐 Get started

Prerequisites

2 requirements

1.

设置 EAS 更新

你的项目需要设置 EAS 更新 才能发布预览更新。你可以通过以下方式设置你的项目:

Terminal
eas update:configure

2.

创建新的开发版本

在配置好项目后,为每个平台创建新的开发版本

以下工作流程会为每个分支上的每次提交发布预览更新。

🌐 The following workflow publishes a preview update for every commit on every branch.

.eas/workflows/publish-preview-update.yml
name: Publish preview update on: push: branches: ['*'] jobs: publish_preview_update: name: Publish preview update type: update params: branch: ${{ github.ref_name || 'test' }}