Skip to content

Commit 7d14c35

Browse files
cameroncookeclaude
andcommitted
ci(release): Add macOS portable packaging pipeline
Extend release workflow with per-architecture macOS packaging jobs, universal artifact assembly, and portable artifact verification. Publish arm64, x64, and universal tarballs plus SHA256 files to GitHub Releases. Keep existing npm and MCP registry release flow intact while wiring version output from the release job into portable packaging stages. Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 961a40d commit 7d14c35

1 file changed

Lines changed: 125 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 125 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ jobs:
1919
release:
2020
runs-on: macos-latest
2121
environment: production
22+
outputs:
23+
version: ${{ steps.get_version.outputs.VERSION }}
2224

2325
steps:
2426
- name: Checkout code
@@ -214,3 +216,126 @@ jobs:
214216
delay=$((delay*2))
215217
done
216218
echo "✅ MCP Registry publish succeeded."
219+
220+
build_and_package_macos:
221+
needs: release
222+
strategy:
223+
fail-fast: false
224+
matrix:
225+
include:
226+
- arch: arm64
227+
runner: macos-14
228+
- arch: x64
229+
runner: macos-13
230+
runs-on: ${{ matrix.runner }}
231+
steps:
232+
- name: Checkout code
233+
uses: actions/checkout@v4
234+
235+
- name: Setup Node.js
236+
uses: actions/setup-node@v4
237+
with:
238+
node-version: '24'
239+
240+
- name: Install dependencies
241+
run: npm ci --ignore-scripts
242+
243+
- name: Package portable artifact
244+
run: |
245+
npm run package:macos -- --arch "${{ matrix.arch }}" --version "${{ needs.release.outputs.version }}"
246+
247+
- name: Verify portable artifact
248+
run: |
249+
npm run verify:portable -- --archive "dist/portable/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-${{ matrix.arch }}.tar.gz"
250+
251+
- name: Upload arch artifact
252+
uses: actions/upload-artifact@v4
253+
with:
254+
name: portable-${{ matrix.arch }}
255+
path: |
256+
dist/portable/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-${{ matrix.arch }}
257+
dist/portable/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-${{ matrix.arch }}.tar.gz
258+
dist/portable/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-${{ matrix.arch }}.tar.gz.sha256
259+
260+
build_universal_and_verify:
261+
needs: [release, build_and_package_macos]
262+
runs-on: macos-latest
263+
steps:
264+
- name: Checkout code
265+
uses: actions/checkout@v4
266+
267+
- name: Setup Node.js
268+
uses: actions/setup-node@v4
269+
with:
270+
node-version: '24'
271+
272+
- name: Install dependencies
273+
run: npm ci --ignore-scripts
274+
275+
- name: Download arm64 artifact
276+
uses: actions/download-artifact@v4
277+
with:
278+
name: portable-arm64
279+
path: dist/portable/arm64
280+
281+
- name: Download x64 artifact
282+
uses: actions/download-artifact@v4
283+
with:
284+
name: portable-x64
285+
path: dist/portable/x64
286+
287+
- name: Build universal portable artifact
288+
run: |
289+
npm run package:macos:universal -- \
290+
--version "${{ needs.release.outputs.version }}" \
291+
--arm64-root "dist/portable/arm64/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-arm64" \
292+
--x64-root "dist/portable/x64/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-x64"
293+
294+
- name: Verify universal portable artifact
295+
run: |
296+
npm run verify:portable -- --archive "dist/portable/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-universal.tar.gz"
297+
298+
- name: Upload universal artifact
299+
uses: actions/upload-artifact@v4
300+
with:
301+
name: portable-universal
302+
path: |
303+
dist/portable/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-universal
304+
dist/portable/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-universal.tar.gz
305+
dist/portable/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-universal.tar.gz.sha256
306+
307+
publish_portable_assets:
308+
if: github.event_name == 'push'
309+
needs: [release, build_universal_and_verify]
310+
runs-on: ubuntu-latest
311+
steps:
312+
- name: Download arm64 artifact
313+
uses: actions/download-artifact@v4
314+
with:
315+
name: portable-arm64
316+
path: dist/portable/arm64
317+
318+
- name: Download x64 artifact
319+
uses: actions/download-artifact@v4
320+
with:
321+
name: portable-x64
322+
path: dist/portable/x64
323+
324+
- name: Download universal artifact
325+
uses: actions/download-artifact@v4
326+
with:
327+
name: portable-universal
328+
path: dist/portable/universal
329+
330+
- name: Upload portable assets to GitHub Release
331+
env:
332+
GH_TOKEN: ${{ github.token }}
333+
run: |
334+
gh release upload "v${{ needs.release.outputs.version }}" \
335+
dist/portable/arm64/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-arm64.tar.gz \
336+
dist/portable/arm64/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-arm64.tar.gz.sha256 \
337+
dist/portable/x64/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-x64.tar.gz \
338+
dist/portable/x64/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-x64.tar.gz.sha256 \
339+
dist/portable/universal/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-universal.tar.gz \
340+
dist/portable/universal/xcodebuildmcp-${{ needs.release.outputs.version }}-darwin-universal.tar.gz.sha256 \
341+
--clobber

0 commit comments

Comments
 (0)