Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,12 @@
"description": "스테이징된 변경사항을 분석하고 원자적 커밋 생성 & 드래프트 PR 생성",
"source": "./plugins/git-commands",
"homepage": "https://github.com/NaverPayDev/naverpay-plugins/tree/main/plugins/git-commands"
},
{
"name": "naverpay-code-verifier",
"description": "코드 검증 및 사이드 이펙트 분석",
"source": "./plugins/code-verifier-agents",
"homepage": "https://github.com/NaverPayDev/naverpay-plugins/tree/main/plugins/code-verifier-agents"
}
]
}
36 changes: 26 additions & 10 deletions docs/scripts/build-docs.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,11 @@ const OUTPUT_PATH = path.join(__dirname, "..", "index.html");
function parseReadme(readmePath, pluginDir) {
const content = fs.readFileSync(readmePath, "utf-8");
const pluginName = path.basename(pluginDir);
const basePluginId = pluginName.replace("-commands", "").replace(/-/g, "");
const basePluginId = pluginName
.replace("-commands", "")
.replace("-agents", "")
.replace("-skills", "")
.replace(/-/g, "");

// marked.lexer()를 사용하여 마크다운을 토큰으로 파싱
const tokens = marked.lexer(content);
Expand Down Expand Up @@ -55,7 +59,10 @@ function parseReadme(readmePath, pluginDir) {
currentSection = token.text.toLowerCase();

// h2 레벨의 "설치" 섹션만 상세 페이지에서 제외 (커스텀 HTML로 만들 예정)
if (token.depth === 2 && (currentSection.includes("설치") || currentSection.includes("install"))) {
if (
token.depth === 2 &&
(currentSection.includes("설치") || currentSection.includes("install"))
) {
skipUntilNextSection = true;
} else {
skipUntilNextSection = false;
Expand All @@ -72,7 +79,10 @@ function parseReadme(readmePath, pluginDir) {
// 리스트 처리
if (token.type === "list") {
// 주요 기능 섹션의 리스트 아이템 추출
if (currentSection.includes("주요 기능") || currentSection.includes("features")) {
if (
currentSection.includes("주요 기능") ||
currentSection.includes("features")
) {
token.items.forEach((item) => {
features.push(item.text);
});
Expand Down Expand Up @@ -107,18 +117,20 @@ function parseReadme(readmePath, pluginDir) {
const originalList = renderer.list.bind(renderer);
renderer.list = (body, ordered, start) => {
// "주요 기능" 또는 "features" 섹션의 리스트에만 특별한 클래스 추가
if (currentHeading.includes("주요 기능") || currentHeading.includes("features")) {
const tag = ordered ? 'ol' : 'ul';
const startAttr = (ordered && start !== 1) ? ` start="${start}"` : '';
if (
currentHeading.includes("주요 기능") ||
currentHeading.includes("features")
) {
const tag = ordered ? "ol" : "ul";
const startAttr = ordered && start !== 1 ? ` start="${start}"` : "";
return `<${tag}${startAttr} class="feature-list">\n${body}</${tag}>\n`;
}
return originalList(body, ordered, start);
};

// contentTokens를 marked.parser()로 HTML로 변환
const detailContentHtml = contentTokens.length > 0
? marked.parser(contentTokens, { renderer })
: "";
const detailContentHtml =
contentTokens.length > 0 ? marked.parser(contentTokens, { renderer }) : "";

return {
title: title || pluginName,
Expand Down Expand Up @@ -225,7 +237,11 @@ function buildDocs() {
}

// 상세 페이지 템플릿 파일 읽기
const DETAIL_TEMPLATE_PATH = path.join(__dirname, "..", "detail-template.html");
const DETAIL_TEMPLATE_PATH = path.join(
__dirname,
"..",
"detail-template.html",
);
const detailTemplate = fs.readFileSync(DETAIL_TEMPLATE_PATH, "utf-8");

// 각 플러그인의 상세 페이지 생성
Expand Down
9 changes: 9 additions & 0 deletions plugins/code-verifier-agents/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"name": "naverpay-code-verifier",
"description": "Automates changeset generation.",
"author": {
"name": "NaverPayDev"
},
"repository": "https://github.com/NaverPayDev/naverpay-plugins",
"keywords": ["naverpay", "claude-plugin", "claude", "plugin", "code-verifier"]
}
20 changes: 20 additions & 0 deletions plugins/code-verifier-agents/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Code Verifier Plugin

코드 작업 전후 동작이 동일한지, 사이드 이펙트는 없을지 검증하는 sub agent를 제공합니다.

## 설치

```
/plugin install naverpay-code-verifier@naverpay-plugins
```

## 주요 기능

- **테스트 기반 동작 검증**: 리팩터링 전후로 테스트를 실행하여 기존 동작이 유지되는지 자동 비교
- **정적 분석을 통한 영향도 파악**: 변경된 함수/클래스 식별, 의존성(호출 관계) 분석, 시그니처 변경 감지, 타입 변경 영향 분석
- **사이드 이펙트 추론**: 전역 상태 변경, 비동기 동작 변경, 오류 처리 변경, 성능 영향 등 잠재적 사이드 이펙트를 자동으로 식별
- **안전한 Git 기반 워크플로우**: git stash를 활용하여 변경사항을 보존하며, 오류 발생 시 원래 상태로 자동 복원

### 사용법

- 자연어로 명령합니다. ex) 사이드 이펙트가 없을지 확인해줘
Loading