Skip to content

恢复 Intel Mac release 构建#317

Merged
appergb merged 1 commit into
Open-Less:mainfrom
H-Chris233:ci/restore-macos-intel-release
May 7, 2026
Merged

恢复 Intel Mac release 构建#317
appergb merged 1 commit into
Open-Less:mainfrom
H-Chris233:ci/restore-macos-intel-release

Conversation

@H-Chris233
Copy link
Copy Markdown
Collaborator

@H-Chris233 H-Chris233 commented May 7, 2026

User description

变更

  • 在 release matrix 中恢复 macOS Intel 构建 lane。
  • 使用 macos-15-intel + x86_64-apple-darwin,生成 darwin/x86_64 updater manifest。
  • 保留现有按架构重命名 macOS updater 包的逻辑,避免 arm64 和 x86_64 资产互相覆盖。

为什么不是 macos-13

之前 Intel Mac lane 被注释掉,是因为 macos-13 runner 已被标记为 deprecated,且队列不稳定,曾经拖住 release run。
这次没有恢复旧的 macos-13,而是改用 GitHub 当前明确提供的 Intel macOS runner:macos-15-intel。这样可以恢复 Intel Mac 产物,同时避免回到旧 runner 的排队/弃用风险。

验证

  • git diff --check
  • 解析 .github/workflows/release-tauri.yml matrix,确认同时包含:
    • macos-latest / aarch64-apple-darwin / darwin aarch64
    • macos-15-intel / x86_64-apple-darwin / darwin x86_64
  • 检查 updater 路径仍使用 ${{ matrix.updater-arch }} 区分架构

未验证

  • 尚未跑完整 GitHub Actions release workflow。

PR Type

Enhancement


Description

  • Restore Intel Mac release lane with macos-15-intel

  • Set x86_64-apple-darwin target and x86_64 updater arch

  • Avoid deprecated macos-13 runner instability


Diagram Walkthrough

flowchart LR
  A["Release matrix"] --> B["macos-latest (aarch64)"]
  A --> C["macos-15-intel (x86_64)"]
  B --> D["darwin/aarch64 updater"]
  C --> E["darwin/x86_64 updater"]
Loading

File Walkthrough

Relevant files
Configuration changes
release-tauri.yml
Add Intel Mac release lane with macos-15-intel                     

.github/workflows/release-tauri.yml

  • Removed commented-out macos-13 matrix entry
  • Added new macos-15-intel entry with x86_64-apple-darwin target
  • Kept architecture-qualified updater path logic intact
+4/-9     

The release matrix had kept Intel macOS disabled because the old macos-13 pool was deprecated and repeatedly stalled releases. GitHub now exposes an explicit Intel runner label, so the release lane can be restored without returning to the unstable macos-13 runner.

Constraint: Intel Mac release artifacts must be produced separately from Apple Silicon artifacts

Rejected: Re-enable macos-13 | that runner was explicitly disabled due to deprecation and queue instability

Confidence: high

Scope-risk: narrow

Directive: Keep macOS updater artifact names architecture-qualified when multiple darwin lanes are active

Tested: git diff --check

Tested: Parsed release-tauri.yml matrix and verified macOS arm64/x86_64 lanes plus arch-specific updater paths

Not-tested: Full GitHub Actions release run
@chatgpt-codex-connector
Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Credits must be used to enable repository wide code reviews.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 7, 2026

PR Reviewer Guide 🔍

Here are some key observations to aid the review process:

⏱️ Estimated effort to review: 1 🔵⚪⚪⚪⚪
🧪 No relevant tests
🔒 No security concerns identified
⚡ No major issues detected

@appergb
Copy link
Copy Markdown
Collaborator

appergb commented May 7, 2026

@claude examine 检查有没有严重的问题,审查这个 CI 构建流程在逻辑上是否通顺、是否不会失败。

@claude
Copy link
Copy Markdown

claude Bot commented May 7, 2026

Claude finished @appergb's task in 3m 30s —— View job


CI 构建流程审查结果

  • 读取 workflow 文件
  • 检查 runner 名称有效性
  • 检查 matrix 配置逻辑
  • 检查 artifact 命名和 updater 路径逻辑
  • 总结审查结果

整体结论:逻辑通顺,无严重问题 ✓

PR 的变更量极小(+4/-9 行),逻辑正确,可以合入。以下是逐项检查。


检查项详情

1. macos-15-intel runner 有效性

这是最关键的问题——runner 名称拼错或不存在会导致 job 一直 queue 或立刻失败。确认 macos-15-intel 是 GitHub 当前明确提供的 Intel macOS runner label(替代已 deprecated 的 macos-13),无问题。

2. matrix 变量一致性

- platform: macos-15-intel
  rust-target: x86_64-apple-darwin   # ✓ 与 Intel 架构匹配
  updater-target: darwin             # ✓ 与 arm64 lane 保持一致
  updater-arch: x86_64              # ✓ 区分 aarch64

三个字段内部自洽,与已有 arm64 lane 形成正确对称。

3. startsWith(matrix.platform, 'macos') 条件覆盖

workflow 中所有 macOS 专属步骤(Apple 证书导入、公证配置、build-mac.sh 调用、xattr 清理、updater bundle 重命名、artifact 上传)均使用该前缀匹配,macos-15-intel 会被正确覆盖,无需额外条件。

4. artifact 命名不冲突

步骤 arm64 产物 x86_64 产物
upload-artifact name openless-macos-aarch64 openless-macos-x86_64
updater bundle OpenLess_aarch64.app.tar.gz OpenLess_x86_64.app.tar.gz
Release 资产(DMG) OpenLess_..._aarch64.dmg OpenLess_..._x86_64.dmg

两个 macOS job 并行上传到同一个 GitHub Release 时,所有资产名称都带架构后缀,不会互相覆盖。

5. generate_release_notes 防重复

generate_release_notes: ${{ matrix.updater-target == 'darwin' && matrix.updater-arch == 'aarch64' }}

现在有两个 darwin job,这个条件确保 release notes 只由 arm64 job 生成一次,x86_64 job 为 false,不会产生重复 body。

6. build-mac.sh 不传 --target — 无问题,但值得理解

脚本直接调用 npm run tauri -- build 而不带 --target x86_64-apple-darwin。因为在 Intel 原生 runner 上,host 默认 target 就是 x86_64-apple-darwin,构建结果正确。dtolnay/rust-toolchain 安装 x86_64 target 在这里是冗余(但无害)的。这是现有 arm64 lane 的同款模式,不是 regression。


未发现严重问题

无构建失败风险、无 artifact 冲突风险、无逻辑短路风险。可以合入。

@appergb appergb merged commit 19f4f64 into Open-Less:main May 7, 2026
3 checks passed
@H-Chris233 H-Chris233 deleted the ci/restore-macos-intel-release branch May 7, 2026 05:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants