Skip to content

Commit

Permalink
Replace get-version.sh in docs
Browse files Browse the repository at this point in the history
This tried to parse version.h which doesn't work anymore with the new
versioning scheme.
  • Loading branch information
arogge committed Nov 13, 2019
1 parent d638b91 commit 3f33d70
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions docs/manuals/source/get-version.sh
@@ -1,8 +1,10 @@
#!/bin/bash

VERSION_H=../../../core/src/include/version.h
if [ -f ${VERSION_H} ]; then
grep "^#define VERSION" ${VERSION_H} | cut -b 17- | sed 's/"//g'
if type -p cmake3 >/dev/null 2>&1; then
cmake="$(type -p cmake3)"
else
cd ../../ && dpkg-parsechangelog | grep Version | cut -b 10-
cmake="$(type -p cmake)"
fi

pushd "$(dirname "$0")/../../.." >/dev/null
"$cmake" -P get_version.cmake | sed -e 's/^-- //'

0 comments on commit 3f33d70

Please sign in to comment.