1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-22 02:51:03 +00:00

[cpubyuser] clear variable names

This commit is contained in:
Lars Kruse 2016-10-22 01:54:57 +02:00
parent a465880501
commit 002e8bbf99

View file

@ -56,14 +56,14 @@ if [ "$1" = "config" ]; then
echo "graph_vlabel %"
echo "graph_scale no"
echo "graph_period second"
_USERS="$(for user in $USERS; do clean_fieldname "$user" | tr '\n' ' '; done)"
echo "graph_order $_USERS others"
for USER in $USERS "others"; do
_USER="$(clean_fieldname "$USER")"
echo "${_USER}.label $USER"
echo "${_USER}.info CPU used by user $USER"
echo "${_USER}.type GAUGE"
echo "${_USER}.draw AREASTACK"
user_fields="$(for user in $USERS; do clean_fieldname "$user" | tr '\n' ' '; done)"
echo "graph_order $user_fields others"
for user in $USERS "others"; do
user_field="$(clean_fieldname "$user")"
echo "${user_field}.label $user"
echo "${user_field}.info CPU used by user $user"
echo "${user_field}.type GAUGE"
echo "${user_field}.draw AREASTACK"
done
exit
fi