dot/.tmux/plugins/tmux-better-mouse-mode/scripts/helpers.sh

16 lines
275 B
Bash

get_tmux_option() {
local option="$1"
local default_value="$2"
local option_value=$(tmux show-option -gqv "$option")
if [ -z "$option_value" ]; then
echo "$default_value"
else
echo "$option_value"
fi
}
get_tmux_version() {
tmux -V | cut -d " " -f 2
}