Skip to content

Building from source

Roy Padina edited this page Oct 29, 2026 · 1 revision

Building from source

A plain Swift Package (macOS 14+, Swift 5.9 or later), no Xcode project, no third-party dependencies. The release build is a universal arm64 + x86_64 app. Requires Xcode or the Xcode command line tools.

git clone https://github.com/roypadina/PullPing.git
cd PullPing
swift test                       # core logic tests
./build.sh                       # writes dist/PullPing.app
open dist/PullPing.app

Layout

Path What
Sources/PullPingCore UI-free, tested logic: models, GitHub GraphQL client, poller, event engine, reminders, persistence, keychain access, ntfy
Sources/PullPing The SwiftUI/AppKit menu-bar app: status panel, main window, notification panels, settings
Tests/PullPingCoreTests Tests for the core, with generic JSON fixtures
Tests/PullPingScreenshotTests Renders the README screenshots (skipped unless RENDER_SCREENSHOTS=<dir> is set)
Assets/icons, AppIcon.icon SVG sources, generated PNG and AppIcon.icns, the macOS 26 Liquid Glass icon
Scripts/package_app.sh Builds the .app bundle (what build.sh runs)
Scripts/make_icons.sh Regenerates icons from the SVGs (needs brew install librsvg)

What package_app.sh does

  1. swift build -c release for Apple Silicon and Intel.
  2. Creates dist/PullPing.app with the binary, Info.plist (LSUIElement, so no Dock icon) and the icons. The macOS 26 icon is compiled when Xcode 26 or later is installed; otherwise macOS 26 shows the classic icon.
  3. Signs it: PULLPING_SIGN_IDENTITY if set, else the maintainer's stable identity if it is in your keychain, else ad hoc.

An ad-hoc signature changes on every build. Set PULLPING_SIGN_IDENTITY to your own code-signing certificate (Keychain Access → Certificate Assistant → Create a Certificate, type Code Signing) if you want a stable signature between builds.

Release zip

RELEASE=1 ./build.sh

Strips the binary and its paths, signs the same way and writes dist/PullPing.zip plus its SHA-256, the asset the Homebrew cask downloads.

Trying the polling logic without the UI

The debug binary has a read-only smoke mode that prints a report and never prints the token:

PULLPING_SMOKE=1 PULLPING_TOKEN=<token> .build/debug/PullPing

swift run

swift run PullPing is fine for quick checks, but it is not a bundled app: no bundled icons, and login item and URL-scheme behavior differ. Use the packaged app for real testing.

Contributing

See Feature requests and contributing and CONTRIBUTING.md.

Clone this wiki locally