Commit a908c17
authored
fix(init): truncate uncommitted file list to first 5 entries (#381)
## Summary
- Truncates the uncommitted/untracked file list in the `init` git safety
check to show only the first 5 files
- Appends a summary line (e.g. `+ 12 more uncommitted files`) when there
are more than 5
- Prevents terminal flooding in repos with many dirty files while still
communicating the situation clearly
## Changes
**`src/lib/init/git.ts`** — In `checkGitStatus`, instead of joining all
files into the warning message, slice to `MAX_DISPLAYED_FILES` (5) and
append a remainder count if truncated. Both the `--yes` auto-proceed and
interactive prompt paths benefit from this.1 parent 6d389c5 commit a908c17
1 file changed
+9
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
10 | 13 | | |
11 | 14 | | |
12 | 15 | | |
| |||
64 | 67 | | |
65 | 68 | | |
66 | 69 | | |
67 | | - | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
68 | 76 | | |
69 | 77 | | |
70 | 78 | | |
| |||
0 commit comments