Communitygithub.com

오픈소스 파이프라인

포크, 정리, 패키징을 통해 비공개 프로젝트를 안전하게 오픈소스로 공개합니다. 3개 에이전트(forker, sanitizer, packager)를 연쇄 실행합니다.

오픈소스 파이프라인란 무엇인가요?

이 스킬은 비공개 저장소를 안전하게 오픈소스로 전환하는 3단계 파이프라인을 제공합니다. 1) 포크 단계에서는 비밀 정보를 제거하고 내부 참조를 대체하며 .env.example을 생성합니다. 2) 정리 단계에서는 비밀, 개인정보, 내부 참조, 위험 파일 등을 검사하여 통과/실패를 판정합니다. 3) 패키징 단계에서는 CLAUDE.md, setup.sh, README, LICENSE, CONTRIBUTING.md 등의 오픈소스 패키지를 자동 생성합니다. 사용자 승인 후 GitHub에 퍼블리시하며, 정리 단계에서 실패 시 최대 3회 재시도 후 수동 수정을 유도합니다. 지원되는 플랫폼은 Claude Code, Cursor, Codex 등 AI 에이전트 기반 도구이며, `/opensource fork`, `/opensource verify`, `/opensource package` 명령어로 작동합니다.

지원 대상✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/affaan-m/everything-claude-code/tree/main/skills/opensource-pipeline

즐겨 사용하는 AI에게 물어보기

이 에이전트 스킬이 미리 로드된 새 채팅을 엽니다.

문서

오픈소스 파이프라인 스킬

모든 프로젝트를 3단계 파이프라인을 통해 안전하게 오픈소스화하세요: 포크 (비밀 정보 제거) → 정리 (깨끗한지 확인) → 패키징 (CLAUDE.md + setup.sh + README).

활성화 시점

  • 사용자가 "이 프로젝트를 오픈소스로 해줘" 또는 "이것을 공개해 줘"라고 말할 때
  • 사용자가 비공개 저장소를 공개 릴리스용으로 준비하려고 할 때
  • 사용자가 GitHub에 푸시하기 전에 비밀 정보를 제거해야 할 때
  • 사용자가 /opensource fork, /opensource verify, 또는 /opensource package를 호출할 때

명령어

명령어동작
/opensource fork PROJECT전체 파이프라인: 포크 + 정리 + 패키징
/opensource verify PROJECT기존 저장소에 대해 정리 도구 실행
/opensource package PROJECTCLAUDE.md + setup.sh + README 생성
/opensource list준비된 모든 프로젝트 표시
/opensource status PROJECT준비된 프로젝트의 보고서 표시

프로토콜

/opensource fork PROJECT

전체 파이프라인 — 주요 워크플로.

1단계: 매개변수 수집

프로젝트 경로를 확인합니다. PROJECT에 /가 포함되어 있으면 경로(절대 또는 상대)로 처리합니다. 그렇지 않으면 현재 작업 디렉토리, $HOME/PROJECT를 확인한 후 사용자에게 질문합니다.

SOURCE_PATH="<확인된 절대 경로>"
STAGING_PATH="$HOME/opensource-staging/${PROJECT_NAME}"

사용자에게 질문:

  1. "어떤 프로젝트인가요?" (찾을 수 없는 경우)
  2. "라이선스는 무엇인가요? (MIT / Apache-2.0 / GPL-3.0 / BSD-3-Clause)"
  3. "GitHub 조직 또는 사용자명은?" (기본값: gh api user -q .login으로 감지)
  4. "GitHub 저장소 이름은?" (기본값: 프로젝트 이름)
  5. "README 설명은?" (프로젝트를 분석하여 제안)

2단계: 스테이징 디렉토리 생성

mkdir -p $HOME/opensource-staging/

3단계: 포커 에이전트 실행

opensource-forker 에이전트를 생성합니다:

Agent(
  description="오픈소스용 {PROJECT} 포크",
  subagent_type="opensource-forker",
  prompt="""
오픈소스 릴리스를 위해 프로젝트를 포크하세요.

소스: {SOURCE_PATH}
대상: {STAGING_PATH}
라이선스: {chosen_license}

전체 포크 프로토콜을 따르세요:
1. 파일 복사 (.git, node_modules, __pycache__, .venv 제외)
2. 모든 비밀 정보와 자격 증명 제거
3. 내부 참조를 플레이스홀더로 대체
4. .env.example 생성
5. Git 히스토리 정리
6. {STAGING_PATH}/FORK_REPORT.md에 FORK_REPORT.md 생성
"""
)

완료될 때까지 기다립니다. {STAGING_PATH}/FORK_REPORT.md를 읽습니다.

4단계: 정리 에이전트 실행

opensource-sanitizer 에이전트를 생성합니다:

Agent(
  description="{PROJECT} 정리 확인",
  subagent_type="opensource-sanitizer",
  prompt="""
오픈소스 포크의 정리 상태를 확인하세요.

프로젝트: {STAGING_PATH}
소스 (참조용): {SOURCE_PATH}

모든 검사 범주를 실행하세요:
1. 비밀 검사 (치명적)
2. 개인정보 검사 (치명적)
3. 내부 참조 검사 (치명적)
4. 위험 파일 확인 (치명적)
5. 설정 완전성 (경고)
6. Git 히스토리 감사

{STAGING_PATH}/ 내에 PASS/FAIL 판정과 함께 SANITIZATION_REPORT.md를 생성하세요.
"""
)

완료될 때까지 기다립니다. {STAGING_PATH}/SANITIZATION_REPORT.md를 읽습니다.

FAIL인 경우: 사용자에게 결과를 보여줍니다. "수정 후 재검사하시겠습니까, 아니면 중단하시겠습니까?"라고 질문합니다.

  • 수정: 수정을 적용하고 정리 도구를 다시 실행합니다 (최대 3회 재시도 — 3회 FAIL 후에는 모든 결과를 제시하고 사용자에게 직접 수정 요청)
  • 중단: 스테이징 디렉토리를 정리합니다

PASS 또는 PASS WITH WARNINGS인 경우: 5단계로 진행합니다.

5단계: 패키저 에이전트 실행

opensource-packager 에이전트를 생성합니다:

Agent(
  description="오픈소스용 {PROJECT} 패키징",
  subagent_type="opensource-packager",
  prompt="""
프로젝트의 오픈소스 패키징을 생성하세요.

프로젝트: {STAGING_PATH}
라이선스: {chosen_license}
프로젝트 이름: {PROJECT_NAME}
설명: {description}
GitHub 저장소: {github_repo}

생성:
1. CLAUDE.md (명령어, 아키텍처, 주요 파일)
2. setup.sh (원클릭 부트스트랩, 실행 가능하게)
3. README.md (또는 기존 파일 개선)
4. LICENSE
5. CONTRIBUTING.md
6. .github/ISSUE_TEMPLATE/ (bug_report.md, feature_request.md)
"""
)

6단계: 최종 검토

사용자에게 표시:

오픈소스 포크 준비 완료: {PROJECT_NAME}

위치: {STAGING_PATH}
라이선스: {license}
생성된 파일:
  - CLAUDE.md
  - setup.sh (실행 가능)
  - README.md
  - LICENSE
  - CONTRIBUTING.md
  - .env.example ({N}개 변수)

정리 상태: {sanitization_verdict}

다음 단계:
  1. 검토: cd {STAGING_PATH}
  2. 저장소 생성: gh repo create {github_org}/{github_repo} --public
  3. 푸시: git remote add origin ... && git push -u origin main

GitHub 생성을 진행하시겠습니까? (yes/no/review first)

7단계: GitHub 퍼블리시 (사용자 승인 시)

cd "{STAGING_PATH}"
gh repo create "{github_org}/{github_repo}" --public --source=. --push --description "{description}"

/opensource verify PROJECT

정리 도구를 독립적으로 실행합니다. 경로 확인: PROJECT에 /가 포함되어 있으면 경로로 처리합니다. 그렇지 않으면 $HOME/opensource-staging/PROJECT, $HOME/PROJECT, 현재 디렉토리 순서로 확인합니다.

Agent(
  subagent_type="opensource-sanitizer",
  prompt="{resolved_path} 정리 확인. 6개 검사 범주 모두 실행하고 SANITIZATION_REPORT.md 생성."
)

/opensource package PROJECT

패키저를 독립적으로 실행합니다. "라이선스는?"과 "설명은?"을 질문한 후:

Agent(
  subagent_type="opensource-packager",
  prompt="패키징: {resolved_path} ..."
)

/opensource list

ls -d $HOME/opensource-staging/*/

각 프로젝트를 파이프라인 진행 상태(FORK_REPORT.md, SANITIZATION_REPORT.md, CLAUDE.md 존재 여부)와 함께 표시합니다.


/opensource status PROJECT

cat $HOME/opensource-staging/${PROJECT}/SANITIZATION_REPORT.md
cat $HOME/opensource-staging/${PROJECT}/FORK_REPORT.md

스테이징 구조

$HOME/opensource-staging/
  my-project/
    FORK_REPORT.md           # 포커 에이전트에서 생성
    SANITIZATION_REPORT.md   # 정리 에이전트에서 생성
    CLAUDE.md                # 패키저 에이전트에서 생성
    setup.sh                 # 패키저 에이전트에서 생성
    README.md                # 패키저 에이전트에서 생성
    .env.example             # 포커 에이전트에서 생성
    ...                      # 정리된 프로젝트 파일

안티패턴

  • 사용자 승인 없이 절대 GitHub에 푸시하지 마세요
  • 정리 도구를 절대 건너뛰지 마세요 — 안전 게이트입니다
  • 모든 치명적 문제를 수정하지 않고 정리 도구가 FAIL한 후에 절대 진행하지 마세요
  • 스테이징 디렉토리에 .env, *.pem, 또는 credentials.json을 절대 남겨두지 마세요

모범 사례

  • 새 릴리스는 항상 전체 파이프라인(포크 → 정리 → 패키징)을 실행하세요
  • 스테이징 디렉토리는 명시적으로 정리될 때까지 유지됩니다 — 검토에 사용하세요
  • 퍼블리시 전에 수동 수정 후 정리 도구를 다시 실행하세요
  • 비밀 정보를 삭제하지 말고 매개변수화하여 프로젝트 기능을 유지하세요

관련 스킬

정리 도구에서 사용하는 비밀 감지 패턴은 security-review를 참조하세요.

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

accessibility

Design, implement, and audit inclusive digital products using WCAG 2.2 Level AA. Use when building or auditing UI that must meet WCAG 2.2 Level AA, or when reviewing a change for keyboard, contrast, or screen-reader support.

affaan-m/claude-api

Anthropic Claude API patterns for Python and TypeScript. Covers Messages API, streaming, tool use, vision, extended thinking, batches, prompt caching, and Claude Agent SDK. Use when building applications with the Claude API or Anthropic SDKs.

affaan-m/everything-claude-code

End-to-end marketing campaign planning and execution. Covers audience research, positioning, campaign angle definition, landing page copy, email sequences, social posts, ad copy, short-form video scripts, and content calendars. Use as the orchestration layer for multi-channel product launches. Use when planning or executing a multi-channel product launch, or producing landing page, email, social, or ad copy.

affaan-m/everything-claude-code

Development conventions and patterns for everything-claude-code. JavaScript project with conventional commits.

affaan-m/everything-claude-code-conventions

Development conventions and patterns for everything-claude-code. JavaScript project with conventional commits.

affaan-m/frontend-design

Create distinctive, production-grade frontend interfaces with high design quality. Use when the user asks to build web components, pages, or applications and the visual direction matters as much as the code quality.

affaan-m/gget

gget CLI and Python workflow for quick genomic database queries, sequence lookup, BLAST-style searches, enrichment checks, and reproducible bioinformatics evidence logs.

affaan-m/literature-review

Systematic literature-review workflow for academic, biomedical, technical, and scientific topics, including search planning, source screening, synthesis, citation checks, and evidence logging.

affaan-m/motion-ui

Production-ready UI motion system for React/Next.js. Use when implementing animations, transitions, or motion patterns.

affaan-m/project-guidelines-example

Example project-specific skill template based on a real production application.

affaan-m/pubmed-database

Direct PubMed and NCBI E-utilities search workflows for biomedical literature, MeSH queries, PMID lookup, citation retrieval, and API-backed literature monitoring.

affaan-m/scholar-evaluation

Structured scholarly-work evaluation for papers, proposals, literature reviews, methods sections, evidence quality, citation support, and research-writing feedback.

affaan-m/uspto-database

USPTO patent and trademark data workflow for official record lookup, PatentSearch queries, TSDR checks, assignment data, and reproducible IP research logs.

agent-architecture-audit

Full-stack diagnostic for agent and LLM applications. Audits the 12-layer agent stack for wrapper regression, memory pollution, tool discipline failures, hidden repair loops, and rendering corruption. Produces severity-ranked findings with code-first fixes. Essential for developers building agent applications, autonomous loops, or any LLM-powered feature. Use when an agent or LLM feature misbehaves and the failing layer is unknown, or before shipping an agent stack.

agent-eval

Head-to-head comparison of coding agents (Claude Code, Aider, Codex, etc.) on custom tasks with pass rate, cost, time, and consistency metrics. Use when choosing between coding agents, or when a change to an agent setup needs measured pass rate, cost, and time rather than an impression.

agent-harness-construction

Design and optimize AI agent action spaces, tool definitions, and observation formatting for higher completion rates. Use when defining or revising an agent

agentic-engineering

Operate as an agentic engineer using eval-first execution, decomposition, and cost-aware model routing. Use when planning or executing engineering work that agents will carry out end to end.

agentic-os

Build persistent multi-agent operating systems on Claude Code. Covers kernel architecture, specialist agents, slash commands, file-based memory, scheduled automation, and state management without external databases. Use when building a persistent multi-agent system on Claude Code with its own memory, commands, and scheduling.

agent-introspection-debugging

Structured self-debugging workflow for AI agent failures using capture, diagnosis, contained recovery, and introspection reports. Use when an agent run fails and you need a reproducible diagnosis instead of a retry.

agent-payment-x402

Add x402 payment execution to AI agents with per-task budgets, spending controls, and non-custodial wallets. Supports Base through agentwallet-sdk and X Layer through OKX Payments / OKX Agent Payments Protocol. Use when an agent must pay for something itself and needs per-task budgets, spending controls, and a non-custodial wallet.

관련 스킬