/sawhorse:codebase-docsfrom sawhorse
Use when the user wants to analyze a codebase and document it feature by feature into the vault - "코드베이스 분석해줘", "기능 문서화해줘", "코드 문서 만들어줘", "이 프로젝트 기능 단위로 정리해줘" 같은 요청일 때 사용.
Ships in sawhorse. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
코드베이스를 읽기 전용으로 탐색해 사용자 관점 기능(capability) 단위로 분해하고,
분석/ 아래 기능당 기능분석 문서 1개씩 만든 뒤 프로젝트 허브(MOC)를 갱신한다.
git push, svn commit/ci, git svn dcommit, hg push를 절대 실행하지 않는다.${user_config.vault_path})뿐이다.${user_config.vault_path} → %USERPROFILE%\.sawhorse\config.json의 vaultPath → 사용자에게 절대경로 문의. 순서대로 시도한다.concepts 확장이 활성화된 경우에만 sawhorse:wiki 규범을 적용한다: 개념 첫 등장 시 [[개념명]] 위키링크. 노트가 없으면 템플릿/개념.md로 먼저 생성한다(죽은 링크 금지). 꺼져 있으면 개념 문서나 링크를 만들지 않는다.sources에만 적는다(경로 변경에 본문이 썩지 않는 구조).$ARGUMENTS = 프로젝트명 [코드베이스 경로]
codebase 필드를 사용한다.\ / : * ? " < > |)는 제거하거나 -로 치환한다.프로젝트 허브 확인
${user_config.vault_path}/프로젝트/<프로젝트명>/<프로젝트명>.md가 있는지 본다. 없으면 /sawhorse:project-doc으로 먼저 등록하라고 안내하고 중단한다.codebase, vcs 필드를 참조한다. vcs는 참고용이며 탐색 방식은 동일하다(경로만 본다).${user_config.vault_path}/프로젝트/<프로젝트명>/분석/과 ${user_config.vault_path}/첨부/스크린샷/, ${user_config.vault_path}/첨부/다이어그램/ 폴더를 준비한다(이미 있으면 유지).코드베이스 읽기 전용 탐색
package.json, pom.xml, build.gradle, *.csproj, requirements.txt 등)로 기술 스택과 엔트리포인트를 식별한다.기능(capability) 트리 도출 — cluedoc 원칙
기능 문서 작성 (1차 패스) — 기능마다 분석/<기능명>.md
기존 문서가 있으면 새로 쓰지 않는다. 사용자가 Obsidian에서 다듬었을 수 있으므로 덮어쓰지 않고, 비어 있는 frontmatter 필드와 누락된 다이어그램·개념 링크만 보완하고 보완 내역을 결과 보고에 남긴다.
${user_config.vault_path}/템플릿/기능분석.md 내용으로 노트를 만들고 frontmatter를 채운다(스키마 순서 고정):
---
type: 기능분석
sources:
- src/auth/LoginService.java # 인증 핵심 로직
- web/pages/LoginPage.vue # 로그인 화면
related: []
status: 초안
tags: []
---
sources에만 실제 파일 경로를 적고, 줄 끼 주석으로 그 파일의 역할을 붙인다. 본문에 파일 경로 나열 금지.
본문은 추상 서술: ## 개요(이 기능이 사용자에게 무엇을 해주는지), ## 동작 흐름(처리 단계 설명).
다이어그램 우선: 내용에 맞는 mermaid를 최소 1개 이상 넣는다 — 구조는 flowchart/classDiagram, 흐름은 sequenceDiagram, 상태 전이는 stateDiagram, 데이터는 erDiagram. 여러 개면 더 좋다.
mermaid로 표현이 복잡한 레이아웃·와이어프레임·전체 아키텍처 그림은 SVG 파일로 직접 그려 ${user_config.vault_path}/첨부/다이어그램/<프로젝트명>/에 저장하고 ![[<파일명>.svg]]로 임베드한다.
concepts 확장이 켜진 경우에만 본문에서 도메인 개념 첫 등장 시 [[개념명]] 링크를 쓰고, 노트가 없으면 템플릿/개념.md로 생성한다(정의 2-3문장, sources에 근거 코드 경로).
related에 관련 기능분석 문서를 서로 링크한다. status는 기본 초안.
스크린샷 (선택)
${user_config.vault_path}/첨부/스크린샷/<프로젝트명>/<기능명>-<화면명>.png로 저장하고 해당 기능 문서에 ![[<파일명>.png]]로 임베드한다.허브 MOC 갱신
## 문서 섹션에 생성한 분석 문서 링크 목록([[<기능명>]])을 추가한다.결과 보고
/sawhorse:codebase-docs 재실행 안내.| 금지 | 대안 |
|---|---|
| 코드베이스 파일 수정/삭제, 빌드·테스트 실행 | 읽기 전용 탐색만 |
원격 변경(git push, svn commit 등) | 실행할 이유가 없다. 훅이 확인을 요구하니 승인하지 말고 로컬 작업만 진행 |
| 본문에 파일 경로 나열 | 경로는 frontmatter sources + 역할 주석만 |
| 폴더 구조 미러한 기능 분해 | 사용자 관점 기능(capability) 단위로 분해 |
| 텍스트만 있는 기능분석 문서 | 다이어그램 필수 — mermaid 우선, 복잡한 그림은 SVG |
| 스키마 밖 frontmatter 필드 추가 | 볼트의 해당 문서 템플릿 참고, 기존 사용자 필드 보존 |
죽은 위키링크([[...]] 대상 없음) | 링크 전에 템플릿/개념.md로 노트 생성 |
| Playwright MCP 부재 시 작업 중단 | 텍스트만 진행하고 건너뛴 사실 보고 |
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub a7garden/sawhorse --plugin sawhorse19 skills in this plugin
/captureUse when the user wants to jot something into today's daily note — "오늘 일지에 적어줘", "이거 메모해줘", "할 일 추가", "오늘 문서 만들어줘", "capture this" — or when a scheduled workbench action asks to prepare today's daily note. Writes one line into the day's journal in the sawhorse workspace, sorting it into 할 일 / 한 일 / 메모./daily-logUse when the user asks to write or update today's work journal from the day's session records — "업무일지 써줘", "오늘 업무 정리", "업무기록 업데이트", "일지 써줘" 같은 요청을 할 때, 퇴근 전 일지를 정리할 때 사용./daily-reportUse when the user asks for a daily work report to send — "업무 보고 써줘", "퇴근 보고", "일일 보고", "오늘 업무 보고해줘" 같은 요청을 할 때, 퇴근 전 보고를 정리할 때 사용./delegateAutomatically assess and delegate bounded Sawhorse harness subtasks to an appropriate model through the host child-request inbox. Use during SDD or TDD work when splitting research, implementation, or verification reduces total work./eveningUse when the user finishes the workday — "퇴근", "저녁", "evening", "오늘 마무리", "일지 쓰고 보고서 만들어줘" 요청 시. 오늘 할 일 체크 정리 → 업무기록 작성 → 보고서 출력 → 내일 할 일 정리를 한 번에 실행한다. 사용자 응답 없이 끝까지 실행한다./init-vaultPrepare enabled feature extensions' document folders, templates, and optional Obsidian integration in an existing Sawhorse vault. Use when document assets are missing or the user asks to initialize workspace notes.