Skip to content
Myr

No need to "tmux list-panes" when obviously not on tmux (#303)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Junegunn Choi · committed by Junegunn Choi · parent fb1b026 · Browse files · 1 file+6 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+6 added−3 removed

  • other:+6 added−3 removed

1 file+6 added−3 removed

modified:plugin/fzf.vim+6 added-3 removed
52 unmodified lines
53 endif54 return s:exec55endfunction5657function! s:tmux_not_zoomed()58 return system('tmux list-panes -F "#F"') !~# 'Z'59endfunction6061function! s:tmux_enabled()62 if has('gui_running')63 return 064 endif6562 let not_zoomed = system('tmux list-panes -F "#F"') !~# 'Z'66 if exists('s:tmux')64 return s:tmux && not_zoomed67 return s:tmux && s:tmux_not_zoomed()68 endif6970 let s:tmux = 071 if exists('$TMUX') && executable(s:fzf_tmux)72 let output = system('tmux -V')73 let s:tmux = !v:shell_error && output >= 'tmux 1.7'74 endif72 return s:tmux && not_zoomed75 return s:tmux && s:tmux_not_zoomed()76endfunction7778function! s:shellesc(arg)79 return '"'.substitute(a:arg, '"', '\\"', 'g').'"'
314 unmodified lines