@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%