From eefbd029b55b2782b0d7b11b4989ce0ca9b256cd Mon Sep 17 00:00:00 2001 From: Mitch Riedstra Date: Tue, 15 Oct 2019 20:56:41 -0400 Subject: Massive organization of my dotfiles --- tmux_helper.sh | 28 ---------------------------- 1 file changed, 28 deletions(-) delete mode 100644 tmux_helper.sh (limited to 'tmux_helper.sh') diff --git a/tmux_helper.sh b/tmux_helper.sh deleted file mode 100644 index 7ce68bd..0000000 --- a/tmux_helper.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/sh - - -# Little helper script to clean up the nasty embeded commands in my tmux configuration -# Functions ripped out of `mkshrc`, worth checking out - -_sys_memory() { - if [ `uname` = "Linux" ] ; then - vmstat | tail -n1 | awk '{print $4/1024}' | sed -e's/\..*$//g' - elif [ `uname` = "FreeBSD" ] ; then - vmstat | tail -n1 | awk '{print $5/1024}' | sed -e's/\..*$//g' - elif [ `uname` = "OpenBSD" ] ; then - vmstat | sed -n '$p' | awk '{print $4}' | sed 's/M$//' - fi -} - -_sys_load() { - # Works on BSD too, neat. - uptime | sed -re's/^.*load averages?: ([0-9]+\.[0-9]+).*$/\1/g' -} - -_sys_uptime() { - # Took awhile to figure out, but this works on BSD as well - uptime | sed -re's/^.*up[ ]+//g' -e's/^([^,]*),.*/\1/g' -e's/^([^ ]+)[ ]*(.).*/\1\2/g' -} - - -_sys_$1 -- cgit v1.2.3