Skip to content

feat(refacto-core): binary hook w/ native cmd exec + streaming#956

Open
aeppling wants to merge 3 commits intodevelopfrom
feat-hook-engine
Open

feat(refacto-core): binary hook w/ native cmd exec + streaming#956
aeppling wants to merge 3 commits intodevelopfrom
feat-hook-engine

Conversation

@aeppling
Copy link
Copy Markdown
Contributor

@aeppling aeppling commented Mar 31, 2026

From the idea of #536

Summary

  • Binary hook engine: RTK can now process Claude Code hooks directly as a binary (rtk hook claude), reading JSON from stdin and responding on stdout without shell script dependencies (no jq/bash required)
  • Native command executor: rtk run executes commands natively with operator logic (&&/||/;), shell builtins (cd, export, pwd), and streaming output filters — all in a single process
  • Hook check command: rtk hook check [--agent] for dry-run testing of hook routing decisions
  • Streaming filter infrastructure: Line-by-line output filtering with per-binary filter modes (Streaming/Buffered/Passthrough) and RAII child process management
  • Multi-remote branch support: git branch -a now correctly deduplicates branches across multiple remotes
  • Documentation: Added src/cmd/README.md, updated docs/TECHNICAL.md architecture diagram, folder map, and flow sections

Test plan

  • 1583 tests pass (cargo test --all)
  • Hook routing retest
  • 20+ Chained commands

Should fix :

ISSUE #154
ISSUE #532
ISSUE #530
ISSUE #222
ISSUE #897
ISSUE #732
ISSUE #917 (for the env var prefix part)
ISSUE #294 (cover ~40%)
ISSUE #361

Co-Authored-By: ahundt <ATHundt@gmail.com>
@aeppling
Copy link
Copy Markdown
Contributor Author

aeppling commented Apr 1, 2026

Removed strip_quote from last release requirements, will be added back for this

@aeppling
Copy link
Copy Markdown
Contributor Author

aeppling commented Apr 2, 2026

not ready for review, need fix for a full standardized flow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant