diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 890616a4..eefd3035 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -317,6 +317,7 @@ check commits: script: - ci-fairy check-commits --textwidth 0 --no-signed-off-by - ci/check-for-symlinks.sh + - ci/check-meson-version.sh clippy: extends: '.debian:12-stable' diff --git a/ci/check-meson-version.sh b/ci/check-meson-version.sh new file mode 100755 index 00000000..e131b03c --- /dev/null +++ b/ci/check-meson-version.sh @@ -0,0 +1,14 @@ +#!/bin/bash + +MESON_VERSION=`head -n5 meson.build | grep ' version\s*:' | sed -e "s/.*version\s*:\s*'//" -e "s/',.*//"` +CARGO_VERSION=`cat Cargo.toml | grep -A1 workspace.package | grep ^version | sed -e 's/^version = "\(.*\)"/\1/'` + +echo "gst-plugins-rs version (meson.build) : $MESON_VERSION" +echo "gst-plugins-rs version (Cargo.toml) : $CARGO_VERSION" + +if test "x$MESON_VERSION" != "x$CARGO_VERSION"; then + echo + echo "===> Version mismatch between meson.build and Cargo.toml! <===" + echo + exit 1; +fi