Stats
Actions
Tags
From reaper
After file edits, scans for stale/outdated comments and updates them. Writes files to fix comment rot.
1 event · 1 hook
Safety signals detected in this hook configuration
Where this hook configuration is defined
Defined in hooks/hooks.json
Event handlers and matchers — expand Raw Configuration for the full JSON
Write|EditFILE="$CLAUDE_FILE_PATH"; [ -z "$FILE" ] && exit 0; EXT="${FILE##*.}"; REAPER_ALLOWLIST=""; REAPER_LOG=""; if [ -f CLAUDE.md ]; then _al=$(grep -m1 'Reaper: formatter-allowlist' CLAUDE.md 2>/dev/null) && REAPER_ALLOWLIST=$(echo "$_al" | sed 's/.*Reaper: formatter-allowlist[[:space:]]*//' | tr -d ' '); grep -q 'Reaper: formatter-log' CLAUDE.md 2>/dev/null && REAPER_LOG=1; fi; _rf() { _name="$1"; shift; if [ -n "$REAPER_ALLOWLIST" ]; then echo ",$REAPER_ALLOWLIST," | grep -q ",$_name," || return 0; fi; "$@" 2>/dev/null; [ -n "$REAPER_LOG" ] && echo "[reaper:fmt] $_name $FILE" >&2; }; case "$EXT" in php|blade.php) if [ -f vendor/bin/pint ]; then _rf pint vendor/bin/pint "$FILE"; elif [ -f vendor/bin/php-cs-fixer ]; then _rf php-cs-fixer vendor/bin/php-cs-fixer fix "$FILE"; elif command -v php-cs-fixer >/dev/null 2>&1; then _rf php-cs-fixer php-cs-fixer fix "$FILE"; fi;; py) if command -v ruff >/dev/null 2>&1; then _rf ruff ruff format "$FILE" && _rf ruff ruff check --fix "$FILE"; elif command -v black >/dev/null 2>&1; then _rf black black "$FILE"; fi;; go) if command -v gofmt >/dev/null 2>&1; then _rf gofmt gofmt -w "$FILE"; fi;; rs) if command -v rustfmt >/dev/null 2>&1; then _rf rustfmt rustfmt "$FILE"; fi;; rb) if command -v rubocop >/dev/null 2>&1; then _rf rubocop rubocop -a "$FILE"; fi;; swift) if command -v swiftformat >/dev/null 2>&1; then _rf swiftformat swiftformat "$FILE"; fi;; kt|kts) if command -v ktlint >/dev/null 2>&1; then _rf ktlint ktlint -F "$FILE"; fi;; dart) if command -v dart >/dev/null 2>&1; then _rf dart dart format "$FILE"; fi;; *) if [ -f .prettierrc ] || [ -f .prettierrc.json ] || [ -f .prettierrc.js ] || [ -f prettier.config.js ] || [ -f prettier.config.mjs ] || [ -f prettier.config.cjs ]; then _rf prettier npx prettier --write "$FILE"; elif [ -f biome.json ] || [ -f biome.jsonc ]; then _rf biome npx @biomejs/biome format --write "$FILE"; elif [ -f .eslintrc ] || [ -f .eslintrc.json ] || [ -f .eslintrc.js ] || [ -f eslint.config.js ] || [ -f eslint.config.mjs ] || [ -f eslint.config.cjs ]; then _rf eslint npx eslint --fix "$FILE"; fi;; esac; truenpx claudepluginhub spicelabshq/claude-marketplace --plugin reaper446plugins reuse this hooks config
First indexed Nov 28, 2025
Showing the 6 earliest of 446 plugins