Browse Source

made loadavg status update at most every 'status-interval' seconds

also, stopped updating when no client is attached
my-config
Gregory Pakosz 5 years ago
parent
commit
3676bfc648
  1. 4
      .tmux.conf

4
.tmux.conf

@ -1181,7 +1181,9 @@ run -b '[ -z "#{window_active}" ] && [ -z "#{version}" ] && tmux set display-tim
# -e 's/#\{(\?)?loadavg/#\{\1@loadavg/g')
# status_right=$(echo "$status_right" | sed -E \
# -e 's/#\{(\?)?loadavg/#\{\1@loadavg/g')
# status_right="#(cut -c3- ~/.tmux.conf | sh -s _loadavg)$status_right"
# interval=$(tmux show -gv status-interval)
# pkill -f 'cut -c3- ~/\.tmux\.conf \| sh -s _loadavg' || true
# status_right="#(printf '\n'; while [ \$(tmux display -p '##{session_attached}') -gt 0 ]; do cut -c3- ~/.tmux.conf | sh -s _loadavg; sleep $interval; done)$status_right"
# ;;
# esac
#

Loading…
Cancel
Save