MCP HubMCP Hub
SKILL·4A7C91

open-sourcing

trailofbits
업데이트됨 25 days ago
5 조회
6,849
586
6,849
GitHub에서 보기
메타wordautomation

정보

이 스킬은 구조화된 워크플로우를 제공하여 개발자가 비공개 저장소를 공개 릴리스에 대비하도록 돕습니다. 비밀 정보 감사, 라이선스 선택, 문서 개선, CI/CD 및 패키징 설정과 같은 핵심 단계를 다룹니다. 사용자가 프로젝트를 오픈소스화하거나 준비 상태를 점검하거나 릴리스 과정을 자동화하려 할 때 활용하세요.

빠른 설치

Claude Code

추천
기본
npx skills add trailofbits/skills -a claude-code
플러그인 명령대체
/plugin add https://github.com/trailofbits/skills
Git 클론대체
git clone https://github.com/trailofbits/skills.git ~/.claude/skills/open-sourcing

Claude Code에서 이 명령을 복사하여 붙여넣어 스킬을 설치하세요

문서

Open-Sourcing a Repository

Prepare a repository for public release so that an outsider with no prior context can build, use, and contribute to it — and so that nothing sensitive ships with it. Work through the steps in order; the secrets audit comes first because its outcome (keeping vs. recreating the repository) affects everything after it.

When to Use

  • Making a private repository public
  • Auditing an existing public repository for release quality ("make it official")
  • Choosing a license for a project
  • Setting up packaging, versioning, or release automation ahead of a public launch

When NOT to Use

  • Routine development on an already-released project (no release event)
  • Auditing third-party code for vulnerabilities (use a security-review skill)
  • Publishing a package from a repository that will stay private — only the release-management steps apply; skip the rest

Workflow

Step 1: Detect the organization profile

bash {baseDir}/scripts/detect_org.sh

The script inspects git remotes and recent committer emails, and prints a profile name. If it prints trailofbits, read references/trailofbits.md now and apply its license policy, publishing accounts, and process notes throughout the remaining steps. If it prints generic, proceed with the generic guidance alone. If the user says the detection is wrong, trust the user.

Step 2: Audit for secrets — before anything else

A repository that has ever contained secrets (API keys, credentials, client data) should not be flipped public. History rewriting is error-prone and does not reach forks, caches, or CI artifacts. The reliable fix is a fresh repository: copy the current tree over, commit, and archive the old repository privately.

  1. Ask whether the project ever handled secrets or client-confidential material. For a security consultancy's tooling, also ask whether test fixtures or example data came from client engagements.
  2. Scan the full history with a dedicated tool if available — gitleaks git . or trufflehog git file://. — rather than eyeballing.
  3. Check beyond the git tree: GitHub Actions logs and artifacts, old releases, issue and PR history, and the repository wiki all become public with the repository.
  4. After going public, enable GitHub secret scanning and push protection in the repository settings.

Reject these rationalizations — this is the one step that cannot be fixed after publication:

  • "The key was revoked, so the history is fine." Revoked credentials still leak infrastructure names, internal URLs, and patterns attackers use for targeting.
  • "We'll rewrite history with git-filter-repo." Rewrites miss forks, clones, caches, and CI artifacts; the fresh-repository approach does not.
  • "It's only test data." Fixtures derived from client engagements or production systems are confidential regardless of how they are labeled.

Step 3: Run the readiness check

bash {baseDir}/scripts/check_readiness.sh

The script prints a checklist of presence indicators (README, LICENSE, CONTRIBUTING, SECURITY.md, CI, tests, semver tags, ...) and warns about tracked files that commonly contain secrets. Treat unchecked items as discussion prompts, not hard failures — a research prototype does not need everything a flagship library needs. Walk through the gaps with the user and fix the ones that matter for this project.

Step 4: Documentation

The README is the project's front door. Confirm it explains:

  • What the project is and what problem it solves (first paragraph)
  • How to install it — package manager, container image, or build from source; a fresh-clone build must work using only what is in the repository
  • How to use it — at least one concrete, copy-pasteable example
  • How to contribute — inline or via CONTRIBUTING.md
  • The license — a short section naming it

Also add:

  • SECURITY.md with vulnerability-reporting instructions (a contact address or GitHub private vulnerability reporting). For security tooling this is table stakes.
  • API documentation, built and hosted (GitHub Pages via CI is the usual route), linked from the README and the repository website field. See the language references below for per-ecosystem doc tooling.
  • A code of conduct if the project expects outside contributors.

Step 5: Licensing

No license means not open source, regardless of visibility. Read references/licensing.md for selection criteria and mechanics. The short version:

  1. Apply the organization's policy if one was detected in Step 1.
  2. Otherwise: Apache 2.0 as the permissive default, AGPLv3 when private modification by competitors is a real concern, Creative Commons for non-code artifacts.
  3. Add the LICENSE file, set SPDX identifiers in package metadata, state the license in the README, and verify all three agree.

Step 6: Tests and CI

  • Confirm the test suite exists and passes; a public repository with a failing default branch signals abandonment.
  • Ensure CI runs the tests on every PR, across the supported language-version and platform matrix.
  • Enforce formatting and linting in CI (per-language tooling in the references below), so style debates never reach review.
  • Respect existing tooling. Do not replace a working formatter, linter, or type checker as part of open-sourcing. If it lags the current generation (the language references name the current tools), warn the maintainer and let them decide; only when a category is missing entirely — no type checker, no formatter — add the current default.
  • Consider a coverage gate that fails CI when coverage drops.
  • Harden the workflows themselves before they become public attack surface:
    • Pin third-party actions to full commit SHAs; enable Dependabot for github-actions so pins stay current.
    • Set least-privilege permissions: blocks (start from permissions: {}).
    • Audit with zizmor .github/workflows/ and lint with actionlint.

Step 7: Repository settings

  • Branch protection on the default branch: no force pushes, PRs required. Prefer rulesets for new repositories; classic branch protection remains supported.
  • Merge protection: required status checks so PRs cannot merge with failing tests.
  • Dependabot or Renovate for dependency and Actions updates. Group updates to cut PR noise, and set a cooldown window (e.g., 7 days) so freshly published — and occasionally hijacked — versions age before adoption.
  • .editorconfig so contributors' editors agree on whitespace basics.
  • Labels: create them as soon as more than one issue or PR needs one; prefixes for facets scale well (C: component, P: platform). See blight's labels for a worked example.

Step 8: Releases and versioning

  • Tag every release vX.Y.Z, following semver; use -rc.N / -pre.N suffixes for release candidates and prereleases.
  • Make releases CI-driven: pushing a tag (or publishing a GitHub Release) triggers build, packaging, and upload with no manual steps. A release should be git tag vX.Y.Z && git push origin vX.Y.Z.
  • Publish packages under an organization-owned account, not a personal one, and use trusted publishing (OIDC) instead of long-lived tokens wherever the index supports it.

Step 9: Language-specific practices

Identify the project's languages from its marker files and read the matching reference for packaging, publishing, and quality tooling:

Marker fileReference
pyproject.toml, setup.pyreferences/python.md — defers to the modern-python skill for tooling
CMakeLists.txt, Makefile (C/C++)references/c-cpp.md
Cargo.tomlreferences/rust.md
go.modreferences/go.md
package.jsonreferences/javascript.md
Gemfile, *.gemspecreferences/ruby.md

For other ecosystems, apply the cross-cutting principles: reproducible builds from a fresh clone, CI-driven releases, trusted publishing or organization-owned accounts, and license metadata in the package manifest.

Final Review

Before the visibility switch is flipped, verify from an outsider's perspective:

  1. Clone into a clean directory and follow the README's build instructions verbatim — do they work with no tribal knowledge?
  2. Re-run {baseDir}/scripts/check_readiness.sh and confirm the remaining gaps are deliberate choices, stated to the user.
  3. Confirm the secrets audit (Step 2) actually happened; it is the one step that cannot be fixed after publication.

Making the repository public is then a repository-settings change. Pair the release with an announcement where the organization has a process for one.

Additional Resources

Reference Files

Scripts

  • scripts/detect_org.sh — prints the organization profile (trailofbits or generic) from git remotes and committer emails
  • scripts/check_readiness.sh — prints presence indicators for release-readiness files and flags tracked files that commonly hold secrets

GitHub 저장소

trailofbits/skills
경로: plugins/open-sourcing/skills/open-sourcing
0
agent-skills
FAQ

자주 묻는 질문

open-sourcing Skill이란 무엇인가요?

open-sourcing은(는) trailofbits이(가) 만든 Claude Skill입니다. Skill은 Claude가 필요할 때 불러오는 지침과 리소스를 묶어 추가 프롬프트 없이 open-sourcing 관련 작업을 수행할 수 있게 합니다.

open-sourcing은(는) 어떻게 설치하나요?

이 페이지의 설치 명령을 사용하세요. open-sourcing을(를) Claude Code 플러그인으로 추가하거나 저장소를 skills 디렉터리에 복제한 다음 Claude를 다시 시작해 Skill을 불러옵니다.

open-sourcing은(는) 어떤 카테고리에 속하나요?

open-sourcing은(는) 메타 카테고리에 속합니다.

open-sourcing은(는) 무료로 사용할 수 있나요?

네. open-sourcing은(는) AIMCP에 등록되어 있으며 무료로 설치할 수 있습니다.

연관 스킬

content-collections
메타

이 스킬은 콘텐츠 콜렉션(Content Collections)을 위한 프로덕션 검증된 설정을 제공합니다. 콘텐츠 콜렉션은 Markdown/MDX 파일을 Zod 검증이 포함된 타입 안전한 데이터 콜렉션으로 변환해주는 TypeScript 최우선 도구입니다. 블로그, 문서 사이트 또는 콘텐츠 중심의 Vite + React 애플리케이션을 구축할 때 타입 안전성과 자동 콘텐츠 검증을 보장하기 위해 사용하세요. Vite 플러그인 구성과 MDX 컴파일부터 배포 최적화 및 스키마 검증에 이르기까지 모든 것을 다룹니다.

스킬 보기
polymarket
메타

이 스킬은 개발자들이 Polymarket 예측 시장 플랫폼을 활용한 애플리케이션을 구축할 수 있도록 지원하며, 거래 및 시장 데이터를 위한 API 통합 기능을 포함합니다. 또한 WebSocket을 통한 실시간 데이터 스트리밍을 제공하여 실시간 거래와 시장 활동을 모니터링할 수 있습니다. 이를 통해 거래 전략을 구현하거나 실시간 시장 업데이트를 처리하는 도구를 생성하는 데 활용할 수 있습니다.

스킬 보기
creating-opencode-plugins
메타

이 스킬은 개발자들이 명령어, 파일, LSP 작업 등 25개 이상의 이벤트 유형에 연결되는 OpenCode 플러그인을 만들 수 있도록 돕습니다. JavaScript/TypeScript 모듈을 위한 플러그인 구조, 이벤트 API 명세, 구현 패턴을 제공합니다. OpenCode AI 어시스턴트의 라이프사이클을 사용자 정의 이벤트 기반 로직으로 가로채거나, 모니터링하거나, 확장해야 할 때 사용하세요.

스킬 보기
sglang
메타

SGLang은 RadixAttention 프리픽스 캐싱을 활용하여 JSON, 정규식, 에이전트 워크플로우를 위한 고속 구조화 생성에 특화된 고성능 LLM 서빙 프레임워크입니다. 특히 반복되는 프리픽스가 있는 작업에서 상당히 빠른 추론 속도를 제공하여 복잡한 구조화 출력 및 다중 턴 대화에 이상적입니다. 제약 디코딩이 필요하거나 광범위한 프리픽스 공유가 있는 애플리케이션을 구축할 때는 vLLM과 같은 대안보다 SGLang을 선택하십시오.

스킬 보기