diff --git a/entrypoint.sh b/entrypoint.sh index beec7a6..d87bb2a 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -57,7 +57,7 @@ get_local_package_version() { PACKAGE=`echo "$PACKAGE_INFO" | cut -d' ' -f1` LOCAL_PACKAGE_VERSION=`echo "$PACKAGE_INFO" | cut -d' ' -f2` if [ -z "$PACKAGE" ]; then - echo "No package found. :(" + echo "::error::No package found. :(" echo "No package found. :(" >> $GITHUB_STEP_SUMMARY exit 1 fi @@ -71,14 +71,14 @@ get_local_package_version() { run_unit_tests() { if [ "$INPUT_SKIPTESTS" = "true" ]; then - echo "Skip unit tests set to true, skip unit testing." + echo "::notice::Skip unit tests set to true, skip unit testing." else HAS_BUILD_RUNNER=`echo "$DEPS_OUTPUT" | perl -n -e'/^.* build_runner (.*)/ && print $1'` HAS_BUILD_TEST=`echo "$DEPS_OUTPUT" | perl -n -e'/^.* build_test (.*)/ && print $1'` HAS_TEST=`echo "$DEPS_OUTPUT" | perl -n -e'/^.* (test|flutter_test) (.*)/ && print $2'` if [ "$HAS_BUILD_RUNNER" != "" ] && [ "$HAS_BUILD_TEST" != "" ] && [ "$INPUT_SUPPRESSBUILDRUNNER" != "true" ]; then if [ "$INPUT_FLUTTER" = "true" ]; then - echo "flutter tests with build_runner" + echo "::notice::flutter tests with build_runner" flutter pub run build_runner build --delete-conflicting-outputs flutter test else @@ -92,7 +92,7 @@ run_unit_tests() { dart pub run test fi else - echo "No unit test related dependencies detected, skip unit testing." + echo "::notice::No unit test related dependencies detected, skip unit testing." echo "No unit test related dependencies detected, skip unit testing." >> $GITHUB_STEP_SUMMARY fi fi @@ -109,9 +109,9 @@ get_remote_package_version() { if [ -z "$REMOTE_PACKAGE_VERSION" ]; then REMOTE_PACKAGE_VERSION="✗" fi - echo "Local version: [$LOCAL_PACKAGE_VERSION]" + echo "::notice::Local version: [$LOCAL_PACKAGE_VERSION]" echo "Local version: [$LOCAL_PACKAGE_VERSION]" >> $GITHUB_STEP_SUMMARY - echo "Remote version: [$REMOTE_PACKAGE_VERSION]" + echo "::notice::Remote version: [$REMOTE_PACKAGE_VERSION]" echo "Remote version: [$REMOTE_PACKAGE_VERSION]" >> $GITHUB_STEP_SUMMARY echo "remoteVersion=$REMOTE_PACKAGE_VERSION" >> $GITHUB_OUTPUT } @@ -128,7 +128,7 @@ format() { publish() { if [ "$LOCAL_PACKAGE_VERSION" = "$REMOTE_PACKAGE_VERSION" ]; then - echo "Remote & Local versions are equal, skip publishing." + echo "::notice::Remote & Local versions are equal, skip publishing." echo "Remote & Local versions are equal, skip publishing." >> $GITHUB_STEP_SUMMARY else mkdir -p ~/.config/dart @@ -151,16 +151,16 @@ EOF dart pub lish --dry-run fi if [ $? -eq 0 ]; then - echo "Dry Run Successfull." + echo "::notice::Dry Run Successfull." else if [ "$INPUT_FORCE" != "true" ] && [ "$INPUT_TESTRUNONLY" != "true" ]; then - echo "Dry Run Failed, skip real publishing." + echo "::error::Dry Run Failed, skip real publishing." echo "Dry Run Failed, skip real publishing." >> $GITHUB_STEP_SUMMARY exit 1 fi fi if [ "$INPUT_DRYRUNONLY" = "true" ]; then - echo "Dry run only, skip publishing." + echo "::notice::Dry run only, skip publishing." echo "Dry run only, skip publishing." >> $GITHUB_STEP_SUMMARY else if [ "$INPUT_FLUTTER" = "true" ]; then