gitlink-cli/skills/gitlink-newcomer-guide/examples/newcomer-guide-workflow.md

72 lines
1.7 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 新人引导完整工作流示例
**场景**:项目标记了一个 good-first-issue需要为新贡献者添加引导评论帮助 TA 迈出第一步。
## 前置条件
- `gitlink-cli` 已安装并登录
- 对目标仓库有评论权限
## 工作流步骤
### Step 1查找 good-first-issue
```bash
gitlink-cli issue +list --owner z2_cc --repo gitlink-cli --state open --format json
```
查看 Issue 列表中哪些标记了适合新人的任务。
### Step 2查看 Issue 详情
```bash
gitlink-cli issue +view --owner z2_cc --repo gitlink-cli --number 10 --format json
```
分析 Issue 内容:
- 是否是 Bug 修复?→ 使用 Bug 模板
- 是否是文档改进?→ 使用文档模板
- 是否是功能需求?→ 使用功能模板
### Step 3添加引导评论
```bash
gitlink-cli issue +comment --owner z2_cc --repo gitlink-cli --number 10 --body "你好!欢迎参与贡献 🎉
这个 Issue 被标记为 **good first issue**,非常适合作为你的第一个贡献。
### 如何开始
1. 在评论区留言"我想认领",我们会把你添加到 Assignee
2. Fork 本仓库并创建你的功能分支
3. 修改代码后提交 Pull Request
### 需要帮助?
- 如果对问题描述有疑问,可以在下方留言
- 开发过程中遇到任何问题,也欢迎随时提问
祝你编码愉快!"
```
### Step 4确认引导已生效
```bash
gitlink-cli issue +view --owner z2_cc --repo gitlink-cli --number 10 --format json
```
检查 `comment_journals_count` 是否增加了。
---
## 完整命令速览
```bash
# 1. 查找 good-first-issue
gitlink-cli issue +list --state open
# 2. 查看详情
gitlink-cli issue +view --number <id>
# 3. 添加引导评论
gitlink-cli issue +comment --number <id> --body "<引导内容>"
```