m/fzf
1
0
mirror of https://github.com/junegunn/fzf.git synced 2025-11-16 07:13:48 -05:00

Fix issues in tcell renderer and Windows build

- Fix display of CJK wide characters
- Fix horizontal offset of header lines
- Add support for keys with ALT modifier, shift-tab, page-up and down
- Fix util.ExecCommand to properly parse command-line arguments
- Fix redraw on resize
- Implement Pause/Resume for execute action
- Remove runtime check of GOOS
- Change exit status to 2 when tcell failed to start
- TBD: Travis CI build for tcell renderer
    - Pending. tcell cannot reliably ingest keys from tmux send-keys
This commit is contained in:
Junegunn Choi
2016-11-07 02:15:34 +09:00
parent 26895da969
commit 898d8d94c8
9 changed files with 96 additions and 33 deletions

View File

@@ -5,6 +5,8 @@ package util
import (
"os"
"os/exec"
"github.com/junegunn/go-shellwords"
)
// ExecCommand executes the given command with $SHELL
@@ -13,5 +15,14 @@ func ExecCommand(command string) *exec.Cmd {
if len(shell) == 0 {
shell = "cmd"
}
return exec.Command(shell, "/c", command)
args, _ := shellwords.Parse(command)
allArgs := make([]string, len(args)+1)
allArgs[0] = "/c"
copy(allArgs[1:], args)
return exec.Command(shell, allArgs...)
}
// IsWindows returns true on Windows
func IsWindows() bool {
return true
}