read

Last week I shared the manual workaround for Xcode 26.4’s broken simulator paste. Running pbpaste | xcrun simctl pbcopy booted every time you want to paste gets old fast.

So I levelled it up with Claude and coded a Mac app.

Sideboard (open source, signed and notarized)

The core

The one-liner that fixes it:

pbpaste | xcrun simctl pbcopy booted

Pipe the Mac clipboard into the Simulator’s pasteboard. Now poll for changes and run it automatically:

let pasteboard = NSPasteboard.general
var lastChangeCount = pasteboard.changeCount

while true {
    if pasteboard.changeCount != lastChangeCount {
        lastChangeCount = pasteboard.changeCount
        if let content = pasteboard.string(forType: .string) {
            let p = Process()
            p.executableURL = URL(fileURLWithPath: "/usr/bin/xcrun")
            p.arguments = ["simctl", "pbcopy", "booted"]
            let pipe = Pipe()
            p.standardInput = pipe
            pipe.fileHandleForWriting.write(Data(content.utf8))
            pipe.fileHandleForWriting.closeFile()
            try? p.run()
        }
    }
    Thread.sleep(forTimeInterval: 1.0)
}

That’s it. Run swift Sideboard.swift and copy-paste works again.

But polling? Really?

Yeah. Every clipboard manager does it.

macOS has no clipboard change notification. No NSNotification, no KVO, no callback. Hammerspoon’s source code says it plainly:

“macOS doesn’t offer any API for getting Pasteboard notifications, so this extension uses polling.”

Here’s what the popular ones do:

App Stars Method Interval
Maccy 19.2k Timer + changeCount 0.5s
Hammerspoon 15.1k NSTimer + changeCount 0.25s

Our 1 second is plenty. You won’t notice the delay.

Sideboard App

That script became Sideboard, a macOS menu bar app. Bidirectional sync (Simulator to Mac) too, with clipboard history.

The core is still that same loop. Poll changeCount, pipe to simctl.

It’s a minimal app for now. But who knows how else it can be useful for 🤷🏻

Trust, but verify

A clipboard tool touches everything you copy. Passwords, tokens, private messages. So trust matters.

Sideboard is open source. You can read every line. But reading source doesn’t prove the DMG you downloaded was built from that source.

That’s why releases are built by GitHub Actions, not on my laptop. The CI pipeline builds from the tagged commit, signs with a Developer ID certificate, and notarizes with Apple. You can see the build logs for every release.

To verify your download:

shasum -a 256 ~/Downloads/Sideboard.dmg

Compare the output against the SHA-256 shown on the release page. If they match, you have the exact binary that CI produced from the source code you can read.

Faster & cheaper to build apps

With vibe coding, I went from a broken Xcode paste to a signed, notarized, open-source Mac app with a one-click release pipeline in a single sitting. The agent handled the parts I’d normally procrastinate on: the notarization dance, mac app scafolding, the GitHub Actions YAML.

Now I focused on what the app should do. Claude handled the implementation.

That’s the shift. The barrier to shipping isn’t writing code anymore. It’s all the stuff around the code. And that stuff just got a lot cheaper.


Image

@samwize

¯\_(ツ)_/¯

Back to Home