summaryrefslogtreecommitdiffstats
path: root/pkg/commands/oscommands/os.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/commands/oscommands/os.go')
-rw-r--r--pkg/commands/oscommands/os.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/commands/oscommands/os.go b/pkg/commands/oscommands/os.go
index 5d37e2f4f..6a40d519c 100644
--- a/pkg/commands/oscommands/os.go
+++ b/pkg/commands/oscommands/os.go
@@ -255,7 +255,7 @@ func (c *OSCommand) EditFile(filename string) (*exec.Cmd, error) {
return nil, errors.New("No editor defined in $VISUAL, $EDITOR, or git config")
}
- splitCmd := str.ToArgv(fmt.Sprintf("%s %s", editor, filename))
+ splitCmd := str.ToArgv(fmt.Sprintf("%s %s", editor, c.Quote(filename)))
return c.PrepareSubProcess(splitCmd[0], splitCmd[1:]...), nil
}