Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions flutter/example/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@ set -euo pipefail
# Or try out the Alpha version of the Sentry Dart Plugin that does it automatically for you, feedback is welcomed.
# https://github.com/getsentry/sentry-dart-plugin

export SENTRY_RELEASE=$(date +%Y-%m-%d_%H-%M-%S)
VERSION=$(grep '^version:' pubspec.yaml | awk '{print $2}')
CURRENT_DATE=$(date +%Y-%m-%d_%H-%M-%S)

export SENTRY_RELEASE="$CURRENT_DATE"@"$VERSION"

echo -e "[\033[92mrun\033[0m] $1"

Expand All @@ -23,7 +26,7 @@ elif [ "$1" == "android" ]; then
launchCmd='adb shell am start -n io.sentry.samples.flutter/io.sentry.samples.flutter.MainActivity'
echo -e "[\033[92mrun\033[0m] Android app installed"
elif [ "$1" == "web" ]; then
flutter build web --dart-define=SENTRY_RELEASE=$SENTRY_RELEASE --source-maps
flutter build web --dart-define=SENTRY_RELEASE="$SENTRY_RELEASE" --source-maps
buildDir='./build/web/'
port='8132'
ls -lah $buildDir
Expand Down