使用 EAS Workflows 创建开发版本
了解如何使用 EAS Workflows 创建开发版本。
开发构建 是你项目的专门版本,其中包括 Expo 的开发者工具。这些类型的构建包括项目内的所有原生依赖,使你可以在模拟器、模拟器或物理设备上运行类似于生产的项目构建。此工作流程允许你为每个平台以及物理设备、Android 模拟器和 iOS 模拟器创建开发版本,你的团队可以使用 eas build:dev
访问这些版本。
¥Development builds are specialized builds of your project that include Expo's developer tools. These types of builds include all native dependencies inside your project, enabling you to run a production-like build of your project on a simulator, emulator, or a physical device. This workflow allows you to create development builds for each platform and for both physical devices, Android emulators, and iOS simulators, which your team can access with eas build:dev
.

开始使用
¥Get started
2 requirements
2 requirements
1.
Set up your environment
首先,你需要配置你的项目和设备以构建和运行开发版本。通过以下指南了解如何为开发版本设置环境:
¥To get started, you'll need to configure your project and devices to build and run development builds. Learn how to set up your environment for development builds with the following guides:
让你的项目准备好进行开发构建。
让你的项目准备好进行开发构建。
让你的项目准备好进行开发构建。
让你的项目准备好进行开发构建。
2.
Create build profiles
配置项目和设备后,将以下构建配置文件添加到 eas.json 文件中。
¥After you've configured your project and devices, add the following build profiles to your eas.json file.
{ "build": { "development": { "developmentClient": true, "distribution": "internal" }, "development-simulator": { "developmentClient": true, "distribution": "internal", "ios": { "simulator": true } } } }
以下工作流程为每个平台以及物理设备、Android 模拟器和 iOS 模拟器创建一个构建。它们都将并行运行。
¥The following workflow creates a build for each platform and for both physical devices, Android emulators, and iOS simulators. They all will run in parallel.
name: Create development builds jobs: android_development_build: name: Build Android type: build params: platform: android profile: development ios_device_development_build: name: Build iOS device type: build params: platform: ios profile: development ios_simulator_development_build: name: Build iOS simulator type: build params: platform: ios profile: development-simulator
使用以下命令运行上述工作流程:
¥Run the above workflow with:
-
eas workflow:run .eas/workflows/create-development-builds.yml