aboutsummaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorGravatar Arun Prakash Jana <engineerarun@gmail.com>2020-06-04 03:41:42 +0530
committerGravatar Arun Prakash Jana <engineerarun@gmail.com>2020-06-04 03:41:42 +0530
commit56eea7e195e98eedca374cfc24cc43afe73d43db (patch)
treed76e489458cd76902cad8d02fab07c2df57cc521 /plugins
parent995fa1ceb678b138eef03a09effff73dc07a0558 (diff)
downloadnnn-56eea7e195e98eedca374cfc24cc43afe73d43db.tar.gz
Fix tmux version check
Diffstat (limited to 'plugins')
-rwxr-xr-xplugins/preview-tui2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/preview-tui b/plugins/preview-tui
index fe13033..bd9fbd8 100755
--- a/plugins/preview-tui
+++ b/plugins/preview-tui
@@ -106,7 +106,7 @@ if [ "$PREVIEW_MODE" ] ; then
exit 0
fi
-if [ -e "${TMUX%%,*}" ] && [ "$(tmux -V | cut -c6)" -eq 3 ] ; then
+if [ -e "${TMUX%%,*}" ] && tmux -V | grep -q '[ -][3456789]\.' ; then
if [ -z "$SPLIT" ] && [ $(($(tput lines) * 2)) -gt "$(tput cols)" ] ; then
SPLIT='v'
elif [ "$SPLIT" != 'v' ] ; then