/SKILL.md
一键上传项目到 GitHub。自动完成:敏感信息检查、生成 README.md、创建.gitignore、Git 初始化、推送仓库。使用场景:发布开源项目、创建新仓库、分享代码、备份项目到 GitHub。
npx skillsauth add superstar0000/github-auto-upload-skill github-auto-uploadInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
自动化完成项目上传到 GitHub 的全流程,包含安全检查、文件生成和 Git 操作。
当用户说以下任意内容时,触发此技能:
根据用户安全规则,上传前必须检查:
自动检查以下内容包括但不限于:
| 类型 | 检查项 | 处理方式 |
|------|--------|----------|
| API Key | API_KEY=, api_key:, sk- | 警告并建议移除 |
| 密码 | password=, passwd: | 警告并建议移除 |
| 私钥 | -----BEGIN RSA PRIVATE KEY----- | 严重警告,必须移除 |
| 数据库连接 | mongodb://, mysql:// | 警告并建议移除 |
| 个人隐私 | 手机号、身份证、邮箱 | 警告并建议脱敏 |
检查工具: 调用 scripts/scan-secrets.py 扫描项目文件
向用户询问:
📦 准备上传到 GitHub
请确认以下信息:
1. 项目名称(仓库名):[默认使用当前文件夹名]
2. 仓库类型:[公开 Public / 私有 Private]
3. GitHub 用户名:[你的 GitHub 用户名]
4. 是否初始化 Git:[是/否,默认是]
5. 是否生成 README.md:[是/否,默认是]
6. 项目描述(一句话):[用于 README]
调用脚本扫描项目:
python scripts/scan-secrets.py "D:\OpenClaw\Projects\项目名"
扫描结果处理:
根据项目类型自动选择模板:
node_modules/, .env, dist/__pycache__/, venv/, *.pycnode_modules/, dist/, .env.local生成标准 README 结构:
# 项目名称
项目描述(用户提供)
## 功能特点
- 功能 1
- 功能 2
## 快速开始
### 安装
[安装说明]
### 使用
[使用说明]
## 技术栈
- 技术 1
- 技术 2
## 许可证
MIT License
默认使用 MIT License,可根据用户需求更换。
cd D:\OpenClaw\Projects\项目名
# 初始化仓库
git init
# 添加所有文件
git add .
# 首次提交
git commit -m "Initial commit - 项目初始化
- 添加项目文件
- 生成 README.md
- 配置 .gitignore"
# 安装 GitHub CLI(如未安装)
winget install GitHub.cli
# 登录
gh auth login
# 创建仓库
gh repo create 仓库名 --public --source=. --remote=origin --push
https://github.com/newgit remote add origin [email protected]:用户名/仓库名.git
git branch -M main
git push -u origin main
向用户展示:
✅ 项目成功上传到 GitHub!
📦 仓库信息:
名称:项目名
地址:https://github.com/用户名/项目名
类型:公开/私有
📝 已生成文件:
- README.md
- .gitignore
- LICENSE
🎯 下一步:
1. 访问仓库查看:https://github.com/用户名/项目名
2. 设置仓库描述和话题标签
3. 添加 GitHub Pages(如需要)
4. 配置 CI/CD(如需要)
⚠️ 安全提醒:
- 已扫描并移除敏感信息
- 请再次检查无 API Key 和密码
- 定期检查 .gitignore 是否生效
scripts/scan-secrets.py(敏感信息扫描)references/gitignore-templates.md(各类 .gitignore 模板)references/readme-templates.md(README 范例).env 文件默认不上传# Windows 安装 Git
winget install Git.Git
# 生成 SSH Key
ssh-keygen -t ed25519 -C "你的邮箱@example.com"
# 查看公钥
cat ~/.ssh/id_ed25519.pub
# 复制到 GitHub → Settings → SSH and GPG keys → New SSH key
# 安装 Git LFS
git lfs install
# 追踪大文件
git lfs track "*.psd"
git lfs track "*.zip"
# 重新添加
git add .
git commit -m "Add large files with LFS"
# 从 Git 历史中彻底删除
git filter-branch --force --index-filter \
"git rm --cached --ignore-unmatch 文件名" \
--prune-empty --tag-name-filter cat -- --all
# 强制推送
git push origin --force --all
| 规则 | 技能中的实现 | |------|-------------| | SEC-002 工作区数据隔离 | 上传前需用户明确授权 | | SEC-004 下载审批制度 | 安装 Git/GHub CLI 需确认 | | SEC-001 禁止公网暴露 | 敏感信息扫描,防止 API Key 泄露 |
技能版本:1.0 | 最后更新:2026-03-21
documentation
Fetch GitHub issues, spawn sub-agents to implement fixes and open PRs, then monitor and address PR review comments. Usage: /gh-issues [owner/repo] [--label bug] [--limit 5] [--milestone v1.0] [--assignee @me] [--fork user/repo] [--watch] [--interval 5] [--reviews-only] [--cron] [--dry-run] [--model glm-5] [--notify-channel -1002381931352]
documentation
Maintain the OpenClaw memory wiki vault with deterministic pages, managed blocks, and source-backed updates.
documentation
Feishu knowledge base navigation. Activate when user mentions knowledge base, wiki, or wiki links.
documentation
Feishu permission management for documents and files. Activate when user mentions sharing, permissions, collaborators.