Files
praxis/hooks/run-hook.cmd
T
阿白叔andClaude Opus 4.7 ea1819f1d2 feat: rename to praxis, package as Claude Code plugin
Reframe team-guide as praxis (Greek for "practice"): Simgreek's coding
agent rulebook, distributed as a Claude Code plugin so SessionStart
hook can force-inject the using-praxis bootstrap.

- Add .claude-plugin/{marketplace,plugin}.json: makes this repo a
  one-plugin marketplace installable via /plugin marketplace add.
- Add hooks/{hooks.json,session-start,run-hook.cmd}: SessionStart
  hook reads using-praxis SKILL.md and injects it into context as
  hookSpecificOutput.additionalContext (Claude Code) or
  additional_context (Cursor) or additionalContext (Copilot CLI).
- Migrate library/<topic>/SPEC.md → skills/<topic>/SKILL.md with
  YAML frontmatter (name + when-to-invoke description).
- Add skills/using-praxis: bootstrap with iron law, red-flags table,
  catalog, instruction priority, sub-agent stop, Codex/Cursor fallback.
- Add skills/debugging: 4-phase root-cause investigation with
  3-fixes-failed → architectural problem rule.
- Add skills/verification: evidence-before-claims gate with
  rationalization table.
- Drop library/, references in AGENTS.md updated to skills/.
- Rename throughout: team-guide → praxis.
- README rewritten with both install paths (plugin / external spec)
  and updated bootstrap prompt.

Codex / Cursor / non-Claude users still get the spec by reading
AGENTS.md and skills/ files manually — only the auto-injection
requires Claude Code.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-25 18:02:48 +08:00

48 lines
1.0 KiB
Batchfile

@echo off
REM Windows shim that invokes a bash hook script. Claude Code passes the
REM hook name as the first argument; we forward stdin and arguments to the
REM matching POSIX script under hooks/.
setlocal
REM Find git's bash. Required because Claude Code on Windows installations
REM does not always have a bash on PATH.
set "BASH_EXE="
for %%P in (
"%ProgramFiles%\Git\bin\bash.exe"
"%ProgramFiles(x86)%\Git\bin\bash.exe"
"%LocalAppData%\Programs\Git\bin\bash.exe"
) do (
if exist "%%~P" (
set "BASH_EXE=%%~P"
goto :found
)
)
REM Fallback: hope bash is on PATH.
where bash >nul 2>&1
if %ERRORLEVEL%==0 (
set "BASH_EXE=bash"
)
:found
if not defined BASH_EXE (
echo praxis hook: bash not found, skipping > nul
exit /b 0
)
set "HOOK_NAME=%~1"
if "%HOOK_NAME%"=="" (
echo praxis hook: no hook name provided 1>&2
exit /b 1
)
set "HOOK_SCRIPT=%~dp0%HOOK_NAME%"
if not exist "%HOOK_SCRIPT%" (
echo praxis hook: %HOOK_NAME% script not found 1>&2
exit /b 1
)
"%BASH_EXE%" "%HOOK_SCRIPT%"
exit /b %ERRORLEVEL%