diff options
author | John Fred Fadrigalan <johnfred.fadrigalan@hotmail.com> | 2022-10-16 16:15:19 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-16 17:15:19 +0900 |
commit | 4603d540c3ae648c9e2ef84f33433b275290aa7c (patch) | |
tree | 2b6211dc1cb03e19fe5aec8089b9de7ddb172d93 /test | |
parent | f9d53303bb00225edb6e46ca1851e5cf1b55e623 (diff) |
[shell] Make bash/zsh completion and bindings work with 'set -u' (#2999)
Co-authored-by: Junegunn Choi <junegunn.c@gmail.com>
Diffstat (limited to 'test')
-rwxr-xr-x | test/test_go.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/test/test_go.rb b/test/test_go.rb index bb6a4c8d..ab5a4ae6 100755 --- a/test/test_go.rb +++ b/test/test_go.rb @@ -2758,6 +2758,7 @@ class TestFish < TestBase end __END__ +set -u PS1= PROMPT_COMMAND= HISTFILE= HISTSIZE=100 unset <%= UNSETS.join(' ') %> unset $(env | sed -n /^_fzf_orig/s/=.*//p) @@ -2801,8 +2802,8 @@ _fzf_complete_g_post() { awk '{print "g" $0 $0}' } -[ -n "$BASH" ] && complete -F _fzf_complete_f -o default -o bashdefault f -[ -n "$BASH" ] && complete -F _fzf_complete_g -o default -o bashdefault g +[ -n "${BASH-}" ] && complete -F _fzf_complete_f -o default -o bashdefault f +[ -n "${BASH-}" ] && complete -F _fzf_complete_g -o default -o bashdefault g _comprun() { local command=$1 |