aboutsummaryrefslogtreecommitdiff
path: root/segments/tmux_mem_cpu_load.sh
blob: c05be3e621a3e6eaa33c39e99151d7c092a348b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# Print out Memory, cpu and load using https://github.com/thewtex/tmux-mem-cpu-load

run_segment() {
	type tmux-mem-cpu-load >/dev/null 2>&1
	if [ "$?" -ne 0 ]; then
		return
	fi

	stats=$(tmux-mem-cpu-load)
	if [ -n "$stats" ]; then
		echo "$stats";
	fi
	return 0
}