vdr-plugin-skindesigner/scripts/vdrstats.default

15 lines
454 B
Plaintext
Raw Normal View History

#!/bin/bash
# please update this script to fit your needs
# this script is call every time the according viewelement will be drawn, so keep it short and fast ;)
OUTPUTFLDR="/tmp/skindesigner/"
mkdir -p ${OUTPUTFLDR}
# there can be 2 files, vdrcpu and vdrmem
rm -f ${OUTPUTFLDR}/vdrcpu ${OUTPUTFLDR}/vdrmem
2016-04-30 18:01:27 +02:00
read vdr_cpu vdr_mem < <(ps -C vdr -o %cpu=,%mem= | sort | tail -n1)
echo $vdr_cpu > ${OUTPUTFLDR}/vdrcpu
echo $vdr_mem > ${OUTPUTFLDR}/vdrmem