Skip to content

Commit cbc998f

Browse files
committed
FIX: Fix C++ client get_version script
1 parent e57fafb commit cbc998f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

scripts/get_version.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,6 @@
22

33
SCRIPTS_DIR="$(cd "$(dirname "$0")" || exit; pwd -P)"
44
PROJECT_ROOT_DIR="$(dirname "${SCRIPTS_DIR}")"
5-
grep '^project("databento" VERSION' "${PROJECT_ROOT_DIR}/CMakeLists.txt" | cut -d' ' -f3
5+
grep --after-context=2 '^project($' "${PROJECT_ROOT_DIR}/CMakeLists.txt" \
6+
| grep --perl-regexp --only-matching 'VERSION \d+\.\d+\.\d+' \
7+
| cut --delimiter=' ' --fields=2

0 commit comments

Comments
 (0)