Skip to content

Commit

Permalink
Skip core/Version.php version check for preview version builds
Browse files Browse the repository at this point in the history
  • Loading branch information
michalkleiner committed May 9, 2024
1 parent 3c18c7a commit a60aa6a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .github/scripts/build-package.sh
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,10 @@ echo "Git tag: $(git describe --exact-match --tags HEAD)"
echo "Git path: $CURRENT_DIR/$LOCAL_REPO"
echo "Matomo version in core/Version.php: $(php -r "include_once 'core/Version.php'; echo \Piwik\Version::VERSION;")"

if [ "$VERSION" != "build" ]; then
IS_PREVIEW_VERSION=$(php -r "include_once 'core/Version.php'; \$v = new \Piwik\Version(); echo (int) \$v->isPreviewVersion('$VERSION');")

if [ "$VERSION" != "build" ] && [ "$IS_PREVIEW_VERSION" == "0" ]
then
[ "$(grep "'$VERSION'" core/Version.php | wc -l)" = "1" ] || die "version $VERSION does not match core/Version.php";
fi

Expand Down

0 comments on commit a60aa6a

Please sign in to comment.