summaryrefslogtreecommitdiffstats
path: root/pkg/commands
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/commands')
-rw-r--r--pkg/commands/files.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/commands/files.go b/pkg/commands/files.go
index 51523ea5f..99e9bcf5c 100644
--- a/pkg/commands/files.go
+++ b/pkg/commands/files.go
@@ -250,7 +250,7 @@ func (c *GitCommand) ShowFileDiffCmdStr(from string, to string, reverse bool, fi
reverseFlag = " -R "
}
- return fmt.Sprintf(`git diff --submodule --no-ext-diff --no-renames --color=%s %s %s %s -- "%s"`, colorArg, from, to, reverseFlag, fileName)
+ return fmt.Sprintf("git diff --submodule --no-ext-diff --no-renames --color=%s %s %s %s -- %s", colorArg, from, to, reverseFlag, c.OSCommand.Quote(fileName))
}
// CheckoutFile checks out the file for the given commit