Plugin process: in Linux read the number of threads from
[collectd.git] / version-gen.sh
index 7bd07cb..460c6e9 100755 (executable)
@@ -2,7 +2,7 @@
 
 DEFAULT_VERSION="5.4.2.git"
 
-VERSION="`git describe 2> /dev/null | sed -e 's/^collectd-//'`"
+VERSION="`git describe 2> /dev/null | grep collectd | sed -e 's/^collectd-//'`"
 
 if test -z "$VERSION"; then
        VERSION="$DEFAULT_VERSION"
@@ -10,4 +10,4 @@ fi
 
 VERSION="`echo \"$VERSION\" | sed -e 's/-/./g'`"
 
-echo -n "$VERSION"
+printf "%s" "$VERSION"