From 7f8e9dba7c29175dca1037e2f3bc82ca0fde1947 Mon Sep 17 00:00:00 2001 From: Michael Hoffmann Date: Tue, 11 Oct 2022 11:23:15 +0200 Subject: [PATCH] ref: Use constant for the SDK version docs: Update README.md & CONTRIBUTING.md (#650) * docs: Update README.md & CONTRIBUTING.md * Add slogan test: Add dsn to e2e test config (#657) * test: Add dsn to e2e test config * Add phpstan exclusion Fix Symfony 6 deprecations in E2E test (#656) fix: Update span ops (#655) docs: Update changelog (#658) Prepare release 4.3.1 (#659) Update phpstan.neon Add bump-version.sh --- .craft.yml | 1 - phpstan.neon | 2 ++ scripts/bump-version.sh | 24 ++++++++++++++++++++++++ 3 files changed, 26 insertions(+), 1 deletion(-) create mode 100755 scripts/bump-version.sh diff --git a/.craft.yml b/.craft.yml index df763ddc..eacd7244 100644 --- a/.craft.yml +++ b/.craft.yml @@ -2,7 +2,6 @@ minVersion: 0.23.1 changelogPolicy: simple artifactProvider: name: none -preReleaseCommand: '' targets: - name: github - name: registry diff --git a/phpstan.neon b/phpstan.neon index c9363548..684f3989 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -16,6 +16,8 @@ parameters: - src/Tracing/Doctrine/DBAL/TracingDriverForV2.php - src/Tracing/HttpClient/TraceableHttpClientForV4.php - src/Tracing/HttpClient/TraceableHttpClientForV5.php + - src/Tracing/HttpClient/TraceableResponseForV4.php + - src/Tracing/HttpClient/TraceableResponseForV5.php - tests/End2End/App - tests/Tracing/Doctrine/DBAL/TracingDriverForV2Test.php - tests/EventListener/Fixtures/UserWithoutIdentifierStub.php diff --git a/scripts/bump-version.sh b/scripts/bump-version.sh new file mode 100755 index 00000000..cc9b06ff --- /dev/null +++ b/scripts/bump-version.sh @@ -0,0 +1,24 @@ +#!/bin/bash +set -eux + +# if [ "$(uname -s)" != "Linux" ]; then +# echo "Please use the GitHub Action." +# exit 1 +# fi + +SCRIPT_DIR="$( dirname "$0" )" +cd $SCRIPT_DIR/.. + +OLD_VERSION="${1}" +NEW_VERSION="${2}" + +echo "Current version: $OLD_VERSION" +echo "Bumping version: $NEW_VERSION" + +function replace() { + ! grep "$2" $3 + perl -i -pe "s/$1/$2/g" $3 + grep "$2" $3 # verify that replacement was successful +} + +replace "SDK_VERSION = '[0-9.]+'" "SDK_VERSION = '$NEW_VERSION'" ./src/SentryBundle.php \ No newline at end of file