在与Visual Studio App App Center链接的自动构建中心中,管理Flutter应用程序的版本名称/代码的最佳实践是什么?

发布于 2025-01-27 19:17:46 字数 565 浏览 5 评论 0原文

我们计划在App Center上配置我们的iOS和Android应用程序,以在每次推动到各自的UAT/生产分支机构时自动触发构建过程(例如,推送到UAT分支,应触发两者的UAT版本的构建版本iOS和Android)。

iOS和Android构建均配置为使用版本编号和pubspec.yaml的构建号码。

在典型的情况下,我将拥有1个UAT版本和1个构建的应用程序版本(例如,UAT的1.2.0+11 和1.2.0+12用于生产),我应该如何在pubspec.yaml中管理版本的更改并构建数字?

例如,如果我在UAT分支上批准了拉动请求以构建1.2.0+11,请完成测试,并希望将其向前移至生产分支以构建1.2.0+12 < /code>,我是否必须创建另一个分支(让我们称其为XYZ分支)将UAT分支合并到并修改版本并将数字构建为1.2.0+12,然后再提交XYZ分支的PR到生产分支?这样做是为了使生产分支只有1个推动,因为App Center上的构建过程是由推送到特定分支的。

We plan to configure our iOS and Android applications on App Center to trigger the build process automatically on every push to their respective UAT/Production branches (e.g. a push to the UAT branch should trigger the build for the UAT version of the flutter app for both iOS and Android).

Both iOS and Android builds are configured to use version number and build number from pubspec.yaml.

In a typical scenario where I would have 1 UAT version and 1 Production version of the app built (e.g. 1.2.0+11 for UAT and 1.2.0+12 for Production), how should I go about managing the changes to version and build numbers in pubspec.yaml?

For example, if I approved a pull request on UAT branch to build 1.2.0+11, completed the testing and wanted to move it forward to Production branch to build 1.2.0+12, would I have to create another branch (let's call it XYZ branch) to merge UAT branch to and modify the version and build numbers to 1.2.0+12 before submitting a PR from XYZ branch to Production branch? This is done so that there is only 1 push to the Production branch as the build process on App Center is triggered by a push to a specific branch.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文