agentleFS
easonc023-deveasonc023-dev/skill-publisher/SKILL.md

skill-publisher

Skill0 starsChanged 6 months agoMITView on GitHub

Publish a Claude Code skill to GitHub with one command. Automates git init, commit, repo creation, README generation, topics, and license setup. TRIGGER when: user wants to upload a skill to GitHub, publish a skill, push to GitHub, "上传到GitHub", "发布到GitHub", "skill上传到我github", "把这个skill发布到github", "推送到github".

  • Reads credentials

6 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions6 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 6

    1. joeseesun/qiaomu-skill-publisher★ 38same name
    2. Liuzln/openclaw-skills★ 6same name
    3. csfuwwc/md-skills★ 4same name
    4. pablolok/claude-skills★ 1same name
    5. bryant24hao/skill-publisher★ 0same name
    6. Weiming3/skill-publisher★ 0same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

The file

Show its rules and text

We split this skill into the rules it gives an agent

18 rules. 0 are common, 9 are distinctive, and 9 are very specific to this project.

  • 0

    Common

    Most of the 3 edited versions we read keep these.

  • 9

    Distinctive

    This author's own choices. Worth a look.

  • 9

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Nothing is hardcoded: Every value is either detected at runtime or derived from the skill being published.

    line 34
  2. Very specific:

    Use inline identity (git -c user.name=...

    line 60
  3. Distinctive:

    If user names a specific path → use that

    line 68
  4. Very specific:

    If user says "this skill" / "当前这个" → use the current working directory (if it contains SKILL.md)

    line 69
  5. Distinctive:

    If ambiguous → ask: "Which skill directory should I publish?"

    line 70
  6. Very specific:

    Verify: directory exists AND contains a SKILL.md file.

    line 72
  7. Distinctive:

    Run these in parallel:

    line 78
  8. Very specific:

    Look for pattern: Logged in to github.com account <USERNAME>

    line 91
  9. Very specific:

    If either is empty, set reasonable defaults derived from GITHUB_USER.

    line 99
  10. Very specific:

    All git commits use: -c user.name="$GIT_NAME" -c user.email="$GIT_EMAIL"

    line 100
  11. Distinctive:

    Use the following template structure:

    line 139
  12. Very specific:

    If .env or credential files are detected in staged changes → warn the user and remove them

    line 196
  13. Distinctive:

    Commit message: concise English, describe what changed (e.g., "Initial commit: <skill-name> skill", "Update README with bilingual format")

    line 197
  14. Distinctive:

    If nothing to commit (clean working tree) → skip to step 5

    line 198
  15. Very specific:

    Read the skill's SKILL.md to pick relevant topics.

    line 219
  16. Distinctive:

    When generating README.md in Step 3, follow these rules:

    line 249
  17. Very specific:

    Bilingual: Every section in Chinese + English.

    line 251
  18. Distinctive:

    Honest: Don't oversell. Describe what the skill actually does.

    line 253

“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Skill Publisher · 一键发布 Skill 到 GitHub

Take a local Claude Code skill directory and publish it to GitHub in one shot — git init, commit, repo creation, README, topics, license, everything.

把本地一个 Claude Code skill 目录一键发布到 GitHub —— git 初始化、提交、创建仓库、README、话题标签、许可证,全包。

Boundary · 边界

What this handles · 管什么:

  • A skill directory (contains SKILL.md) that needs to go on GitHub
  • First-time publishing (no git repo yet) and subsequent updates (already has git + remote)
  • Auto-generating bilingual README if missing, MIT License, .gitignore
  • Setting repo description and topics

What this does NOT handle · 不管什么:

  • Non-skill projects (no SKILL.md) — user can still use, but this skill is optimized for skill repos
  • Force push, rebase, or destructive git operations
  • Private repos (default is public; if user wants private, they'll say so explicitly)
  • Repos hosted on platforms other than GitHub
  • Sensitive files (.env, credentials, tokens) — will warn and skip

Prerequisites · 前置条件:

  • git installed
  • gh CLI installed and authenticated (gh auth status)
  • A GitHub account

Configuration · 配置

Nothing is hardcoded. Every value is either detected at runtime or derived from the skill being published.

Values detected from the environment:

ConfigHow to detect
GitHub usernameRun gh auth status 2>&1. Parse the output for Logged in to github.com account <username>. Extract <username>.
Git user.nameRun git config --global user.name. If empty, derive from GitHub username.
Git user.emailRun git config --global user.email. If empty, try gh api user --jq '.email'. If still empty, use <username>@github.

Values derived per-skill:

ConfigHow to determine
Repo nameDirectory name (e.g., skill-publisher). Keep as-is unless it conflicts with an existing repo.
Repo descriptionFrom SKILL.md frontmatter description. First sentence, ≤ 150 chars.
VisibilityDefault public. If user mentions "private" / "私有", use --private.
TopicsBaseline: claude-code skill. ADDITIONALLY, read the skill's SKILL.md body and add 1-3 content-specific topics: dashboard, template, pdf, automation, publish, generator, api, frontend, design, translator, etc. Use your judgment based on what the skill does.
LicenseDefault MIT. If user specifies another license, use that.

Windows-specific:

gh may not be on PATH. Try gh first; if not found, use C:\Program Files\GitHub CLI\gh.exe. On macOS/Linux, gh is typically on PATH.

Git identity rule:

Use inline identity (git -c user.name=... -c user.email=...) rather than modifying git config files globally.

Execution Steps · 执行步骤

Step 0: Identify the Target · 确认目标

Determine which skill directory to publish:

  1. If user names a specific path → use that
  2. If user says "this skill" / "当前这个" → use the current working directory (if it contains SKILL.md)
  3. If ambiguous → ask: "Which skill directory should I publish?"

Verify: directory exists AND contains a SKILL.md file. If not, warn the user.

Set REPO_NAME = directory name. Set SKILL_DIR = full path.

Step 1: Environment Check & Config Detection · 环境检查与配置检测

Run these in parallel:

Check 1: git --version
Check 2: gh --version (try "gh" first; on Windows fallback to "C:\Program Files\GitHub CLI\gh.exe")
Check 3: gh auth status
  • gh not found → install: winget install GitHub.cli (Windows) or direct to https://cli.github.com
  • gh not authenticated → direct user to run gh auth login
  • git not found → direct user to install Git

Extract GitHub username from gh auth status output:

  • Look for pattern: Logged in to github.com account <USERNAME>
  • Store as GITHUB_USER

Extract git identity:

GIT_NAME=$(git config --global user.name)
GIT_EMAIL=$(git config --global user.email)
  • If either is empty, set reasonable defaults derived from GITHUB_USER.
  • All git commits use: -c user.name="$GIT_NAME" -c user.email="$GIT_EMAIL"

Step 2: Git Setup · Git 初始化

Check repo state:

git -C "$SKILL_DIR" status          # Is it a git repo?
git -C "$SKILL_DIR" remote -v       # Does it have a remote?

Case A: Not a git repo → git init

Case B: Git repo, no remote → proceed to step 3.

Case C: Git repo, remote matches GITHUB_USER/REPO_NAME → already published. Skip repo creation in step 5, just add/commit/push.

Case D: Git repo, remote points elsewhere → warn user: "This repo already has a remote: <url>. Continue pushing there?"

Step 3: Ensure Project Files · 补全项目文件

For each file below: check if it exists, if not → generate it.

.gitignore (if missing):

skills-data.js
node_modules/
.env
.DS_Store

LICENSE (if missing): Generate MIT License with current year and GIT_NAME as copyright holder.

README.md (if missing): Generate using the bilingual template below. Read the skill's SKILL.md to extract:

  • Skill name (from frontmatter name)
  • Description (from frontmatter description)
  • What it does (from body Overview section)
  • Key features (from body sections)

Use the following template structure:

# <Skill Name> · <中文名>

> <One-line description in Chinese>
> <One-line description in English>

---

## 这解决什么问题? · What Problem Does This Solve?

<2-3 sentences in Chinese explaining the use case.>

<2-3 sentences in English explaining the use case.>

---

## 快速开始 · Quick Start

<Chinese: how to use the skill — 2-3 steps.>

<English: how to use the skill — 2-3 steps.>

---

## 主要能力 · Key Features

- <Feature 1 中文> · <Feature 1 English>
- <Feature 2 中文> · <Feature 2 English>
- ...

---

## 自定义 · Customization

<Chinese: key configuration points.>

<English: key configuration points.>

---

## License

MIT — 随便用、改、商用,保留署名即可。Use, modify, and sell freely — just keep the attribution.

Adapt template sections based on what the skill actually does. If the skill has no configuration, skip the "自定义" section. If it has notable dependencies or architecture, add an "架构" section.

Step 4: Commit · 提交

git -C "$SKILL_DIR" add <specific files>   # NEVER "git add -A" — add files by name
git -C "$SKILL_DIR" -c user.name="$GIT_NAME" -c user.email="$GIT_EMAIL" commit -m "<message>"
  • Stage files by specific name, never git add -A
  • If .env or credential files are detected in staged changes → warn the user and remove them
  • Commit message: concise English, describe what changed (e.g., "Initial commit: <skill-name> skill", "Update README with bilingual format")
  • If nothing to commit (clean working tree) → skip to step 5

Step 5: Create Repo & Push · 创建仓库并推送

If repo has no remote (Case A/B):

gh repo create $GITHUB_USER/$REPO_NAME --source "$SKILL_DIR" --public --push --description "<description>"
  • --public by default. If user explicitly asked for private, use --private.
  • Description: derive from SKILL.md frontmatter description field (first 150 chars max, trim to sentence boundary).

If repo already has remote (Case C):

git -C "$SKILL_DIR" push

After push, determine and add topics:

Read the skill's SKILL.md to pick relevant topics. Start with baseline claude-code skill, then add 1-3 skill-specific ones:

Skill content signalsSuggested topic
Generates HTML pages, visual dashboardsdashboard
Generates documents (PDF, DOCX, PPTX)generator
Deals with APIs, SDKsapi
Frontend, CSS, design, themesfrontend
Automation, publishing, workflowautomation
Template-based generationtemplate
Translation, localizationtranslator
Git/GitHub operationsgithub
gh repo edit $GITHUB_USER/$REPO_NAME --add-topic "claude-code" --add-topic "skill" --add-topic "<topic3>" ...

Step 6: Report · 报告结果

Report the final GitHub URL clearly:

已发布到 GitHub · Published to GitHub:
https://github.com/$GITHUB_USER/$REPO_NAME

Mention what was done: committed files, repo created (or updated), topics set. If README was auto-generated, mention it so user can review.

README Generation Guidelines · README 生成指南

When generating README.md in Step 3, follow these rules:

  1. Bilingual: Every section in Chinese + English. Chinese first, English second. Use · as separator in headings.
  2. Concise: One paragraph per language per section. Not a novel.
  3. Honest: Don't oversell. Describe what the skill actually does.
  4. Read the SKILL.md: Extract the real description and purpose — don't invent from thin air.
  5. Skip irrelevant sections: Template sections are optional. If a skill has no customization points, don't add a "自定义" section.

Verification Checklist · 验证清单

After publishing, verify:

  • gh repo view $GITHUB_USER/$REPO_NAME shows the repo
  • Repo visibility is correct (public/private as intended)
  • Topics are set (baseline + skill-specific)
  • All project files are on GitHub (check via gh repo view or quick browser check)
  • README renders correctly on GitHub
  • No sensitive files (.env, credentials) in the repo

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.