Skip to content

block-catch: init at 0.5.1 - #580909

Open
kleinbem wants to merge 1 commit into
NixOS:masterfrom
kleinbem:block-catch-init
Open

kleinbem wants to merge 1 commit into
NixOS:masterfrom
kleinbem:block-catch-init

Conversation

@kleinbem

@kleinbem kleinbem commented Oct 30, 2026 •

Copy link
Copy Markdown
Member

Adds block-catch, Catch: Block's macOS shortcut for finding and starting Goose agent sessions. It's built from source with nixpkgs' Swift and the macOS 26 SDK, which it requires. The attribute isn't catch because that name is still taken by the removal alias of the old C++ library.

Catch runs standalone, where it starts goose serve itself, or embedded in a host app. Berd embeds it for its global shortcut, and the next PR uses this package for Berd on macOS instead of the prebuilt binary upstream's script downloads. The package installs Catch.app with the Info.plist from upstream's release script, plus bin/catch, and points standalone Catch at nixpkgs' goose (GOOSE_BINARY), since it otherwise only looks in Homebrew's paths.

The check phase runs upstream's swift test (73 tests, none skipped). Three things make them pass in the sandbox: ICU data for URL parsing, the AppKit appearance bundle for the panel tests, and a home directory the build-script tests can compare. The Xcode-only #Preview block is turned into a plain function because the open-source toolchain has no preview macros.

On a macOS runner, standalone Catch starts goose serve from nixpkgs' goose-cli. Catch embedded in Berd isn't tested: it opens with the global shortcut, which I couldn't trigger there.

Things done

Prepared with Claude Code (claude-opus-5-5); the commit carries an Assisted-by: trailer.

@kleinbem kleinbem mentioned this pull request Oct 30, 2026
7 of 13 tasks
@nixpkgs-ci nixpkgs-ci Bot added 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. llm-assisted Contributions that include code generation with LLMs labels Oct 30, 2026
kleinbem added a commit to kleinbem/nix-packages that referenced this pull request Oct 30, 2026
Pins berd to 064f3f90, the signed head of NixOS/nixpkgs#580616
(nixpkgs-review green on all three platforms). Berd now takes
`block-catch` (NixOS/nixpkgs#580909), which the fleet's nixpkgs doesn't
have, so the *Pin nixpkgs PR* run failed on eval. A registry entry's new
`scope` calls such packages into the entry's scope without exporting
them.

Evaluated berd on x86_64-linux and aarch64-darwin: same derivations as
in the nixpkgs trial.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **New Features**
* Package entries can now use additional dependencies from the same pull
request, including dependencies that are not exposed in the final
package set.
* The `berd` package entry now includes an additional dependency and
points to an updated nixpkgs revision.
* **Documentation**
* Clarified how packages can depend on other packages from the same or a
separate pull request.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Co-authored-by: Claude Opus 5.5 <[email protected]>
@kleinbem
kleinbem marked this pull request as ready for review October 31, 2026 05:38
@nixpkgs-ci nixpkgs-ci Bot added 9.needs: reviewer This PR currently has no reviewers requested and needs attention. 7.no default reviewers This PR targets a package or module with no existing maintainers; roving reviewers, take pity! labels Oct 31, 2026
@kleinbem

Copy link
Copy Markdown
Member Author

The aarch64-darwin failure isn't from this package. SwiftUI's @State stopped compiling with Swift 6.4, tracked in #590363.

Comment thread pkgs/by-name/bl/block-catch/package.nix Resolved
Comment thread pkgs/by-name/bl/block-catch/package.nix Resolved
Comment thread pkgs/by-name/bl/block-catch/package.nix Resolved
Comment thread pkgs/by-name/bl/block-catch/package.nix Resolved
Comment thread pkgs/by-name/bl/block-catch/package.nix Resolved
@reckenrode

Copy link
Copy Markdown
Contributor

I added some suggested changes that should let this compile with our Swift 6.4 toolchain. For SDK-specific macros, we have implementations of SwiftUI and FoundationModels macros in open-apple-macros (with stubs for Previews). For other macros, we also have darwin.xcode-macros, but that adds a dependency on Xcode to copy them out.

There’s more on Swift macros in the documentation.

@nixpkgs-ci nixpkgs-ci Bot removed the 9.needs: reviewer This PR currently has no reviewers requested and needs attention. label Nov 19, 2026
@kleinbem

Copy link
Copy Markdown
Member Author

Applied your open-apple-macros and preCheck suggestions and dropped the #Preview postPatch. I couldn't test the Darwin build locally on Linux and my nixpkgs-review-gha run timed out at 6 hours compiling swiftc from source, so this is eval-checked only.

@kleinbem
kleinbem requested a review from reckenrode November 23, 2026 23:58
Assisted-by: Claude Code (claude-opus-5-5)
Assisted-by: Antigravity (Gemini 4 Hydrogen)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

7.no default reviewers This PR targets a package or module with no existing maintainers; roving reviewers, take pity! 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. llm-assisted Contributions that include code generation with LLMs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants