Commit cf74e99
committed
feat: Enhanced Git Diff Functionality
⚡ Updated the getGitDiff() function in util.go to run 'git diff --staged' if no diff is detected from the 'git diff' command, thus taking into account both unstaged and staged changes. The code changes trim excessive white spaces from the output. These changes now allow better diff prints by including staged diffs in the output.1 parent 1704273 commit cf74e99
1 file changed
Lines changed: 9 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
27 | 32 | | |
28 | 33 | | |
29 | 34 | | |
| |||
0 commit comments