summaryrefslogtreecommitdiffstats
path: root/collectors/charts.d.plugin/charts.d.dryrun-helper.sh
diff options
context:
space:
mode:
Diffstat (limited to '')
-rwxr-xr-xcollectors/charts.d.plugin/charts.d.dryrun-helper.sh (renamed from plugins.d/charts.d.dryrun-helper.sh)9
1 files changed, 7 insertions, 2 deletions
diff --git a/plugins.d/charts.d.dryrun-helper.sh b/collectors/charts.d.plugin/charts.d.dryrun-helper.sh
index 8142f9882..67496c1bd 100755
--- a/plugins.d/charts.d.dryrun-helper.sh
+++ b/collectors/charts.d.plugin/charts.d.dryrun-helper.sh
@@ -1,4 +1,7 @@
#!/usr/bin/env bash
+# SPDX-License-Identifier: GPL-3.0-or-later
+
+# shellcheck disable=SC2181
# will stop the script for any error
set -e
@@ -10,8 +13,8 @@ conf="$3"
can_diff=1
-tmp1="`mktemp`"
-tmp2="`mktemp`"
+tmp1="$(mktemp)"
+tmp2="$(mktemp)"
myset() {
set | grep -v "^_=" | grep -v "^PIPESTATUS=" | grep -v "^BASH_LINENO="
@@ -36,6 +39,7 @@ myset >"$tmp1"
# include the plugin and its config
if [ -f "$conf" ]
then
+ # shellcheck source=/dev/null
. "$conf"
if [ $? -ne 0 ]
then
@@ -45,6 +49,7 @@ then
fi
fi
+# shellcheck source=/dev/null
. "$chart"
if [ $? -ne 0 ]
then