Skip to content

feat(repo): distribute the macOS build via a Homebrew cask #81

Description

@sepehr-safari

Summary

Distribute the macOS build through a Homebrew cask so users install and update
Studio with a single command, via a shared org tap ocpp-debugkit/homebrew-tap
(brew tap ocpp-debugkit/tap) — a generic tap that can also host future
formulae/casks beyond Studio (e.g. a toolkit CLI).

Motivation

For Studio's audience (CP / CSMS engineers), brew install --cask is the
idiomatic, low-friction install — better than downloading a DMG and dragging to
Applications — and it adds one-command updates (brew upgrade) and a clean
uninstall.

Honest UX note. A cask does not, by itself, remove the Gatekeeper
first-launch prompt on the current ad-hoc (un-notarized) build: Homebrew sets the
quarantine flag by default. The interim is to document
brew install --cask --no-quarantine ocpp-debugkit-studio — one command, no
dialog (the flag skips the quarantine xattr, so Gatekeeper never engages). When
notarization lands (tracked separately), plain brew install --cask becomes
zero-flag seamless with no change to the cask. This issue is the delivery
channel; notarization is complementary and slots in underneath it.

Design

Tap repo — a new public repo ocpp-debugkit/homebrew-tap. Homebrew requires
the homebrew- prefix, so brew tap ocpp-debugkit/tap resolves to it. It is a
shared, generic org tap (not Studio-specific) so it can also host future
formulae/casks — e.g. a toolkit CLI — without spinning up another tap. We do
not target the official homebrew/cask repo: it has a notability gate
(stars / forks) a fresh 0.5 project will not meet — revisit after traction.

CaskCasks/ocpp-debugkit-studio.rb:

cask "ocpp-debugkit-studio" do
  version "0.5.0"
  sha256 "<sha256 of the release .dmg>"

  url "https://github.com/ocpp-debugkit/studio/releases/download/v#{version}/studio-#{version}-macos-ReleaseFast.dmg",
      verified: "github.com/ocpp-debugkit/studio/"
  name "OCPP DebugKit Studio"
  desc "Native desktop debugger for OCPP charging sessions"
  homepage "https://github.com/ocpp-debugkit/studio"

  depends_on macos: ">= :big_sur"   # matches LSMinimumSystemVersion 11.0
  depends_on arch: :arm64           # arm64-only until a universal build

  app "studio.app"                  # confirm exact bundle name inside the DMG

  zap trash: [
    "~/Library/Application Support/io.github.ocpp-debugkit.studio",
    "~/Library/Preferences/io.github.ocpp-debugkit.studio.plist",
    "~/Library/Saved Application State/io.github.ocpp-debugkit.studio.savedState",
  ]
end
  • Confirm the exact .app bundle name inside the DMG during implementation:
    packaging produces studio.app on disk; "OCPP DebugKit Studio" is only the
    Finder display name (CFBundleDisplayName), so the app stanza needs the real
    filename.
  • depends_on arch: :arm64 — Intel Macs are excluded until a universal
    (arm64 + x86_64) build exists (separate issue).
  • depends_on macos: ">= :big_sur" — mirrors the bundle's
    LSMinimumSystemVersion (11.0).

Release automation — extend the studio release workflow so a v* tag
auto-bumps the cask (version + sha256) in the tap: compute the DMG's SHA-256
in the publish job and push a commit (or open a PR) to homebrew-tap. This needs
a scoped cross-repo push credential stored as a secret (the default workflow
token cannot write to another repo) — the maintainer provides it.

Docs — README install section (brew tap … && brew install --cask …, plus
the --no-quarantine interim note), a RELEASING.md runbook step, and a CHANGELOG
entry.

Acceptance criteria

  • brew tap ocpp-debugkit/tap && brew install --cask ocpp-debugkit-studio
    installs the app to /Applications.
  • brew audit --cask ocpp-debugkit-studio and brew style pass.
  • brew uninstall --cask ocpp-debugkit-studio + zap remove it cleanly.
  • First-launch behavior verified on a clean machine and documented honestly
    (plain install vs --no-quarantine).
  • A new studio release auto-bumps the cask (version + sha256).
  • README / RELEASING / CHANGELOG updated.

Tasks

  • Bootstrap the ocpp-debugkit/homebrew-tap tap repo (README, Casks/,
    LICENSE).
  • Add the cask file pinned to v0.5.0 (real sha256 + confirmed app name).
  • Add the release-workflow auto-bump job (+ the cross-repo push secret).
  • Update studio docs (README install, RELEASING, CHANGELOG).
  • Verify end-to-end install / update / uninstall on macOS (arm64).

Dependencies & out of scope

  • Depends on the existing stable DMG release asset
    (studio-<version>-macos-ReleaseFast.dmg). No changes to Studio's app code.
  • Out of scope (separate items): macOS notarization (complementary), a
    universal arm64 + x86_64 build (Intel support), Linux package managers, and
    official homebrew/cask submission.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions