]> arthur.barton.de Git - netdata.git/blobdiff - charts.d/sensors.chart.sh
charts.d.plugin and tc-qos-helper.sh optimization to avoid frequent forks due to...
[netdata.git] / charts.d / sensors.chart.sh
index 6e77317783c2479cbec05e90f43ee64c4ca6c237..9652f896a0822f39cf65f7047fe5f05681daae99 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/sh
+# no need for shebang - this file is loaded from charts.d.plugin
 
 # sensors docs
 # https://www.kernel.org/doc/Documentation/hwmon/sysfs-interface
@@ -213,7 +213,7 @@ sensors_create() {
                                fi
 
                                echo "DIMENSION $fid '$labelname' $algorithm $multiplier $divisor"
-                               echo >>$TMP_DIR/sensors.sh "printf \"SET $fid = \"; cat $file "
+                               echo >>$TMP_DIR/sensors.sh "echo \"SET $fid = \"\$(< $file )"
                        done
 
                        echo >>$TMP_DIR/sensors.sh "echo END"