From 417cb97dc63b08594d75f77b0c5ac8d3e5097142 Mon Sep 17 00:00:00 2001 From: Jesse Duffield Date: Wed, 8 Aug 2018 07:49:45 +1000 Subject: [PATCH] add file to command --- gitcommands.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gitcommands.go b/gitcommands.go index f12545897..c8f81dd6b 100644 --- a/gitcommands.go +++ b/gitcommands.go @@ -279,7 +279,7 @@ func sublimeOpenFile(g *gocui.Gui, filename string) (string, error) { func openFile(g *gocui.Gui, filename string) (string, error) { cmdName, cmdTrail := getOpenCommand() - return runCommand(cmdName + " " + cmdTrail) + return runCommand(cmdName + " " + filename + " " + cmdTrail) // TODO: find out why finder is being opened here } func gitAddPatch(g *gocui.Gui, filename string) { @@ -306,7 +306,7 @@ func getOpenCommand() (string, string) { "cygstart": "", } for name, trail := range trailMap { - if out, _ := runCommand("which " + name); out != "" { + if out, _ := runCommand("which " + name); out != "exit status 1" { return name, trail } }