summaryrefslogtreecommitdiffstats
path: root/pkg/commands/git.go
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2020-02-24 09:14:57 +1100
committerJesse Duffield <jessedduffield@gmail.com>2020-02-24 09:20:50 +1100
commit370cec098b8e51bcc06f4db947d7e71434f76b54 (patch)
treecd0776fa0c456416109608c52c004b7bbdd642da /pkg/commands/git.go
parent49a2f0191fde427f0b28daa1caef837dad1ece9d (diff)
show diff stat
Diffstat (limited to 'pkg/commands/git.go')
-rw-r--r--pkg/commands/git.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/commands/git.go b/pkg/commands/git.go
index 9b4fbd544..deb3c43e4 100644
--- a/pkg/commands/git.go
+++ b/pkg/commands/git.go
@@ -558,7 +558,7 @@ func (c *GitCommand) Ignore(filename string) error {
}
func (c *GitCommand) ShowCmdStr(sha string) string {
- return fmt.Sprintf("git show --color --no-renames %s", sha)
+ return fmt.Sprintf("git show --color --no-renames --stat -p %s", sha)
}
func (c *GitCommand) GetBranchGraphCmdStr(branchName string) string {
@@ -604,7 +604,7 @@ func (c *GitCommand) DiffCmdStr(file *File, plain bool, cached bool) string {
colorArg = ""
}
- return fmt.Sprintf("git diff %s %s %s %s", colorArg, cachedArg, trackedArg, fileName)
+ return fmt.Sprintf("git diff --stat -p %s %s %s %s", colorArg, cachedArg, trackedArg, fileName)
}
func (c *GitCommand) ApplyPatch(patch string, flags ...string) error {