From 75b696e0d60bba6c300769042831ded23b0f77dd Mon Sep 17 00:00:00 2001 From: Loi Nguyen Date: Thu, 30 Jul 2026 21:06:56 +0700 Subject: [PATCH] docs(init): trim always-loaded awareness templates --- hooks/claude/rtk-awareness.md | 12 ------------ hooks/codex/rtk-awareness.md | 8 -------- src/hooks/init.rs | 9 +++++++++ 3 files changed, 9 insertions(+), 20 deletions(-) diff --git a/hooks/claude/rtk-awareness.md b/hooks/claude/rtk-awareness.md index f68d972a2e..8afe1efef3 100644 --- a/hooks/claude/rtk-awareness.md +++ b/hooks/claude/rtk-awareness.md @@ -11,19 +11,7 @@ rtk discover # Analyze Claude Code history for missed opportunities rtk proxy # Execute raw command without filtering (for debugging) ``` -## Installation Verification - -```bash -rtk --version # Should show: rtk X.Y.Z -rtk gain # Should work (not "command not found") -which rtk # Verify correct binary -``` - -⚠️ **Name collision**: If `rtk gain` fails, you may have reachingforthejack/rtk (Rust Type Kit) installed instead. - ## Hook-Based Usage All other commands are automatically rewritten by the Claude Code hook. Example: `git status` → `rtk git status` (transparent, 0 tokens overhead) - -Refer to CLAUDE.md for full command reference. diff --git a/hooks/codex/rtk-awareness.md b/hooks/codex/rtk-awareness.md index 7ae285e1a8..da97608ed5 100644 --- a/hooks/codex/rtk-awareness.md +++ b/hooks/codex/rtk-awareness.md @@ -22,11 +22,3 @@ rtk gain # Token savings analytics rtk gain --history # Recent command savings history rtk proxy # Run raw command without filtering ``` - -## Verification - -```bash -rtk --version -rtk gain -which rtk -``` diff --git a/src/hooks/init.rs b/src/hooks/init.rs index b71c6288c7..d6244a6d08 100644 --- a/src/hooks/init.rs +++ b/src/hooks/init.rs @@ -4871,6 +4871,15 @@ mod tests { assert_eq!(content, RTK_SLIM); } + #[test] + fn test_awareness_templates_omit_one_time_setup() { + assert!(!RTK_SLIM.contains("Installation Verification")); + assert!(!RTK_SLIM.contains("which rtk")); + assert!(!RTK_SLIM.contains("Refer to CLAUDE.md for full command reference.")); + assert!(!RTK_SLIM_CODEX.contains("## Verification")); + assert!(!RTK_SLIM_CODEX.contains("which rtk")); + } + #[test] fn test_claude_md_mode_creates_full_injection() { // Just verify RTK_INSTRUCTIONS constant has the right content