]> git.ipfire.org Git - thirdparty/rrdtool-1.x.git/commitdiff
allow to print the actual rrdtool calls run by a test by setting the VERBOSE
authorPeter Stamfest <peter@stamfest.at>
Wed, 20 Aug 2014 22:52:01 +0000 (00:52 +0200)
committerPeter Stamfest <peter@stamfest.at>
Sun, 31 Aug 2014 20:15:33 +0000 (22:15 +0200)
env. variable to a non-empty string before calling the test

tests/functions

index 3923cf62b524158d33141c0ee5df7aa1ce91c70b..e4eb066a6b51dd71cceaf75da7055f00f5440c30 100644 (file)
@@ -24,6 +24,17 @@ if [ -z "$RRDTOOL" ] ; then
        esac
 fi
 
+function verbose_rrdtool {
+       echo "$RRDTOOL_V" "$@"
+       "$RRDTOOL_V" "$@"
+}
+
+if [ -n "$VERBOSE" ] ; then
+       RRDTOOL_V="$RRDTOOL"
+       RRDTOOL=verbose_rrdtool
+fi
+
+
 DIFF="diff -u"
 
 function fail {