fix(release): ship map/asset editors as macOS .app + launch.command #161

Merged
marco merged 1 commit from fix/macos-editor-app-bundles into main 2026-07-22 23:14:17 +02:00
Owner

Summary

Ship the macOS map editor and asset editor as double-clickable .app bundles (they were plain folders of ~200 files), and add a launch.command to every macOS zip that unlocks the unsigned app and opens it.

Context: you flagged the release macOS assets. I downloaded the 0.1.4 assets and checked — the client .app is fine (still a proper IsoMmo.app bundle, unchanged since #101). The gap was the GUI dev tools: the map/asset editors were only ever zipdir'd as loose folders (added that way in #147), never .apps.

  • Generalized macos_app() (scripts/ci/lib.sh) from client-only to any self-contained publish: macos_app PUBLISH VERSION STAGING NAME EXECUTABLE BUNDLE_ID CATEGORY, filling a shared scripts/ci/macos-app.plist template (__NAME__/__BUNDLE_ID__/__EXECUTABLE__/__CATEGORY__/__VERSION__). Replaces the hard-coded IsoMmo.app + client Info.plist.
  • Map editor (osx-arm64) → IsoMmo Map Editor.app; asset editorIsoMmo Asset Editor.app; client unchanged (IsoMmo.app, same values, now via the generic helper). Windows editors stay plain folders.
  • launch.command (macos_launcher()) in every macOS zip: xattr -cr (falling back to xattr -c) + ad-hoc codesign --force --deep --sign - + open. .command, not .sh, so Finder runs it on double-click. Plus a short per-tool unlock note for the editors; the client's note now points at launch.command as the easy path.

How it was tested

Locally on macOS (arm64), using the released 0.1.4 map-editor publish output as the dotnet publish -r osx-arm64 stand-in:

  • macos_app produces IsoMmo Map Editor.app with Contents/{MacOS,Resources,Info.plist}; plutil -lint OK; CFBundleExecutable=IsoMmo.MapEditor, CFBundleName=IsoMmo Map Editor, version + id correct; the apphost is a +x Mach-O arm64.
  • launch.command is +x with the right app name; running its unlock steps ad-hoc-signs the bundle and codesign --verify --deep --strict passes. (xattr -cr isn't supported on every macOS build — the || xattr -c fallback covers it, matching the existing note.) The open line was inspected, not run, to avoid spawning a GUI window.
  • python3 yaml.safe_load on release.yaml and bash -n on lib.sh pass; all helpers resolve.

CI's Lint & Test job is unaffected (no compiled code changed). The bundling only exercises on a tag build — I could not run the full release pipeline pre-merge, so the definitive check is the next tagged release's assets.

Checklist

  • Verified the actual 0.1.4 assets (client OK; editors were the gap)
  • Bundling + launcher validated locally on macOS
  • Multi-platform preserved (Windows editors unchanged; linux CI builds the .app as before)
  • End-to-end release pipeline — runs only on a tag; verify on the next release
## Summary Ship the macOS **map editor** and **asset editor** as double-clickable `.app` bundles (they were plain folders of ~200 files), and add a `launch.command` to every macOS zip that unlocks the unsigned app and opens it. Context: you flagged the release macOS assets. I downloaded the 0.1.4 assets and checked — the **client** `.app` is fine (still a proper `IsoMmo.app` bundle, unchanged since #101). The gap was the **GUI dev tools**: the map/asset editors were only ever `zipdir`'d as loose folders (added that way in #147), never `.app`s. - **Generalized `macos_app()`** (`scripts/ci/lib.sh`) from client-only to any self-contained publish: `macos_app PUBLISH VERSION STAGING NAME EXECUTABLE BUNDLE_ID CATEGORY`, filling a shared `scripts/ci/macos-app.plist` template (`__NAME__/__BUNDLE_ID__/__EXECUTABLE__/__CATEGORY__/__VERSION__`). Replaces the hard-coded `IsoMmo.app` + client `Info.plist`. - **Map editor** (osx-arm64) → `IsoMmo Map Editor.app`; **asset editor** → `IsoMmo Asset Editor.app`; **client** unchanged (`IsoMmo.app`, same values, now via the generic helper). Windows editors stay plain folders. - **`launch.command`** (`macos_launcher()`) in every macOS zip: `xattr -cr` (falling back to `xattr -c`) + ad-hoc `codesign --force --deep --sign -` + `open`. `.command`, not `.sh`, so Finder runs it on double-click. Plus a short per-tool unlock note for the editors; the client's note now points at `launch.command` as the easy path. ## How it was tested Locally on macOS (arm64), using the released 0.1.4 map-editor publish output as the `dotnet publish -r osx-arm64` stand-in: - `macos_app` produces `IsoMmo Map Editor.app` with `Contents/{MacOS,Resources,Info.plist}`; `plutil -lint` OK; `CFBundleExecutable=IsoMmo.MapEditor`, `CFBundleName=IsoMmo Map Editor`, version + id correct; the apphost is a `+x` Mach-O arm64. - `launch.command` is `+x` with the right app name; running its unlock steps ad-hoc-signs the bundle and `codesign --verify --deep --strict` passes. (`xattr -cr` isn't supported on every macOS build — the `|| xattr -c` fallback covers it, matching the existing note.) The `open` line was inspected, not run, to avoid spawning a GUI window. - `python3 yaml.safe_load` on `release.yaml` and `bash -n` on `lib.sh` pass; all helpers resolve. CI's Lint & Test job is unaffected (no compiled code changed). The bundling only exercises on a tag build — I could not run the full release pipeline pre-merge, so the definitive check is the next tagged release's assets. ## Checklist - [x] Verified the actual 0.1.4 assets (client OK; editors were the gap) - [x] Bundling + launcher validated locally on macOS - [x] Multi-platform preserved (Windows editors unchanged; linux CI builds the .app as before) - [ ] End-to-end release pipeline — runs only on a tag; verify on the next release
fix(release): ship map/asset editors as macOS .app + double-click launch.command
All checks were successful
ci / Lint & Test (pull_request) Successful in 3m25s
69e3c4c91a
Generalize macos_app() to bundle any self-contained publish (client + GUI dev
tools) into a <name>.app; the map and asset editors were shipping as plain
folders. Add launch.command (double-clickable) that unlocks the unsigned app
(xattr + ad-hoc codesign) and opens it, in every macOS zip, plus a per-tool
unlock note. The client .app was already correct and is unchanged in behaviour.
marco merged commit 9678f50d66 into main 2026-07-22 23:14:17 +02:00
marco deleted branch fix/macos-editor-app-bundles 2026-07-22 23:14:17 +02:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
marco/IsoMmo!161
No description provided.