lee-spec-kit 0.1.3 → 0.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/dist/index.js +108 -55
- package/package.json +1 -1
- package/templates/en/fullstack/agents/agents.md +9 -1
- package/templates/en/fullstack/agents/constitution.md +5 -0
- package/templates/en/fullstack/agents/git-workflow.md +17 -3
- package/templates/en/fullstack/agents/issue-template.md +44 -1
- package/templates/en/fullstack/agents/pr-template.md +31 -1
- package/templates/en/fullstack/features/README.md +4 -4
- package/templates/en/fullstack/features/be/README.md +1 -1
- package/templates/en/fullstack/features/fe/README.md +1 -1
- package/templates/en/fullstack/features/feature-base/plan.md +2 -2
- package/templates/en/fullstack/features/feature-base/spec.md +6 -4
- package/templates/en/fullstack/features/feature-base/tasks.md +4 -4
- package/templates/en/fullstack/prd/README.md +5 -0
- package/templates/en/single/agents/agents.md +9 -1
- package/templates/en/single/agents/constitution.md +44 -39
- package/templates/en/single/agents/git-workflow.md +74 -60
- package/templates/en/single/agents/issue-template.md +76 -29
- package/templates/en/single/agents/pr-template.md +63 -31
- package/templates/en/single/features/README.md +2 -2
- package/templates/en/single/features/feature-base/plan.md +2 -2
- package/templates/en/single/features/feature-base/spec.md +6 -4
- package/templates/en/single/features/feature-base/tasks.md +4 -4
- package/templates/en/single/prd/README.md +14 -9
- package/templates/ko/fullstack/agents/agents.md +9 -1
- package/templates/ko/fullstack/agents/constitution.md +5 -0
- package/templates/ko/fullstack/agents/git-workflow.md +17 -3
- package/templates/ko/fullstack/agents/issue-template.md +45 -0
- package/templates/ko/fullstack/agents/pr-template.md +31 -1
- package/templates/ko/fullstack/features/README.md +4 -4
- package/templates/ko/fullstack/features/be/README.md +1 -1
- package/templates/ko/fullstack/features/fe/README.md +1 -1
- package/templates/ko/fullstack/features/feature-base/spec.md +2 -0
- package/templates/ko/fullstack/prd/README.md +5 -0
- package/templates/ko/single/agents/agents.md +9 -1
- package/templates/ko/single/agents/constitution.md +5 -0
- package/templates/ko/single/agents/git-workflow.md +17 -3
- package/templates/ko/single/agents/issue-template.md +45 -0
- package/templates/ko/single/agents/pr-template.md +31 -1
- package/templates/ko/single/features/README.md +2 -2
- package/templates/ko/single/features/feature-base/spec.md +2 -0
- package/templates/ko/single/prd/README.md +5 -0
|
@@ -44,7 +44,7 @@ docs/
|
|
|
44
44
|
|
|
45
45
|
### 1. New Feature Request
|
|
46
46
|
|
|
47
|
-
1. Create feature folder: `lee-spec-kit feature <name>`
|
|
47
|
+
1. Create feature folder: `npx lee-spec-kit feature <name>`
|
|
48
48
|
2. Write `spec.md` - what and why
|
|
49
49
|
3. Request spec review
|
|
50
50
|
4. Create GitHub Issue
|
|
@@ -56,6 +56,14 @@ docs/
|
|
|
56
56
|
3. Status transition: `[TODO]` → `[DOING]` → `[DONE]`
|
|
57
57
|
4. Commit on task completion
|
|
58
58
|
|
|
59
|
+
### 3. Handling Requests Outside Tasks
|
|
60
|
+
|
|
61
|
+
> When user requests **work not in tasks.md**:
|
|
62
|
+
|
|
63
|
+
1. Ask user if this should be **added to tasks.md**
|
|
64
|
+
2. If approved: Add to tasks.md then execute
|
|
65
|
+
3. If declined: Proceed as temporary work (still included in commit)
|
|
66
|
+
|
|
59
67
|
---
|
|
60
68
|
|
|
61
69
|
## 📋 ADR (Architecture Decision Records)
|
|
@@ -1,75 +1,80 @@
|
|
|
1
1
|
# {{projectName}} Constitution
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
Core principles and technical decision guidelines for the project.
|
|
4
|
+
All development decisions should be based on this document.
|
|
5
|
+
|
|
6
|
+
> **📌 Document Scope**
|
|
7
|
+
>
|
|
8
|
+
> - **This document**: Tech stack, architecture principles, code quality, security principles
|
|
9
|
+
> - **PRD**: Product requirements, business logic, user stories → `prd/*.md`
|
|
5
10
|
|
|
6
11
|
---
|
|
7
12
|
|
|
8
|
-
##
|
|
13
|
+
## Project Mission
|
|
9
14
|
|
|
10
|
-
> (
|
|
15
|
+
> (Write your project mission here)
|
|
11
16
|
|
|
12
17
|
---
|
|
13
18
|
|
|
14
|
-
##
|
|
19
|
+
## Tech Stack
|
|
15
20
|
|
|
16
21
|
### Backend
|
|
17
22
|
|
|
18
|
-
|
|
|
19
|
-
|
|
|
20
|
-
| (
|
|
23
|
+
| Tech | Version | Reason |
|
|
24
|
+
| ------------- | --------- | -------- |
|
|
25
|
+
| (e.g. NestJS) | (version) | (reason) |
|
|
21
26
|
|
|
22
27
|
### Frontend
|
|
23
28
|
|
|
24
|
-
|
|
|
25
|
-
|
|
|
26
|
-
| (
|
|
29
|
+
| Tech | Version | Reason |
|
|
30
|
+
| ------------ | --------- | -------- |
|
|
31
|
+
| (e.g. React) | (version) | (reason) |
|
|
27
32
|
|
|
28
|
-
###
|
|
33
|
+
### Common
|
|
29
34
|
|
|
30
|
-
|
|
|
31
|
-
| ----------------- |
|
|
32
|
-
| TypeScript | strict
|
|
33
|
-
| ESLint + Prettier | -
|
|
34
|
-
| pnpm | -
|
|
35
|
+
| Tech | Version | Reason |
|
|
36
|
+
| ----------------- | ------- | ------------ |
|
|
37
|
+
| TypeScript | strict | Type safety |
|
|
38
|
+
| ESLint + Prettier | - | Code quality |
|
|
39
|
+
| pnpm | - | Package mgmt |
|
|
35
40
|
|
|
36
41
|
---
|
|
37
42
|
|
|
38
|
-
##
|
|
43
|
+
## Architecture Principles
|
|
39
44
|
|
|
40
|
-
### 1. Feature
|
|
45
|
+
### 1. Feature-Centric Management
|
|
41
46
|
|
|
42
|
-
-
|
|
43
|
-
- FE/BE
|
|
44
|
-
- spec → plan → tasks → decisions
|
|
47
|
+
- Manage new features in `docs/features/F00X/` structure
|
|
48
|
+
- Develop by **feature unit** (FE/BE separate)
|
|
49
|
+
- spec → plan → tasks → decisions workflow
|
|
45
50
|
|
|
46
|
-
### 2. (
|
|
51
|
+
### 2. (Additional Principles)
|
|
47
52
|
|
|
48
|
-
(
|
|
53
|
+
(Write project-specific architecture principles here)
|
|
49
54
|
|
|
50
55
|
---
|
|
51
56
|
|
|
52
|
-
##
|
|
57
|
+
## Code Quality Standards
|
|
53
58
|
|
|
54
|
-
- TypeScript strict mode
|
|
55
|
-
- ESLint + Prettier
|
|
56
|
-
-
|
|
57
|
-
-
|
|
58
|
-
-
|
|
59
|
+
- TypeScript strict mode required
|
|
60
|
+
- ESLint + Prettier required
|
|
61
|
+
- Major business logic test coverage **80%+**
|
|
62
|
+
- Components follow **Single Responsibility Principle**
|
|
63
|
+
- Minimize code duplication
|
|
59
64
|
|
|
60
65
|
---
|
|
61
66
|
|
|
62
|
-
##
|
|
67
|
+
## Security Principles
|
|
63
68
|
|
|
64
|
-
-
|
|
65
|
-
-
|
|
66
|
-
- CORS
|
|
69
|
+
- Manage secrets via environment variables (no repo commits)
|
|
70
|
+
- **Minimal data collection** for user data
|
|
71
|
+
- CORS only for allowed origins
|
|
67
72
|
|
|
68
73
|
---
|
|
69
74
|
|
|
70
|
-
##
|
|
75
|
+
## Language/Code Rules
|
|
71
76
|
|
|
72
|
-
-
|
|
73
|
-
-
|
|
74
|
-
-
|
|
75
|
-
-
|
|
77
|
+
- **Responses**: English
|
|
78
|
+
- **Code/Filenames**: English
|
|
79
|
+
- **Comments/Commits**: English
|
|
80
|
+
- **Date/Time**: User's local system time (e.g., `{{date}}`)
|
|
@@ -1,97 +1,111 @@
|
|
|
1
|
-
# Git
|
|
1
|
+
# Git Workflow Guide
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Rules for AI agents to automate Git/GitHub operations.
|
|
4
4
|
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
-
##
|
|
7
|
+
## Core Concepts
|
|
8
8
|
|
|
9
|
-
|
|
|
10
|
-
|
|
|
11
|
-
| Feature
|
|
12
|
-
|
|
|
13
|
-
|
|
|
9
|
+
| Concept | GitHub Mapping | Description |
|
|
10
|
+
| ---------------- | -------------- | ------------------------------- |
|
|
11
|
+
| Feature | GitHub Issue | Feature-level work unit |
|
|
12
|
+
| Task | Commit | Individual implementation unit |
|
|
13
|
+
| Feature Complete | Pull Request | Create PR on feature completion |
|
|
14
14
|
|
|
15
15
|
---
|
|
16
16
|
|
|
17
|
-
##
|
|
17
|
+
## Branch Strategy
|
|
18
18
|
|
|
19
19
|
```
|
|
20
20
|
main
|
|
21
|
-
└── feat/123-feature-name # Issue #123
|
|
22
|
-
├── commit 1: feat(#123):
|
|
23
|
-
├── commit 2: test(#123):
|
|
24
|
-
└── commit 3: docs(#123):
|
|
21
|
+
└── feat/123-feature-name # Branch based on Issue #123
|
|
22
|
+
├── commit 1: feat(#123): implement feature
|
|
23
|
+
├── commit 2: test(#123): add tests
|
|
24
|
+
└── commit 3: docs(#123): update docs
|
|
25
25
|
```
|
|
26
26
|
|
|
27
|
-
###
|
|
27
|
+
### Branch Naming
|
|
28
28
|
|
|
29
29
|
```
|
|
30
30
|
{type}/{issue-number}-{feature-name}
|
|
31
31
|
```
|
|
32
32
|
|
|
33
|
-
| Type |
|
|
34
|
-
| ---------- |
|
|
35
|
-
| `feat` |
|
|
36
|
-
| `fix` |
|
|
37
|
-
| `refactor` |
|
|
38
|
-
| `docs` |
|
|
33
|
+
| Type | Description |
|
|
34
|
+
| ---------- | ------------- |
|
|
35
|
+
| `feat` | New feature |
|
|
36
|
+
| `fix` | Bug fix |
|
|
37
|
+
| `refactor` | Refactoring |
|
|
38
|
+
| `docs` | Documentation |
|
|
39
39
|
|
|
40
|
-
|
|
40
|
+
**Examples:**
|
|
41
41
|
|
|
42
42
|
- `feat/123-user-auth`
|
|
43
43
|
- `fix/456-login-error`
|
|
44
44
|
|
|
45
45
|
---
|
|
46
46
|
|
|
47
|
-
##
|
|
47
|
+
## Commit Convention
|
|
48
48
|
|
|
49
|
-
|
|
49
|
+
> 📖 Type and Description follow [Udacity Git Commit Message Style Guide](https://udacity.github.io/git-styleguide/).
|
|
50
|
+
|
|
51
|
+
### Format
|
|
50
52
|
|
|
51
53
|
```
|
|
52
54
|
{type}(#{issue}): {description}
|
|
53
55
|
```
|
|
54
56
|
|
|
55
|
-
### Type
|
|
57
|
+
### Type List
|
|
56
58
|
|
|
57
|
-
| Type |
|
|
58
|
-
| ---------- |
|
|
59
|
-
| `feat` |
|
|
60
|
-
| `fix` |
|
|
61
|
-
| `refactor` |
|
|
62
|
-
| `test` |
|
|
63
|
-
| `docs` |
|
|
64
|
-
| `style` |
|
|
65
|
-
| `chore` |
|
|
59
|
+
| Type | Description | Example |
|
|
60
|
+
| ---------- | ------------- | ------------------------------------- |
|
|
61
|
+
| `feat` | New feature | `feat(#123): implement user auth` |
|
|
62
|
+
| `fix` | Bug fix | `fix(#123): fix login error` |
|
|
63
|
+
| `refactor` | Refactoring | `refactor(#123): separate auth logic` |
|
|
64
|
+
| `test` | Tests | `test(#123): add auth unit tests` |
|
|
65
|
+
| `docs` | Documentation | `docs(#123): clarify spec` |
|
|
66
|
+
| `style` | Code style | `style(#123): fix lint errors` |
|
|
67
|
+
| `chore` | Other | `chore(#123): update dependencies` |
|
|
66
68
|
|
|
67
69
|
---
|
|
68
70
|
|
|
69
|
-
##
|
|
71
|
+
## Automation Workflow
|
|
70
72
|
|
|
71
|
-
### 1. Feature
|
|
73
|
+
### 1. Feature Start
|
|
72
74
|
|
|
73
75
|
```bash
|
|
74
|
-
# 1. GitHub Issue
|
|
75
|
-
# 2.
|
|
76
|
+
# 1. Create GitHub Issue (Feature = Issue)
|
|
77
|
+
# 2. Create branch
|
|
76
78
|
git checkout -b feat/{issue-number}-{feature-name}
|
|
77
79
|
```
|
|
78
80
|
|
|
79
|
-
> `gh
|
|
81
|
+
> When creating/modifying issues/PRs with `gh`, share the title/body/labels first and **wait for user confirmation (OK)** before proceeding.
|
|
82
|
+
|
|
83
|
+
### 2. Document Writing and Commit
|
|
84
|
+
|
|
85
|
+
| Document | Commit Timing | Commit Message Example |
|
|
86
|
+
| ------------ | ----------------------- | ------------------------------ |
|
|
87
|
+
| spec.md | After user approval | `docs(#123): write spec` |
|
|
88
|
+
| plan.md | After user approval | `docs(#123): write plan` |
|
|
89
|
+
| tasks.md | After user approval | `docs(#123): break down tasks` |
|
|
90
|
+
| decisions.md | Included in task commit | (no separate commit) |
|
|
91
|
+
|
|
92
|
+
> 📌 **Do not commit when creating Feature folder.**
|
|
93
|
+
> Commit each document individually **after user approval**.
|
|
80
94
|
|
|
81
|
-
###
|
|
95
|
+
### 3. Auto Commit on Task Completion
|
|
82
96
|
|
|
83
|
-
|
|
97
|
+
When a task is completed:
|
|
84
98
|
|
|
85
99
|
```bash
|
|
86
100
|
git add .
|
|
87
101
|
git commit -m "{type}(#{issue}): {task-description}"
|
|
88
102
|
```
|
|
89
103
|
|
|
90
|
-
> `git commit
|
|
104
|
+
> Before running `git commit`, share the commit message and file list first and **wait for user confirmation (OK)** before proceeding.
|
|
91
105
|
|
|
92
|
-
###
|
|
106
|
+
### 4. Create PR on Feature Completion
|
|
93
107
|
|
|
94
|
-
|
|
108
|
+
When all tasks are completed:
|
|
95
109
|
|
|
96
110
|
```bash
|
|
97
111
|
git push origin feat/{issue-number}-{feature-name}
|
|
@@ -100,58 +114,58 @@ gh pr create --title "feat(#{issue}): {feature-title}" \
|
|
|
100
114
|
--base main
|
|
101
115
|
```
|
|
102
116
|
|
|
103
|
-
###
|
|
117
|
+
### 5. Merge
|
|
104
118
|
|
|
105
|
-
|
|
119
|
+
When all reviews are resolved:
|
|
106
120
|
|
|
107
121
|
```bash
|
|
108
|
-
#
|
|
122
|
+
# Update main before merge
|
|
109
123
|
git checkout main
|
|
110
124
|
git pull
|
|
111
125
|
|
|
112
126
|
# Squash and Merge
|
|
113
127
|
gh pr merge --squash --delete-branch
|
|
114
128
|
|
|
115
|
-
#
|
|
129
|
+
# Update main after merge
|
|
116
130
|
git pull
|
|
117
131
|
```
|
|
118
132
|
|
|
119
133
|
---
|
|
120
134
|
|
|
121
|
-
##
|
|
135
|
+
## Agent Automation Rules
|
|
122
136
|
|
|
123
|
-
###
|
|
137
|
+
### On Task Completion
|
|
124
138
|
|
|
125
139
|
```
|
|
126
|
-
1.
|
|
127
|
-
2. tasks.md
|
|
140
|
+
1. Complete code changes
|
|
141
|
+
2. Update tasks.md status [DOING] → [DONE] (docs)
|
|
128
142
|
3. git add .
|
|
129
143
|
4. git commit -m "{type}(#{issue}): {description}"
|
|
130
|
-
5.
|
|
144
|
+
5. Proceed to next task
|
|
131
145
|
```
|
|
132
146
|
|
|
133
|
-
### Feature
|
|
147
|
+
### On Feature Completion
|
|
134
148
|
|
|
135
149
|
```
|
|
136
|
-
1.
|
|
150
|
+
1. Verify all tasks [DONE]
|
|
137
151
|
2. git push origin {branch}
|
|
138
152
|
3. gh pr create
|
|
139
|
-
4.
|
|
140
|
-
5.
|
|
153
|
+
4. Wait for review
|
|
154
|
+
5. Address review comments
|
|
141
155
|
6. gh pr merge --squash
|
|
142
156
|
```
|
|
143
157
|
|
|
144
158
|
---
|
|
145
159
|
|
|
146
|
-
## GitHub
|
|
160
|
+
## GitHub Setup Requirements
|
|
147
161
|
|
|
148
|
-
###
|
|
162
|
+
### Required
|
|
149
163
|
|
|
150
|
-
- [ ] GitHub CLI (`gh`)
|
|
164
|
+
- [ ] GitHub CLI (`gh`) installed and authenticated
|
|
151
165
|
- [ ] Branch protection rules (main)
|
|
152
166
|
- Require PR before merging
|
|
153
167
|
|
|
154
|
-
###
|
|
168
|
+
### Recommended
|
|
155
169
|
|
|
156
170
|
- [ ] Auto-delete head branches
|
|
157
171
|
- [ ] Squash merging only
|
|
@@ -1,64 +1,109 @@
|
|
|
1
|
-
# GitHub Issue
|
|
1
|
+
# GitHub Issue Template Guide
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
A template for AI agents to create GitHub Issues.
|
|
4
4
|
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
-
##
|
|
7
|
+
## Issue Creation Rules
|
|
8
8
|
|
|
9
|
-
###
|
|
9
|
+
### Title Format
|
|
10
10
|
|
|
11
11
|
```text
|
|
12
|
-
F{
|
|
12
|
+
F{number}: {feature-name} ({short description})
|
|
13
13
|
```
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
Example: `F001: user-auth (User authentication feature)`
|
|
16
16
|
|
|
17
|
-
> "
|
|
17
|
+
> Keep the "short description" concise enough to convey the intent in one line.
|
|
18
|
+
|
|
19
|
+
### Link Format (Important!)
|
|
20
|
+
|
|
21
|
+
In GitHub Issues, use different link formats **based on file location**:
|
|
22
|
+
|
|
23
|
+
1. **Files within project repo**: Use full URL (clickable)
|
|
24
|
+
- **Merged documents/code**: Use `main` branch
|
|
25
|
+
```markdown
|
|
26
|
+
[filename](https://github.com/{owner}/{repo}/blob/main/path/to/file)
|
|
27
|
+
```
|
|
28
|
+
- **In-progress documents** (not merged yet): Use **Feature branch**
|
|
29
|
+
```markdown
|
|
30
|
+
[filename](https://github.com/{owner}/{repo}/blob/{feat-branch}/path/to/file)
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
2. **External documents (with public URL)**: Use **absolute URL**
|
|
34
|
+
|
|
35
|
+
```markdown
|
|
36
|
+
[react-i18next](https://react.i18next.com/)
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
3. **External/local documents** (no URL available): Use **relative path as text only**
|
|
40
|
+
```text
|
|
41
|
+
../docs/features/F001-feature-name/spec.md
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
> ⚠️ Local documents are not clickable on GitHub, so provide path text only.
|
|
18
45
|
|
|
19
46
|
---
|
|
20
47
|
|
|
21
|
-
##
|
|
48
|
+
## Issue Body Template
|
|
22
49
|
|
|
23
50
|
```markdown
|
|
24
|
-
##
|
|
51
|
+
## Overview
|
|
25
52
|
|
|
26
|
-
{
|
|
53
|
+
{Brief description of the feature}
|
|
27
54
|
|
|
28
|
-
##
|
|
55
|
+
## Goals
|
|
29
56
|
|
|
30
|
-
- {
|
|
31
|
-
- {
|
|
57
|
+
- {Goal 1}
|
|
58
|
+
- {Goal 2}
|
|
32
59
|
|
|
33
|
-
##
|
|
60
|
+
## Completion Criteria
|
|
34
61
|
|
|
35
|
-
- [ ] {
|
|
36
|
-
- [ ] {
|
|
62
|
+
- [ ] {Criterion 1}
|
|
63
|
+
- [ ] {Criterion 2}
|
|
37
64
|
|
|
38
|
-
##
|
|
65
|
+
## Related Documents
|
|
39
66
|
|
|
40
|
-
- Spec: `docs/features/
|
|
67
|
+
- Spec: `docs/features/F{number}-{feature-name}/spec.md`
|
|
41
68
|
|
|
42
|
-
##
|
|
69
|
+
## Labels
|
|
43
70
|
|
|
44
|
-
- `enhancement` (
|
|
45
|
-
- `bug` (
|
|
46
|
-
- `documentation` (
|
|
71
|
+
- `enhancement` (New feature)
|
|
72
|
+
- `bug` (Bug fix)
|
|
73
|
+
- `documentation` (Documentation)
|
|
47
74
|
```
|
|
48
75
|
|
|
49
76
|
---
|
|
50
77
|
|
|
51
|
-
##
|
|
78
|
+
## Label Rules
|
|
52
79
|
|
|
53
|
-
|
|
|
80
|
+
| Label | Usage |
|
|
54
81
|
| --------------- | ------------- |
|
|
55
|
-
| `enhancement` |
|
|
56
|
-
| `bug` |
|
|
57
|
-
| `documentation` |
|
|
58
|
-
| `backend` | BE
|
|
59
|
-
| `frontend` | FE
|
|
82
|
+
| `enhancement` | New feature |
|
|
83
|
+
| `bug` | Bug fix |
|
|
84
|
+
| `documentation` | Documentation |
|
|
85
|
+
| `backend` | BE related |
|
|
86
|
+
| `frontend` | FE related |
|
|
60
87
|
| `priority:high` | High priority |
|
|
61
88
|
|
|
89
|
+
> ⚠️ If a label does not exist, create it first:
|
|
90
|
+
>
|
|
91
|
+
> ```bash
|
|
92
|
+
> gh label create "label-name" --description "description" --color "color-code"
|
|
93
|
+
> ```
|
|
94
|
+
|
|
95
|
+
---
|
|
96
|
+
|
|
97
|
+
## Assignee Rules
|
|
98
|
+
|
|
99
|
+
- Default: Self-assign (`--assignee @me`)
|
|
100
|
+
- When assigning others, **confirm with user** first
|
|
101
|
+
- Examples:
|
|
102
|
+
```bash
|
|
103
|
+
gh issue create --assignee @me ...
|
|
104
|
+
gh issue create --assignee username ...
|
|
105
|
+
```
|
|
106
|
+
|
|
62
107
|
---
|
|
63
108
|
|
|
64
109
|
## Body Input Rules (Shell Execution Prevention)
|
|
@@ -67,3 +112,5 @@ F{번호}: {기능명} ({짧은 설명})
|
|
|
67
112
|
- If the body contains backticks (`) or `$()`and is placed directly in`"..."`, it may be **interpreted by the shell**.
|
|
68
113
|
- For multi-line bodies, use **single-quoted heredoc** like `cat <<'EOF'`,
|
|
69
114
|
and handle variables via **placeholder → sed substitution**.
|
|
115
|
+
|
|
116
|
+
and handle variables via **placeholder → sed substitution**.
|
|
@@ -1,74 +1,106 @@
|
|
|
1
|
-
# GitHub PR
|
|
1
|
+
# GitHub PR Template Guide
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
A template for AI agents to create Pull Requests.
|
|
4
4
|
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
-
## PR
|
|
7
|
+
## PR Creation Rules
|
|
8
8
|
|
|
9
|
-
###
|
|
9
|
+
### Title Format
|
|
10
10
|
|
|
11
11
|
```text
|
|
12
|
-
feat(#{
|
|
12
|
+
feat(#{issue-number}): {feature-name}
|
|
13
13
|
```
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
Example: `feat(#1): Implement user authentication`
|
|
16
|
+
|
|
17
|
+
### Link Format (Important!)
|
|
18
|
+
|
|
19
|
+
For file links within the repo in PR body, **always use current branch name**:
|
|
20
|
+
|
|
21
|
+
```markdown
|
|
22
|
+
[filename](https://github.com/{owner}/{repo}/blob/{branch-name}/docs/path/to/file.md)
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
> ⚠️ `main` branch links will return 404 until merged!
|
|
26
|
+
> Always use the **current feature branch name** (e.g., `feat/5-feature-name`).
|
|
16
27
|
|
|
17
28
|
---
|
|
18
29
|
|
|
19
|
-
## PR
|
|
30
|
+
## PR Body Template
|
|
20
31
|
|
|
21
32
|
```markdown
|
|
22
|
-
##
|
|
33
|
+
## Overview
|
|
23
34
|
|
|
24
|
-
{
|
|
35
|
+
{Brief description of changes}
|
|
25
36
|
|
|
26
|
-
##
|
|
37
|
+
## Changes
|
|
27
38
|
|
|
28
|
-
- {
|
|
29
|
-
- {
|
|
30
|
-
- {
|
|
39
|
+
- {Change 1}
|
|
40
|
+
- {Change 2}
|
|
41
|
+
- {Change 3}
|
|
31
42
|
|
|
32
|
-
##
|
|
43
|
+
## Tests
|
|
33
44
|
|
|
34
|
-
- [ ]
|
|
35
|
-
- [ ]
|
|
45
|
+
- [ ] Unit tests passed
|
|
46
|
+
- [ ] Integration tests completed
|
|
36
47
|
|
|
37
|
-
##
|
|
48
|
+
## Screenshots (for UI changes)
|
|
38
49
|
|
|
39
|
-
{
|
|
50
|
+
{Attach if applicable}
|
|
40
51
|
|
|
41
|
-
##
|
|
52
|
+
## Related Documents
|
|
42
53
|
|
|
43
|
-
- Spec: `docs/features/
|
|
44
|
-
- Tasks: `docs/features/
|
|
54
|
+
- Spec: `docs/features/F{number}-{feature-name}/spec.md`
|
|
55
|
+
- Tasks: `docs/features/F{number}-{feature-name}/tasks.md`
|
|
45
56
|
|
|
46
|
-
Closes #{
|
|
57
|
+
Closes #{issue-number}
|
|
47
58
|
```
|
|
48
59
|
|
|
49
60
|
---
|
|
50
61
|
|
|
51
|
-
## PR
|
|
62
|
+
## PR Creation Command
|
|
52
63
|
|
|
53
64
|
```bash
|
|
54
|
-
#
|
|
65
|
+
# Check current branch name
|
|
55
66
|
BRANCH=$(git branch --show-current)
|
|
56
67
|
|
|
57
68
|
gh pr create \
|
|
58
|
-
--title "feat(#{issue}): {
|
|
69
|
+
--title "feat(#{issue}): {feature-name}" \
|
|
59
70
|
--body-file /tmp/pr-body.md \
|
|
60
71
|
--base main
|
|
61
72
|
```
|
|
62
73
|
|
|
63
74
|
---
|
|
64
75
|
|
|
65
|
-
##
|
|
76
|
+
## Merge Rules
|
|
77
|
+
|
|
78
|
+
| Situation | Merge Method |
|
|
79
|
+
| -------------- | ---------------- |
|
|
80
|
+
| Normal Feature | Squash and Merge |
|
|
81
|
+
| Urgent Hotfix | Merge or Rebase |
|
|
82
|
+
| Docs update | Squash and Merge |
|
|
83
|
+
|
|
84
|
+
---
|
|
85
|
+
|
|
86
|
+
## Label Rules
|
|
87
|
+
|
|
88
|
+
- Specify appropriate labels when creating PR (`--label`)
|
|
89
|
+
- If a label does not exist, create it first:
|
|
90
|
+
```bash
|
|
91
|
+
gh label create "label-name" --description "description" --color "color-code"
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
---
|
|
95
|
+
|
|
96
|
+
## Assignee Rules
|
|
66
97
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
98
|
+
- Default: Self-assign (`--assignee @me`)
|
|
99
|
+
- Use `--reviewer` option to specify reviewers
|
|
100
|
+
- Examples:
|
|
101
|
+
```bash
|
|
102
|
+
gh pr create --assignee @me --reviewer reviewer-username ...
|
|
103
|
+
```
|
|
72
104
|
|
|
73
105
|
---
|
|
74
106
|
|