Set up AI dev environment for recordingtest (#2)
- CLAUDE.md with collaboration rules and Planner/Generator/Evaluator cycle - .claude/ agents, commands, skills, hooks per Claude Code conventions - Sprint Contracts for sut-prober, normalizer, recorder, player, diff-reporter - SUT catalog (EG-BIM Modeler, 187 plugins) and .gitignore excluding SUT tree - PROGRESS.md / PLAN.md as shared agent handoff state - Solution scaffold targeting sut-prober PoC Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
15
.claude/hooks/guard-sut-folder.sh
Normal file
15
.claude/hooks/guard-sut-folder.sh
Normal file
@@ -0,0 +1,15 @@
|
||||
#!/usr/bin/env bash
|
||||
# PreToolUse(Edit|Write) hook: block modifications to the EG-BIM Modeler/ folder.
|
||||
# The SUT binary tree is read-only from recordingtest's perspective.
|
||||
set -e
|
||||
|
||||
input=$(cat)
|
||||
path=$(echo "$input" | jq -r '.tool_input.file_path // ""')
|
||||
|
||||
case "$path" in
|
||||
*/EG-BIM\ Modeler/*|*"EG-BIM Modeler"*)
|
||||
>&2 echo "🚫 EG-BIM Modeler/ is the SUT binary tree and must not be modified by recordingtest. Use docs/sut-catalog/ for derived data."
|
||||
exit 2
|
||||
;;
|
||||
esac
|
||||
exit 0
|
||||
16
.claude/hooks/guard-sut-launch.sh
Normal file
16
.claude/hooks/guard-sut-launch.sh
Normal file
@@ -0,0 +1,16 @@
|
||||
#!/usr/bin/env bash
|
||||
# PreToolUse(Bash) hook: warn if the agent is about to launch the SUT binary
|
||||
# without going through the runner/player. Does not block; just informs.
|
||||
set -e
|
||||
|
||||
input=$(cat)
|
||||
cmd=$(echo "$input" | jq -r '.tool_input.command // ""')
|
||||
|
||||
if echo "$cmd" | grep -qi 'EG-BIM Modeler\.exe'; then
|
||||
jq -n '{
|
||||
hookSpecificOutput: {
|
||||
hookEventName: "PreToolUse",
|
||||
additionalContext: "⚠ SUT 실행 감지: EG-BIM Modeler.exe 는 player/runner 를 통해서만 실행하세요. sut-explorer 는 정적 분석만 허용됩니다."
|
||||
}
|
||||
}'
|
||||
fi
|
||||
26
.claude/hooks/session-start-progress.sh
Normal file
26
.claude/hooks/session-start-progress.sh
Normal file
@@ -0,0 +1,26 @@
|
||||
#!/usr/bin/env bash
|
||||
# SessionStart hook: surface PROGRESS.md and PLAN.md so any agent can pick up work.
|
||||
set -e
|
||||
|
||||
ctx=""
|
||||
for f in PROGRESS.md PLAN.md; do
|
||||
if [ -f "$f" ]; then
|
||||
ctx="${ctx}
|
||||
|
||||
=== $f ===
|
||||
$(head -80 "$f")"
|
||||
else
|
||||
ctx="${ctx}
|
||||
|
||||
=== $f ===
|
||||
(missing — run /handoff to bootstrap)"
|
||||
fi
|
||||
done
|
||||
|
||||
# Emit JSON so Claude Code adds it as additionalContext.
|
||||
jq -n --arg c "$ctx" '{
|
||||
hookSpecificOutput: {
|
||||
hookEventName: "SessionStart",
|
||||
additionalContext: $c
|
||||
}
|
||||
}'
|
||||
22
.claude/hooks/stop-handoff-reminder.sh
Normal file
22
.claude/hooks/stop-handoff-reminder.sh
Normal file
@@ -0,0 +1,22 @@
|
||||
#!/usr/bin/env bash
|
||||
# Stop hook: remind the agent to run /handoff if PROGRESS.md / PLAN.md / today's
|
||||
# history file look stale. Informational only — never blocks.
|
||||
set -e
|
||||
|
||||
today=$(date +%Y-%m-%d)
|
||||
msg=""
|
||||
|
||||
if [ ! -f PROGRESS.md ]; then msg="${msg}\n- PROGRESS.md missing"; fi
|
||||
if [ ! -f PLAN.md ]; then msg="${msg}\n- PLAN.md missing"; fi
|
||||
if ! ls "docs/history/${today}_"*.md >/dev/null 2>&1; then
|
||||
msg="${msg}\n- 오늘 날짜의 history 파일이 없습니다 (${today})"
|
||||
fi
|
||||
|
||||
if [ -n "$msg" ]; then
|
||||
jq -n --arg m "작업 종료 전 확인:${msg}\n→ /handoff 실행 권장" '{
|
||||
hookSpecificOutput: {
|
||||
hookEventName: "Stop",
|
||||
additionalContext: $m
|
||||
}
|
||||
}'
|
||||
fi
|
||||
Reference in New Issue
Block a user