git-repo-guide
Skill0 starsChanged 10 months agoMITView on GitHub
Generates repository creation guidelines and naming suggestions. Use when setting up new repositories, asking about repo naming conventions, or creating new projects.
- Commits and pushes
In this repository4 other files it gives its agents.
- git-branchSkill
- git-cleanupSkill
- git-commitSkill
- git-prSkill
The file
Files
Git Repo Guide
生成仓库创建指南(非执行)
Naming Conventions
命名格式
<产品线>-<模块>-<功能>命名示例
| 类型 | 示例 | 说明 |
| 产品核心 | crm-customer-core | CRM 客户核心模块 |
| API 服务 | crm-order-api | CRM 订单 API |
| 管理后台 | crm-admin-portal | CRM 管理后台 |
| 通用服务 | common-auth-service | 通用认证服务 |
| 工具脚本 | tools-db-migrator | 数据库迁移工具 |
| 实验项目 | experiment-ai-poc | AI 概念验证 |
命名规则
- 小写字母 + 连字符
- 语义清晰,避免缩写
- 前缀统一,便于分类
Workflow
Step 1: 收集信息
如果用户未提供完整信息,依次询问:
📦 创建新仓库指南
1. 产品线/项目前缀(如 crm, common, tools):
2. 模块或功能名称:
3. 项目类型:
[ ] 正式项目 - 需要立项审批
[ ] 实验项目 - experiment- 前缀,无需审批
4. 简短描述(一句话):Step 2: 生成仓库名建议
根据输入生成规范的仓库名:
📝 仓库名称建议:
推荐: crm-order-api
备选: crm-order-service
💡 命名说明:
• crm - 产品线前缀
• order - 模块名
• api - 表明这是 API 服务Step 3: 输出完整指南
╭─────────────────────────────────────────────────────╮
│ 📦 仓库创建指南 │
╰─────────────────────────────────────────────────────╯
📝 仓库信息:
名称: crm-order-api
描述: CRM 订单服务 API
类型: 正式项目
可见性: 私有
═══════════════════════════════════════════════════════
⚠️ 第一步:立项审批(正式项目必须)
1. 在规范仓库创建「新项目立项申请」Issue
2. 填写:项目背景、目标、参与人员、技术选型
3. 等待审批通过
跳过条件: 实验项目(experiment-* 前缀)无需审批
═══════════════════════════════════════════════════════
📋 第二步:在 Git 服务器创建仓库
1. 访问 Git 服务器创建页面
2. 填写:
• 仓库名称: crm-order-api
• 描述: CRM 订单服务 API
• 可见性: 私有
• 初始化: ✓ README, ✓ .gitignore (根据技术栈)
• 默认分支: main
3. 点击创建
═══════════════════════════════════════════════════════
🔧 第三步:配置分支保护
在仓库设置 → 分支 → 分支保护规则:
分支: main
├─ ✓ 禁止直接推送
├─ ✓ 要求 Pull Request
├─ ✓ 要求至少 1 人审批
└─ ✓ 禁止强制推送
═══════════════════════════════════════════════════════
💻 第四步:本地初始化
复制以下命令执行:
# 克隆仓库
git clone git@git.yourcompany.com:org/crm-order-api.git
cd crm-order-api
# 创建 develop 分支
git checkout -b develop
git push -u origin develop
# 创建基础目录结构
mkdir -p src tests docs
# 提交初始结构
git add .
git commit -m "chore: 初始化项目结构"
git push
═══════════════════════════════════════════════════════
✅ 完成后检查:
├─ [ ] 仓库已创建
├─ [ ] main 分支保护已启用
├─ [ ] develop 分支已创建
├─ [ ] 本地仓库已克隆
└─ [ ] 团队成员已添加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
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.

