gut-cli 0.1.5 → 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 +89 -29
- package/dist/index.js +537 -222
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -17,11 +17,13 @@ All AI commands support short aliases (without `ai-` prefix):
|
|
|
17
17
|
| `gut ai-commit` | `gut commit` | Generate commit messages |
|
|
18
18
|
| `gut ai-pr` | `gut pr` | Generate PR descriptions |
|
|
19
19
|
| `gut ai-review` | `gut review` | Code review |
|
|
20
|
-
| `gut ai-diff` | `gut diff` | Explain changes |
|
|
21
20
|
| `gut ai-merge` | `gut merge` | Resolve merge conflicts |
|
|
22
|
-
| `gut ai-explain` | `gut explain` | Explain commits, PRs, or files |
|
|
21
|
+
| `gut ai-explain` | `gut explain` | Explain changes, commits, PRs, or files |
|
|
23
22
|
| `gut ai-find` | `gut find` | Find commits by vague description |
|
|
23
|
+
| `gut ai-branch` | `gut branch` | Generate branch names from description |
|
|
24
24
|
| `gut changelog` | - | Generate changelogs |
|
|
25
|
+
| `gut sync` | - | Sync with remote (fetch + rebase/merge) |
|
|
26
|
+
| `gut stash` | - | Stash with AI-generated names |
|
|
25
27
|
|
|
26
28
|
### `gut commit`
|
|
27
29
|
|
|
@@ -88,24 +90,6 @@ gut review 123
|
|
|
88
90
|
gut review --json
|
|
89
91
|
```
|
|
90
92
|
|
|
91
|
-
### `gut diff`
|
|
92
|
-
|
|
93
|
-
Get an AI-powered explanation of your changes.
|
|
94
|
-
|
|
95
|
-
```bash
|
|
96
|
-
# Explain all uncommitted changes
|
|
97
|
-
gut diff
|
|
98
|
-
|
|
99
|
-
# Explain staged changes only
|
|
100
|
-
gut diff --staged
|
|
101
|
-
|
|
102
|
-
# Explain specific commit
|
|
103
|
-
gut diff --commit abc123
|
|
104
|
-
|
|
105
|
-
# Output as JSON
|
|
106
|
-
gut diff --json
|
|
107
|
-
```
|
|
108
|
-
|
|
109
93
|
### `gut merge`
|
|
110
94
|
|
|
111
95
|
Merge branches with AI-powered conflict resolution.
|
|
@@ -123,17 +107,14 @@ gut merge feature/login --no-commit
|
|
|
123
107
|
|
|
124
108
|
### `gut explain`
|
|
125
109
|
|
|
126
|
-
Get AI-powered explanations of commits, PRs, or file contents.
|
|
110
|
+
Get AI-powered explanations of changes, commits, PRs, or file contents.
|
|
127
111
|
|
|
128
112
|
```bash
|
|
129
|
-
# Explain
|
|
130
|
-
gut explain
|
|
131
|
-
|
|
132
|
-
# Explain file's recent change history
|
|
133
|
-
gut explain src/index.ts --history
|
|
113
|
+
# Explain uncommitted changes (default)
|
|
114
|
+
gut explain
|
|
134
115
|
|
|
135
|
-
# Explain
|
|
136
|
-
gut explain
|
|
116
|
+
# Explain staged changes only
|
|
117
|
+
gut explain --staged
|
|
137
118
|
|
|
138
119
|
# Explain a specific commit
|
|
139
120
|
gut explain abc123
|
|
@@ -143,8 +124,17 @@ gut explain HEAD
|
|
|
143
124
|
gut explain 123
|
|
144
125
|
gut explain #123
|
|
145
126
|
|
|
127
|
+
# Explain a file's purpose and contents
|
|
128
|
+
gut explain src/index.ts
|
|
129
|
+
|
|
130
|
+
# Explain file's recent change history
|
|
131
|
+
gut explain src/index.ts --history
|
|
132
|
+
|
|
133
|
+
# Explain multiple recent commits for a file
|
|
134
|
+
gut explain src/index.ts --history -n 5
|
|
135
|
+
|
|
146
136
|
# Output as JSON
|
|
147
|
-
gut explain
|
|
137
|
+
gut explain --json
|
|
148
138
|
```
|
|
149
139
|
|
|
150
140
|
**Project Context Support**: Create `.gut/explain.md` to provide project-specific context for better explanations.
|
|
@@ -180,6 +170,75 @@ gut find "authentication" --json
|
|
|
180
170
|
|
|
181
171
|
**Project Context Support**: Create `.gut/find.md` to provide project-specific context for better search results.
|
|
182
172
|
|
|
173
|
+
### `gut branch`
|
|
174
|
+
|
|
175
|
+
Generate branch names from GitHub issue or description using AI.
|
|
176
|
+
|
|
177
|
+
```bash
|
|
178
|
+
# Generate branch name from issue number (requires gh CLI)
|
|
179
|
+
gut branch 123
|
|
180
|
+
gut branch #123
|
|
181
|
+
|
|
182
|
+
# Auto-checkout the branch
|
|
183
|
+
gut branch 123 --checkout
|
|
184
|
+
|
|
185
|
+
# Specify branch type
|
|
186
|
+
gut branch 123 --type fix
|
|
187
|
+
|
|
188
|
+
# Use description instead of issue
|
|
189
|
+
gut branch -d "add user authentication"
|
|
190
|
+
```
|
|
191
|
+
|
|
192
|
+
**Branch Convention Support**: Create `.gut/branch-convention.md` for custom naming rules.
|
|
193
|
+
|
|
194
|
+
### `gut sync`
|
|
195
|
+
|
|
196
|
+
Sync current branch with remote (fetch + rebase).
|
|
197
|
+
|
|
198
|
+
```bash
|
|
199
|
+
# Sync current branch (rebase by default)
|
|
200
|
+
gut sync
|
|
201
|
+
|
|
202
|
+
# Use merge instead of rebase
|
|
203
|
+
gut sync --merge
|
|
204
|
+
|
|
205
|
+
# Auto-stash changes before sync
|
|
206
|
+
gut sync --stash
|
|
207
|
+
|
|
208
|
+
# Force sync with uncommitted changes
|
|
209
|
+
gut sync --force
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
### `gut stash`
|
|
213
|
+
|
|
214
|
+
Stash changes with AI-generated descriptive names.
|
|
215
|
+
|
|
216
|
+
```bash
|
|
217
|
+
# Stash with AI-generated name
|
|
218
|
+
gut stash
|
|
219
|
+
|
|
220
|
+
# Stash with custom name
|
|
221
|
+
gut stash "working on auth"
|
|
222
|
+
|
|
223
|
+
# List all stashes
|
|
224
|
+
gut stash --list
|
|
225
|
+
|
|
226
|
+
# Apply latest stash
|
|
227
|
+
gut stash --apply
|
|
228
|
+
|
|
229
|
+
# Apply specific stash
|
|
230
|
+
gut stash --apply 2
|
|
231
|
+
|
|
232
|
+
# Pop stash
|
|
233
|
+
gut stash --pop
|
|
234
|
+
|
|
235
|
+
# Drop stash
|
|
236
|
+
gut stash --drop 1
|
|
237
|
+
|
|
238
|
+
# Clear all stashes
|
|
239
|
+
gut stash --clear
|
|
240
|
+
```
|
|
241
|
+
|
|
183
242
|
### `gut changelog`
|
|
184
243
|
|
|
185
244
|
Generate a changelog from commits.
|
|
@@ -252,6 +311,7 @@ gut looks for these configuration files in your repository:
|
|
|
252
311
|
| `.gut/merge-strategy.md` | Merge conflict resolution rules |
|
|
253
312
|
| `.gut/explain.md` | Project context for explanations |
|
|
254
313
|
| `.gut/find.md` | Project context for commit search |
|
|
314
|
+
| `.gut/branch-convention.md` | Custom branch naming rules |
|
|
255
315
|
| `.github/pull_request_template.md` | PR template (fallback) |
|
|
256
316
|
| `CHANGELOG.md` | Changelog style (fallback) |
|
|
257
317
|
|