An auto tiler for macOS
README.md

Distribution #

Release apps use Sparkle 2.10.1; debug apps never start it. The bundler requires SUFeedURL and SUPublicEDKey, embeds the complete framework, and signs inside-out. Keep the bundle ID, Developer ID team, and signing identity stable so Accessibility grants survive updates.

Public beta previews #

Use the local Parcel Development identity for previews while Developer ID setup is pending:

PARCEL_VERSION=0.1.0-beta.1 PARCEL_BUILD_NUMBER=$(git rev-list --count HEAD) \
  Scripts/bundle.sh release --preview

This keeps the optimized universal build and shipping resources, disables automatic updates, and signs without a trusted timestamp. It does not notarize the app or enable debugging. Package it with Scripts/dmg.sh; label the download as a beta and link to Apple's opening instructions. Keep the local signing identity stable across beta updates. Developer ID signing and notarization remain required for the normal public release.

Installation status #

Signed release distribution is still being prepared. Build from source today. When signed artifacts are published, open the DMG and drag Parcel into Applications. The CLI is at /Applications/Parcel.app/Contents/Resources/bin/prcl; add that containing directory to your shell’s PATH if you want the terminal commands.

Packaging/parcel.rb is a template, not an installable cask. There is no published tap yet. A release’s rendered cask can be installed with brew install --cask ./parcel.rb once its referenced download is available.

Prepare a key #

The owner runs this once:

Scripts/parcel-dev.sh generate-update-key

It creates an Ed25519 seed in the login keychain and prints only the public key. Commit that public key as PRODUCT_UPDATE_PUBLIC_KEY in Scripts/product.env; releases refuse a missing or different key. It does not rotate an existing key or change keychain settings. The account defaults to dev.vinnymac.parcel; use --account and the same PARCEL_UPDATE_ACCOUNT when choosing another. Keep a secure backup outside the repo: losing the key can prevent installed apps from accepting updates.

Try packaging #

Scripts/release.sh --dry-run

This builds a universal app and DMG, signs an appcast entry with a disposable key, and renders a checksum and cask. It never contacts notarization or upload services, or uses your login keychain. Outputs in build/dry-run/0.1.0/ are not distributable. The test replaces build/Parcel.app; rebuild your dev app afterwards.

SwiftPM 6.2.4 switches to its legacy build backend when given multiple --arch options, even with --build-system swiftbuild. That backend cannot build the resource plugin. We use SwiftBuild's universal release default and verify both slices with lipo; don't restore those architecture options without testing.

The bundler remaps Swift and C source paths, removes checkout-only loader paths, and strips debug metadata from staged executables before signing. Build-tree debug artifacts stay intact. Release bundles must contain no checkout paths; debug bundles can retain compiler-generated closure-lifetime diagnostics. Both must target macOS 15.0 and link against the current SDK.

Ad-hoc release bundles require PARCEL_ALLOW_ADHOC=1 and are not distributable. The dry run sets it explicitly; normal releases still require Developer ID.

The layout writer creates and verifies the disk image's Finder layout without launching Finder or requesting Automation permission. Opening the image opens its installer window automatically. Drag Parcel onto Applications, wait for the copy, then open Parcel from Applications and eject the disk. Copying the app is the installation; the image never launches the app or replaces an installed copy automatically.

To test the installer with an existing signed development bundle:

Scripts/dmg.sh build/Parcel.app build/Parcel-install-test.dmg
open build/Parcel-install-test.dmg

This preserves the source bundle and its signing identity. It does not notarize the image; use the release pipeline for public downloads. The output must not already exist.

The background is drawn natively at 640×440 and 1280×880 pixels, with the same 640×440-point canvas at 72 and 144 dpi. Regenerate both PNGs with:

swift run --package-path Packaging/DMGLayout dmg-background Packaging

DMGBackground/BackgroundArtwork.swift draws the palette, geometry, and text. The English installer copy lives in DMGBackground/Resources/Installer.xcstrings; it is baked into both background representations at generation time. Packaging combines background.png and background@2x.png with the system tiffutil -cathidpicheck into .background/background.tiff. The layout writer checks both TIFF representations, their pixel sizes, and their logical sizes.

Packaging uses hdiutil makehybrid -hfs-openfolder to set the installer window without Finder scripting or the Intel-only bless --openfolder option. The writable filesystem is expanded by 16 MiB before writing Finder metadata; unused space compresses away in the final image.

Make a release #

export PARCEL_VERSION=0.3.0
export PARCEL_BUILD_NUMBER=30
export PARCEL_SIGN_IDENTITY='Developer ID Application: Your Name (TEAMID)'
export PARCEL_NOTARY_PROFILE=parcel-notary
export PARCEL_APPCAST_URL=https://your-host.example/parcel/appcast.xml
export PARCEL_UPDATE_PUBLIC_KEY='your-public-key'
export PARCEL_DOWNLOAD_URL_PREFIX=https://your-host.example/parcel/releases/
export PARCEL_PREVIOUS_APP=/path/to/previous/Parcel.app
Scripts/release.sh

Use an App Store Connect API-key profile for PARCEL_NOTARY_PROFILE. Alternatively, set PARCEL_NOTARY_KEY to the .p8 file, PARCEL_NOTARY_KEY_ID, and PARCEL_NOTARY_ISSUER. CI requires the API-key path, not Apple ID credentials.

CI builds the unsigned universal app in a secret-free job. A separate job uses scripts from the trusted default branch to validate, re-sign, and notarize that archive; it never builds tagged code with signing secrets available. Certificate credentials and the update seed travel through stdin, not process arguments.

The optional previous app enables a designated-requirement continuity check. The script notarizes and staples the app, then signs, notarizes, and staples the DMG before signing its final bytes for updates. It verifies that signature before writing metadata. Existing output directories are never replaced; PARCEL_RELEASE_DIR selects a different one.

Nothing is uploaded automatically. Review the new appcast.xml entry, publish the DMG first, then update the hosted feed and cask without deleting feed history. Packaging/parcel.rb is only a template until rendered; the resulting cask installs both app and CLI.

mise run dmg packages without notarizing and still needs release metadata and a signing identity. Scripts/check-bundle.sh checks and smoke-launches a relocated app; --no-launch avoids launching it or contacting the feed. Shell regression tests live in Scripts/tests/.