diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2018-09-01 12:22:33 +1000 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2018-09-01 12:53:51 +1000 |
commit | 04d5a473d758090b0f65af5520e91bc7924648a1 (patch) | |
tree | 101561dc17876e94389b7bce36f5a55ea8a747c0 /pkg | |
parent | f127ae62bb67e86360a1a38971fef7e8e53cb5b9 (diff) |
use start instead of cygstart to open files on windows
Diffstat (limited to 'pkg')
-rw-r--r-- | pkg/commands/os.go | 2 | ||||
-rw-r--r-- | pkg/commands/os_linux.go | 2 | ||||
-rw-r--r-- | pkg/commands/os_windows.go | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/pkg/commands/os.go b/pkg/commands/os.go index c3574f98e..680105df8 100644 --- a/pkg/commands/os.go +++ b/pkg/commands/os.go @@ -111,7 +111,7 @@ func (c *OSCommand) OpenFile(filename string) error { } command := utils.ResolvePlaceholderString(commandTemplate, templateValues) - _, err := c.RunDirectCommand(command) + err := c.RunCommand(command) return err } diff --git a/pkg/commands/os_linux.go b/pkg/commands/os_linux.go index cbd037139..c17ebc98f 100644 --- a/pkg/commands/os_linux.go +++ b/pkg/commands/os_linux.go @@ -10,6 +10,6 @@ func getPlatform() *Platform { shell: "bash", shellArg: "-c", escapedQuote: "\"", - openCommand: "xdg-open {{filename}} &>/dev/null &", + openCommand: "bash -c \"xdg-open {{filename}} &>/dev/null &\"", } } diff --git a/pkg/commands/os_windows.go b/pkg/commands/os_windows.go index 5b50d2c38..f41c6d2b9 100644 --- a/pkg/commands/os_windows.go +++ b/pkg/commands/os_windows.go @@ -6,6 +6,6 @@ func getPlatform() *Platform { shell: "cmd", shellArg: "/c", escapedQuote: "\\\"", - openCommand: "cygstart {{filename}}", + openCommand: "start {{filename}}", } } |