star-history-chart
하는 일
이 스킬은 저장소 README에 외부 차트 서비스에 의존하지 않는 스타 히스토리 차트를 설정합니다. 프로젝트 성장을 보여주고 싶은 오픈소스 관리자에게 맞습니다.
사용하는 경우
- ✓GitHub README에 시간에 따른 스타 수 차트를 보여주고 싶을 때.
- ✓저장소의 외부 스타 차트 이미지가 더 이상 로드되지 않을 때.
- ✓GitHub Action으로 차트를 매주 자동 갱신하고 싶을 때.
스킬 링크
https://github.com/davila7/claude-code-templates/blob/main/cli-tool/components/skills/git/star-history-chart/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“제 프로젝트 README에 매주 스스로 업데이트되는 스타 히스토리 차트를 추가해 주세요.”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
에이전트는 스크립트와 GitHub 워크플로 파일을 저장소에 복사합니다. 워크플로는 저장소의 토큰으로 스타를 가져와 밝은 테마와 어두운 테마 SVG를 그리고 매주 커밋합니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
Star History Chart (self-hosted, never breaks)
Add a "Stargazers over time" chart that renders from a static SVG committed to the repo and refreshes itself weekly — no external chart service, no broken images.
Why this exists
GitHub now restricts the /stargazers endpoint to a repository's own admins and
collaborators. Unauthenticated requests return {"message":"Requires authentication"}, which breaks every third-party live-chart service
(star-history.com free tier, starchart.cc, etc.) for all repos. The only
reliable fix is to generate the chart yourself with an authenticated token and
commit a static image. Inside GitHub Actions, the repo's own GITHUB_TOKEN can
read its own stargazers, so the whole thing runs with zero secrets to configure.
What this skill sets up
scripts/generate_star_history.py— fetches stargazers (authenticated), renders a clean, light/dark-adaptive SVG..github/workflows/star-history.yml— weekly cron + manual trigger that regenerates and commitsdocs/star-history.svg.- A README section pointing at the local SVG.
Workflow
Step 1: Copy the script and workflow into the repo
mkdir -p scripts .github/workflows docs
cp skills/git/star-history-chart/scripts/generate_star_history.py scripts/generate_star_history.py
cp skills/git/star-history-chart/assets/star-history.yml .github/workflows/star-history.yml
The script needs the
requestspackage:pip install requests. It resolves the repo fromSTAR_HISTORY_REPO, thenGITHUB_REPOSITORY(set automatically in Actions), then theorigingit remote — so no edits are required for it to work in a different repo.
Step 2: Generate the SVG once, locally
Use a token that can read the repo's stargazers (as owner/collaborator). The GitHub CLI provides one:
GITHUB_TOKEN=$(gh auth token) python scripts/generate_star_history.py
This writes docs/star-history.svg. For a repo with many thousands of stars the
first run paginates the whole stargazer list and can take a couple of minutes.
Verify it rendered (optional, macOS): qlmanage -t -s 800 -o . docs/star-history.svg
Step 3: Add it to the README
Add or replace the star chart section. Point the image at the local SVG. Set the link target to wherever you want clicks to go (the repo, a docs page, or your own site):
## Stargazers over time
[](https://github.com/OWNER/REPO/stargazers)
If replacing a broken star-history.com / starchart.cc embed, swap only the
image URL to docs/star-history.svg and keep or update the link target.
Step 4: Commit
git add scripts/generate_star_history.py .github/workflows/star-history.yml docs/star-history.svg README.md
git commit -m "feat(readme): self-hosted stargazers chart with weekly auto-refresh"
git push
Step 5: (Optional) Trigger the auto-refresh now
The workflow runs every Monday at 04:00 UTC. To refresh immediately without waiting: GitHub → Actions → "Update Star History" → Run workflow.
Customization
- Output path — set
STAR_HISTORY_OUTPUT(defaultdocs/star-history.svg). - Different repo — set
STAR_HISTORY_REPO=owner/name. - Colors / size — edit the
.line,.area,.dotCSS andWIDTH/HEIGHTconstants near the top ofgenerate_star_history.py. The chart is theme-aware via aprefers-color-scheme: darkblock, so it looks right in both GitHub light and dark modes. - Refresh cadence — edit the
cronexpression in the workflow.
Notes
- No secrets to add: the workflow uses the automatic
GITHUB_TOKEN. - Private repos work too, as long as the token can read the repo.
- The script uses only
requestsplus the Python standard library.
자주 묻는 질문
왜 실시간 차트 웹사이트를 쓰지 않나요?
GitHub가 스타 데이터를 저장소 관리자에게만 제한하게 되어, 많은 외부 차트 서비스가 모두에게 작동하지 않는다고 설명합니다.
비밀 키를 추가해야 하나요?
아니요. 워크플로는 GitHub Actions 안에서 저장소의 자체 토큰으로 실행되므로 추가 비밀 값을 설정할 필요가 없다고 밝힙니다.
프로젝트에 무엇이 추가되나요?
스크립트, 매주 실행되는 워크플로 파일, docs 폴더의 생성된 SVG, 차트를 가리키는 README 섹션이 추가됩니다.
상세 정보
작성자의 원본 설명
Add a self-hosted "Stargazers over time" chart to any GitHub repo's README. GitHub now restricts the stargazers endpoint to a repo's own admins/collaborators, so third-party live services (star-history free tier, starchart.cc) return "Requires authentication" for everyone. This generates a static, theme-aware SVG in-repo and auto-refreshes it weekly with a GitHub Action using the repo's own GITHUB_TOKEN. Use when the star chart in a README is broken, shows "Requires authentication", or you want a star history that never breaks.
인기도
- GitHub 스타
- 33k
- 순위
- #8855
- 라이선스
- MIT
- 업데이트
- 2026. 11. 2.
댓글
- …
이 저장소의 다른 스킬
owasp-security
33k웹 앱, API, 모바일, 컨테이너, AI 에이전트를 위한 OWASP 보안 지침을 따르도록 해서, 흔한 약점을 찾고 수정안을 제안하게 합니다.
agent-management
33k에이전트가 AI Maestro 명령줄을 사용해 AI 에이전트를 만들고, 나열하고, 일시 정지하고, 깨우고, 이름을 바꾸고, 삭제하도록 돕습니다.
agent-messaging
33k에이전트가 Agent Messaging Protocol로 AI 에이전트 사이에 서명된 메시지를 보내고, 받고, 답하도록 돕습니다. 대부분 내 컴퓨터에서 작동합니다.
docs-search
33k에이전트가 자동 생성된 코드 문서에서 함수 시그니처, 클래스 정의, 주석을 검색하도록 해서, 코드를 바꾸기 전에 실제 API를 확인하게 합니다.
비슷한 스킬
openclaw-update
394k에이전트가 설치 방식에 맞는 방법을 골라 기존 OpenClaw Gateway를 업데이트하고, 세션이 계속 작동하도록 돕습니다.
diagnose-gateway
394k에이전트가 설정, 채널, 포트를 확인해 OpenClaw Gateway가 왜 실패하는지 찾되, 아무것도 바꾸지 않도록 돕습니다.
crabbox-apps
394k에이전트가 임시 클라우드 머신에서 앱을 열고 실행한 뒤, 그 화면을 채팅의 측면 패널에 보여 주도록 돕습니다.