Open Source Project Polish
One-pass workflow to turn a bare repo into a professional, discoverable open source
project. Four phases: README → topics/About → commit-history narrative → trending-repo
positioning.
When to use
- Preparing a project for public release or first launch
- Repo has working code but a bare README, missing topics, or no About description
- Want a commit-history narrative (
REPOSITORY_SUMMARY.md + THE_STORY_OF_THIS_REPO.md)
- Researching trending repos in a domain for positioning benchmarking
Not for: open source business model or commercialization strategy (use oss-strategy), or general project documentation (use documentation-audit).
Steps
1. Analyze project
- Read entry files (
package.json, go.mod, Cargo.toml, requirements.txt, mkdocs.yml).
- Scan source dirs for architecture and key features; note tech stack, target users, unique value.
- Check existing
README.md and repo metadata.
- If
README.md exists, ask: update in place or back up to README-backup.md first?
Result: a one-paragraph summary of what the project does, who it's for, and what's special.
2. Generate README
Produce a professional README.md with sections in this order:
- Title (H1) — repository name.
- Badges — shields.io format. Order: build status → tech stack → hosting → license.
Pick templates from
references/badges.md. Limit 5–10 for readability. Do NOT add a
self-link "GitHub repo" badge — readers are already on GitHub.
- Live site link — if deployed (GitHub Pages, Netlify, Vercel).
- Overview — 1–3 paragraphs answering what / who / why / unique. Hook a visitor in <15s.
- Site metrics (documentation/educational repos) — for content-heavy repos (docs sites,
courses), run
python references/scripts/collect-site-metrics.py <repo-path>; emit a
| Metric | Count | table (markdown files, words, chapters, glossary…). For code-focused
repos, skip this step — github_fetcher.py covers repo metrics instead.
- Getting Started — prerequisites, clone, install, build/serve, deploy.
- Repository Structure — concise ASCII tree (10–20 lines), representative not exhaustive.
- Reporting Issues — link to GitHub Issues + bug-report template.
- License — match
LICENSE file / mkdocs.yml copyright; default CC BY 4.0 for
educational content (CC BY-SA if share-alike is desired); reserve NC (NonCommercial) only for
projects that explicitly restrict commercial use, MIT or Apache-2.0 for code.
- Acknowledgements — key dependencies only.
- Contact — maintainer info.
- Optional — Contributing, Citation (BibTeX), Changelog.
Formatting: ATX headers, blank line before lists, code fences with a language tag, lines <120 chars.
3. Topics & About description
- Research trending repos in the same domain — what topics do they use? Run
python references/scripts/github_fetcher.py with TOPIC=<domain> env var to list repos
by stars; inspect each repo's topics field.
- Identify 8–15 highly relevant topics; rank by discoverability × relevance × search volume.
- Select the final list (max 20 — GitHub limit).
- Write the About description (GitHub allows ≤350 chars): one compelling sentence
covering what + who + why.
Present the final list + rationale to the user before applying. Apply via GitHub API
(PUT /repos/:owner/:repo/topics) and repo settings (description).
4. Commit-history narrative story
Generate two files in the repo root using git data as evidence — write the files directly,
do NOT paste markdown to chat.
REPOSITORY_SUMMARY.md — overview, architecture, key components, technologies, data
flow, team/ownership.
THE_STORY_OF_THIS_REPO.md — chronicles (year in numbers), cast of characters
(contributors + specialties), seasonal patterns, great themes (feat/fix/refactor),
plot twists/turning points, current chapter.
Git commands to run systematically (POSIX forms for Git Bash):
git rev-list --all --count — total commits
git shortlog -sn --since="1 year ago" | head -20 — top contributors
git log --since="1 year ago" --format="%ai" | cut -c1-7 | sort | uniq -c | sort -rn | head -12 — monthly activity
git log --since="1 year ago" --oneline --grep="feat\|fix\|update\|add\|remove" | head -50 — change themes
git log --since="1 year ago" --name-only --oneline — hotspot files
git log --since="1 year ago" --merges --oneline | head -20 — collaboration patterns
Be specific: actual file names, commit messages, contributor names. Evidence-based — explain
why patterns exist (holidays, releases, incidents).
5. Trending-repo positioning
- Run
python references/scripts/github_fetcher.py with TOPIC=<your-domain> to fetch top
repos by stars.
- Run
python references/scripts/readme_fetcher.py (or the batch helper) to pull competitor
README summaries.
- Benchmark: how does this project compare on stars, README quality, topic coverage, positioning?
- Produce: a 5–10 word tagline, recommended launch channels (HN / Reddit / Dev.to /
DevHunt by domain), and a short positioning paragraph noting differentiators.
GH_TOKEN env var is optional but recommended (5000 req/hr authenticated vs 60 unauthenticated).
6. Consolidated report
Output a single report:
# [Project Name] Open Source Polish
## Analysis Summary — what / stack / audience
## README — full content or diff
## Topics & About — About (≤350 chars), topics list, rationale
## Narrative — links to the two generated .md files
## Positioning — tagline, launch plan, differentiators
## Next Steps — apply checklist (README, topics, About, LICENSE)
After user approval, apply changes via your available GitHub tooling — the gh
CLI or GitHub MCP (create_or_update_file for README/LICENSE; GitHub API
PUT /repos/:owner/:repo/topics for topics; repo settings for the About
description).
Output: README.md (polished) + REPOSITORY_SUMMARY.md + THE_STORY_OF_THIS_REPO.md (commit-history narrative), plus topics/About applied via GitHub API.
Verify
References
- ${CLAUDE_PLUGIN_ROOT}/references/engineering-principles.md — discipline every skill shares.
- references/badges.md — shields.io templates by category (languages, hosting, license, status, custom).
- references/scripts/ —
collect-site-metrics.py (README metrics), validate-readme.py (README linter, scores 0–100), github_fetcher.py + readme_fetcher.py + config.py (trending-repo research via GitHub API).
1---2name: oss-polish3description: Use when polishing an open source project's GitHub presence — README, topics/About description, commit-history narrative story, and trending-repo positioning. Triggers on "polish my repo", "beautify open source project", "开源项目美化", "优化项目展示".4---56# Open Source Project Polish78One-pass workflow to turn a bare repo into a professional, discoverable open source9project. Four phases: README → topics/About → commit-history narrative → trending-repo10positioning.1112## When to use1314- Preparing a project for public release or first launch15- Repo has working code but a bare README, missing topics, or no About description16- Want a commit-history narrative (`REPOSITORY_SUMMARY.md` + `THE_STORY_OF_THIS_REPO.md`)17- Researching trending repos in a domain for positioning benchmarking1819**Not for:** open source business model or commercialization strategy (use `oss-strategy`), or general project documentation (use `documentation-audit`).2021## Steps2223### 1. Analyze project24251. Read entry files (`package.json`, `go.mod`, `Cargo.toml`, `requirements.txt`, `mkdocs.yml`).262. Scan source dirs for architecture and key features; note tech stack, target users, unique value.273. Check existing `README.md` and repo metadata.284. If `README.md` exists, ask: update in place or back up to `README-backup.md` first?2930Result: a one-paragraph summary of what the project does, who it's for, and what's special.3132### 2. Generate README3334Produce a professional `README.md` with sections in this order:35361. **Title (H1)** — repository name.372. **Badges** — shields.io format. Order: build status → tech stack → hosting → license.38 Pick templates from `references/badges.md`. Limit 5–10 for readability. Do NOT add a39 self-link "GitHub repo" badge — readers are already on GitHub.403. **Live site link** — if deployed (GitHub Pages, Netlify, Vercel).414. **Overview** — 1–3 paragraphs answering what / who / why / unique. Hook a visitor in <15s.425. **Site metrics (documentation/educational repos)** — for content-heavy repos (docs sites,43 courses), run `python references/scripts/collect-site-metrics.py <repo-path>`; emit a44 `| Metric | Count |` table (markdown files, words, chapters, glossary…). For code-focused45 repos, skip this step — `github_fetcher.py` covers repo metrics instead.466. **Getting Started** — prerequisites, clone, install, build/serve, deploy.477. **Repository Structure** — concise ASCII tree (10–20 lines), representative not exhaustive.488. **Reporting Issues** — link to GitHub Issues + bug-report template.499. **License** — match `LICENSE` file / `mkdocs.yml` copyright; default CC BY 4.0 for50 educational content (CC BY-SA if share-alike is desired); reserve NC (NonCommercial) only for51 projects that explicitly restrict commercial use, MIT or Apache-2.0 for code.5210. **Acknowledgements** — key dependencies only.5311. **Contact** — maintainer info.5412. **Optional** — Contributing, Citation (BibTeX), Changelog.5556Formatting: ATX headers, blank line before lists, code fences with a language tag, lines <120 chars.5758### 3. Topics & About description59601. Research trending repos in the same domain — what topics do they use? Run61 `python references/scripts/github_fetcher.py` with `TOPIC=<domain>` env var to list repos62 by stars; inspect each repo's `topics` field.632. Identify 8–15 highly relevant topics; rank by discoverability × relevance × search volume.643. Select the final list (max 20 — GitHub limit).654. Write the **About description** (GitHub allows ≤350 chars): one compelling sentence66 covering what + who + why.6768Present the final list + rationale to the user before applying. Apply via GitHub API69(`PUT /repos/:owner/:repo/topics`) and repo settings (description).7071### 4. Commit-history narrative story7273Generate two files in the repo root using git data as evidence — write the files directly,74do NOT paste markdown to chat.7576- **`REPOSITORY_SUMMARY.md`** — overview, architecture, key components, technologies, data77 flow, team/ownership.78- **`THE_STORY_OF_THIS_REPO.md`** — chronicles (year in numbers), cast of characters79 (contributors + specialties), seasonal patterns, great themes (feat/fix/refactor),80 plot twists/turning points, current chapter.8182Git commands to run systematically (POSIX forms for Git Bash):8384- `git rev-list --all --count` — total commits85- `git shortlog -sn --since="1 year ago" | head -20` — top contributors86- `git log --since="1 year ago" --format="%ai" | cut -c1-7 | sort | uniq -c | sort -rn | head -12` — monthly activity87- `git log --since="1 year ago" --oneline --grep="feat\|fix\|update\|add\|remove" | head -50` — change themes88- `git log --since="1 year ago" --name-only --oneline` — hotspot files89- `git log --since="1 year ago" --merges --oneline | head -20` — collaboration patterns9091Be specific: actual file names, commit messages, contributor names. Evidence-based — explain92why patterns exist (holidays, releases, incidents).9394### 5. Trending-repo positioning95961. Run `python references/scripts/github_fetcher.py` with `TOPIC=<your-domain>` to fetch top97 repos by stars.982. Run `python references/scripts/readme_fetcher.py` (or the batch helper) to pull competitor99 README summaries.1003. Benchmark: how does this project compare on stars, README quality, topic coverage, positioning?1014. Produce: a 5–10 word **tagline**, recommended **launch channels** (HN / Reddit / Dev.to /102 DevHunt by domain), and a short positioning paragraph noting differentiators.103104`GH_TOKEN` env var is optional but recommended (5000 req/hr authenticated vs 60 unauthenticated).105106### 6. Consolidated report107108Output a single report:109110```111# [Project Name] Open Source Polish112## Analysis Summary — what / stack / audience113## README — full content or diff114## Topics & About — About (≤350 chars), topics list, rationale115## Narrative — links to the two generated .md files116## Positioning — tagline, launch plan, differentiators117## Next Steps — apply checklist (README, topics, About, LICENSE)118```119120After user approval, apply changes via your available GitHub tooling — the `gh`121CLI or GitHub MCP (`create_or_update_file` for README/LICENSE; GitHub API122`PUT /repos/:owner/:repo/topics` for topics; repo settings for the About123description).124125**Output:** `README.md` (polished) + `REPOSITORY_SUMMARY.md` + `THE_STORY_OF_THIS_REPO.md` (commit-history narrative), plus topics/About applied via GitHub API.126127## Verify128129- [ ] README conforms to best practices — run130 `python references/scripts/validate-readme.py README.md`; score ≥75/100 and no missing131 required sections (overview, getting started, license, contact).132- [ ] Topics set on the repo (1–20 topics, all relevant to the project's domain).133- [ ] About description set (≤350 chars, covers what + who + why).134- [ ] Both narrative files (`REPOSITORY_SUMMARY.md`, `THE_STORY_OF_THIS_REPO.md`) exist in repo135 root with complete content (not chat output).136- [ ] Badge URLs resolve; no self-link GitHub-repo badge; all README links work.137- [ ] Positioning report includes tagline, launch channels, and ≥1 differentiator vs trending repos.138139## References140141- [${CLAUDE_PLUGIN_ROOT}/references/engineering-principles.md](${CLAUDE_PLUGIN_ROOT}/references/engineering-principles.md) — discipline every skill shares.142- [references/badges.md](references/badges.md) — shields.io templates by category (languages, hosting, license, status, custom).143- [references/scripts/](references/scripts/) — `collect-site-metrics.py` (README metrics), `validate-readme.py` (README linter, scores 0–100), `github_fetcher.py` + `readme_fetcher.py` + `config.py` (trending-repo research via GitHub API).