설정

언어

Claude Code Skills: AI 코딩 어시스턴트를 위한 맞춤형 워크플로우 구축하기

L
LemonData
·2026년 2월 26일·59 조회수
#Claude Code#기술#개발자 도구#튜토리얼#생산성
Claude Code Skills: AI 코딩 어시스턴트를 위한 맞춤형 워크플로우 구축하기

Claude Code 스킬: AI 코딩 어시스턴트를 위한 맞춤형 워크플로우 구축하기

Claude Code는 범용 AI 어시스턴트와 함께 제공됩니다. 스킬은 이를 전문화할 수 있게 해줍니다. 스킬은 Claude Code에게 특정 작업 유형을 처리하는 방법을 가르치는 마크다운 파일입니다: Kubernetes 배포, 데이터베이스 마이그레이션 작성, 풀 리퀘스트 리뷰, 또는 팀의 코딩 규칙 준수 등.

"React 컴포넌트를 작성해줘"와 "우리 디자인 시스템을 따르고, 커스텀 훅을 사용하며, 적절한 에러 바운더리와 접근성 속성을 갖춘 React 컴포넌트를 작성해줘"의 차이가 바로 스킬입니다.

스킬이란 무엇인가

스킬은 .claude/commands/ (프로젝트 레벨) 또는 ~/.claude/commands/ (글로벌) 폴더에 위치한 마크다운 파일입니다. Claude Code에서 /skill-name을 입력하면, 해당 파일의 내용이 지침으로 대화에 주입됩니다.

.claude/
  commands/
    deploy.md          # /deploy
    review-pr.md       # /review-pr
    write-test.md      # /write-test

이게 전부입니다. 특별한 문법도, 컴파일도, SDK도 필요 없습니다. 단지 무언가를 수행하는 방법을 설명하는 마크다운일 뿐입니다.

첫 번째 스킬 작성하기

실용적인 예시를 들어보겠습니다: 팀의 커밋 메시지 규칙을 강제하는 스킬입니다.

.claude/commands/commit.md 파일을 만드세요:

# Commit Workflow

## Steps
1. Run `git diff --staged` to see what's being committed
2. Analyze the changes and categorize: feat, fix, refactor, docs, test, chore
3. Write a commit message following our convention:
   - Format: `type(scope): description`
   - Scope is the package or module name
   - Description is imperative mood, lowercase, no period
   - Body explains WHY, not WHAT
4. If changes touch multiple scopes, create separate commits
5. Run `git commit -m "message"` with the generated message

## Rules
- Never use `--no-verify` to skip hooks
- Never amend published commits
- If tests fail in pre-commit, fix the issue first

## Examples
- `feat(billing): add stripe webhook handler`
- `fix(auth): handle expired refresh tokens`
- `refactor(api): extract rate limiter to shared package`

이제 /commit 명령은 막연한 "내 변경사항을 커밋해줘" 지시 대신 구조화된 워크플로우를 Claude Code에 제공합니다.

스킬 설계 패턴

체크리스트 패턴

여러 검증 단계가 필요한 작업에 적합합니다.

# Pre-Deploy Checklist

Before deploying, verify each item:

- [ ] `pnpm typecheck` passes
- [ ] `pnpm test` passes
- [ ] No console.log statements in production code
- [ ] Environment variables documented in .env.example
- [ ] Database migrations are reversible
- [ ] API changes are backward compatible

If any check fails, stop and report the issue. Do not proceed with deployment.

의사결정 트리 패턴

상황에 따라 접근 방식이 달라지는 작업에 적합합니다.

# Bug Fix Workflow

1. Reproduce the bug (find or write a failing test)
2. Identify the root cause:
   - If it's a type error → fix the type definition at the source
   - If it's a race condition → add proper locking/sequencing
   - If it's a missing validation → add schema validation at the boundary
   - If it's a logic error → fix and add regression test
3. Verify the fix doesn't break existing tests
4. Write a test that would have caught this bug

템플릿 패턴

일관된 출력을 생성하는 데 적합합니다.

# New API Endpoint

Create a new API endpoint following our conventions:

## File Structure
- Route handler: `apps/api/src/routes/{resource}/{action}.ts`
- Schema: `apps/api/src/schemas/{resource}.ts`
- Test: `apps/api/src/routes/{resource}/__tests__/{action}.test.ts`

## Required Elements
- Zod schema for request validation
- Authentication middleware
- Rate limiting
- Structured error responses using errorResponse()
- Success responses using successResponse()
- OpenAPI documentation comments

커뮤니티 스킬 설치하기

Claude Code 생태계에는 점점 더 많은 커뮤니티 스킬 라이브러리가 있습니다. 다음 명령어로 설치하세요:

npx add-skill username/repo-name -y

인기 있는 스킬 모음:

  • coreyhaines31/marketingskills (29개의 마케팅/SEO 스킬)
  • hedging8563/lemondata-api-skill (LemonData API 통합)

설치된 스킬은 ~/.claude/commands/에 나타나며 모든 프로젝트에서 사용할 수 있습니다.

프로젝트 스킬 vs 글로벌 스킬

위치 범위 사용 사례
.claude/commands/ 해당 프로젝트만 프로젝트 규칙, 배포 워크플로우
~/.claude/commands/ 모든 프로젝트 개인 선호, 일반 도구

프로젝트 스킬은 팀 전체가 혜택을 받도록 저장소에 커밋해야 합니다. 글로벌 스킬은 개인 워크플로우 선호에 맞게 사용하세요.

고급: 훅이 포함된 스킬

스킬은 특정 이벤트에서 실행되는 셸 명령인 훅을 참조하여 자동화된 강제를 할 수 있습니다:

# Pre-Commit Check

Before any commit, the following hooks run automatically:
- `pre-commit`: runs typecheck + lint
- `post-commit`: updates changelog

If a hook fails, investigate the error output and fix the issue.
Do not use --no-verify to bypass hooks.

훅 자체는 .claude/settings.json에서 설정됩니다:

{
  "hooks": {
    "pre-commit": "pnpm typecheck && pnpm lint-staged"
  }
}

효과적인 스킬 작성 팁

  1. 파일 경로와 명명 규칙을 구체적으로 명시하세요. "컴포넌트 생성"은 모호합니다. "PascalCase 명명법을 사용해 src/components/ui/에 컴포넌트 생성"은 실행 가능하고 명확합니다.

  2. 올바른 출력 예시를 포함하세요. Claude Code는 추상적인 규칙보다 예시에서 더 잘 학습합니다.

  3. 하지 말아야 할 것을 정의하세요. "절대 any 타입을 사용하지 마세요"가 "적절한 타입을 사용하세요"보다 더 강제력이 있습니다.

  4. 스킬은 집중적으로 유지하세요. 워크플로우 당 하나의 스킬. 모든 것을 다루는 200줄짜리 스킬보다, 각각 한 가지 작업을 잘 처리하는 40줄짜리 스킬 다섯 개가 더 유용합니다.

  5. 스킬 버전을 관리하세요. 규칙이 진화하면 스킬도 업데이트하세요. 오래된 스킬은 구식 패턴을 강제하기 때문에 없는 것보다 해롭습니다.

실제 효과

스킬을 도입한 팀들은 다음과 같은 꾸준한 개선을 보고합니다:

  • 리뷰 전에 규칙이 강제되어 코드 리뷰 주기가 단축됨
  • 신입 개발자도 베테랑과 동일한 가이드를 받아 온보딩 시간이 단축됨
  • AI가 프로젝트 표준에 대한 명확한 맥락을 갖게 되어 AI 생성 코드 품질 향상

투자 시간은 적습니다(처음 몇 개 스킬 작성에 30분)만, 상호작용할수록 효과가 누적됩니다.


AI와 함께 구축하고, 자신만의 규칙으로 안내하세요. lemondata.cc는 AI 기반 개발 도구를 위한 API 인프라를 제공합니다.

Share: