19 Commits

Author SHA1 Message Date
rootiest c3e39b7a96 fix(agents): chain AGENTS git hooks to global core.hooksPath
The local core.hooksPath override set by agents-init shadowed the user's
global hooks (ggshield, Git LFS) since git honors only one hooksPath. Each
shim now execs the global/system hook of the same name after running
version-bump, so global hooks still run after version increment. Bumped the
agents-tools version marker to 2 so existing AGENTS repos refresh.
2026-06-17 22:39:18 -04:00
rootiest 70f1ec2eeb docs: document AGENTS/ structure versioning and current layout 2026-06-17 21:42:36 -04:00
rootiest 46dd6cd3a9 feat(agents-init): scaffold .version + commit-time version hooks, pull before commit 2026-06-17 21:40:40 -04:00
rootiest 5cbb01497c fix(agents-tools): harden version-bump test (CDPATH + hooks isolation), drop LFS band-aid 2026-06-17 21:29:05 -04:00
rootiest a5966fd982 chore(agents-init): fix formatting and alignment 2026-06-13 00:24:18 -04:00
rootiest 976f46757c fix(agents-init): quiet only on change, add -v/--verbose flag
- quiet mode now outputs one summary line only when something actually changed;
  idempotent re-runs produce no output
- add -v/--verbose flag as an explicit alias for the default verbose behavior
- gitignore helper output captured to detect changes without printing in quiet mode
- drop eager "Initializing…" header in favour of end-of-run conditional summary
2026-06-13 00:19:11 -04:00
rootiest 2a7cb0f5cb feat(agents-init): add -a/--agents and -p/--plugins short flags 2026-06-13 00:05:31 -04:00
rootiest 8f845f7cf2 feat(agents-init): add --quiet and --silent flags; wrappers use --quiet 2026-06-13 00:03:11 -04:00
rootiest 69384f6427 fix(agents-init): use command cp -rn to bypass interactive wrapper and skip existing files 2026-06-12 23:51:30 -04:00
rootiest 9f9248deb1 fix(agents-init): fix gitignore duplicate entries, add block comment style
- Strip leading / from pattern before git check-ignore so root-anchored
  patterns like /AGENTS.md are checked as repo-relative paths (AGENTS.md)
  and correctly match existing rules — fixes duplicates on every run
- Rework helper to accept multiple patterns and write them as a single
  labeled block with project-style header/footer comment rather than
  appending bare patterns one at a time
- Move gitignore calls out of per-plug loop in --plugins mode so all
  three docs/ patterns are checked and written in one block
- Remove 5 duplicate bare entries left in .gitignore by the broken runs
2026-06-12 23:30:12 -04:00
rootiest 3a054021cf fix(agents-init): migrate plugin dirs, smarter CLAUDE.md handling, wrappers run full init
- Move plugin dir creation into --plugins mode (not 'Always') so --agents
  alone no longer creates empty AGENTS/plugins/ dirs
- Wrappers (claude, agy) now call plain agents-init (both modes) so plugin
  dirs in docs/ are migrated on the first AI launch, not just --agents
- Rewrite --agents CLAUDE.md logic: detect which root files are real vs
  symlinks and handle all four cases (both/agents-only/claude-only/neither)
  without ever losing content
- AGENTS/CLAUDE.md is now its own file in AGENTS/ (real file when both
  existed, symlink → AGENTS.md for single-source cases)
- Root CLAUDE.md now points to AGENTS/CLAUDE.md instead of AGENTS/AGENTS.md;
  readlink checks auto-fix existing symlinks with the wrong target
- New empty setups get AGENTS/AGENTS.md pre-populated with the agent
  directive warning editors not to write through the root symlinks
2026-06-12 23:05:40 -04:00
rootiest 45cba3a15b fix(agents-init): address final review issues (CLAUDE.md safety, rm-rf guard, gitignore anchoring, worktree detection) 2026-06-12 22:09:44 -04:00
rootiest 8d0f425b10 feat(agents-init): add auto-commit step for AGENTS/ sub-repo 2026-06-12 21:59:02 -04:00
rootiest a483c30c05 fix(agents-init): use fish-idiomatic command substitution in --plugins mode 2026-06-12 21:55:05 -04:00
rootiest 3befc07887 feat(agents-init): add --plugins mode (docs/ move + symlinks + gitignore) 2026-06-12 21:53:32 -04:00
rootiest 2a9a7ed2ff fix(agents-init): add error checks and CLAUDE.md move to --agents mode 2026-06-12 21:51:05 -04:00
rootiest d1949953df feat(agents-init): add --agents mode (AGENTS.md move + symlinks + gitignore) 2026-06-12 21:48:25 -04:00
rootiest 7463d894f2 fix(agents-init): address code quality issues in skeleton 2026-06-12 21:46:59 -04:00
rootiest 1e1c2003f3 feat(agents-init): scaffold function with argparse, help, and sub-repo init 2026-06-12 21:42:58 -04:00