Skip to content

build(macos): create the dmg with dmgbuild and an arrow background - #49

Merged
mayuki merged 2 commits into
mainfrom
dmgbuild-installer-image
Nov 2, 2026
Merged

mayuki merged 2 commits into
mainfrom
dmgbuild-installer-image

Conversation

@mayuki

@mayuki mayuki commented Nov 2, 2026

Copy link
Copy Markdown
Member

Summary

  • PackageMacOS now builds the disk image with dmgbuild (MIT) through pipx run dmgbuild==1.6.7 instead of hdiutil create, so the Finder window of the dmg has a fixed size and layout: Preferis.app on the left, the /Applications link on the right, 128pt icons (build/dmg/settings.py). pipx run installs nothing on the machine; GitHub's macOS runners carry pipx. The version is pinned in DmgBuildVersion.
  • The background is an arrow between the two icons (build/dmg/background.png + @2x, folded by dmgbuild into one Retina TIFF). build/dmg/make-background.py (standard library only) draws both from arrow.png: a dark canvas, a light arrow, and a light band under the icons. The Finder has no appearance-aware folder backgrounds, paints transparent areas white, and draws the labels black whenever a window has a background picture (dark mode included), so this is the layout that reads the same in both appearances.
  • Docs: Platform.ja.md §3.1 and Design.ja.md §4.4 and the decision log. Workflow comments updated; no new CI steps.

Verification

  • dotnet build build/Preferis.Build.proj -t:PackageMacOS -p:RuntimeIdentifier=osx-arm64 locally with Xcode 26.6: the dmg contains Preferis.app (codesign --verify --strict passes), the Applications link, and a .background.tiff with 640×320 @72dpi and 1280×640 @144dpi representations.
  • Opened in the Finder in dark mode: arrow between the icons, labels readable on the band.

🤖 Generated with Claude Code

mayuki and others added 2 commits November 2, 2026 16:25
Replace the hdiutil step of PackageMacOS with `pipx run dmgbuild==1.6.7` and
build/dmg/settings.py, which lays out Preferis.app and the /Applications link
side by side in the Finder window (128pt icons, fixed window size). pipx run
keeps dmgbuild (MIT) out of the machine, and GitHub's macOS runners carry pipx.

The background (build/dmg/background.png and its @2x, drawn from arrow.png by
make-background.py with the standard library only) is a dark canvas with a
light arrow and a light band under the icons: the Finder has no
appearance-aware folder backgrounds, paints transparent areas white, and draws
the labels black whenever a window has a background picture, dark mode
included.

Documented in Platform.ja.md §3.1 and Design.ja.md §4.4.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@mayuki
mayuki merged commit 34ea7dc into main Nov 2, 2026
3 checks passed
@mayuki
mayuki deleted the dmgbuild-installer-image branch November 2, 2026 07:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant