From 57156f93cf564cdbb1845103bc42a0215a3550db Mon Sep 17 00:00:00 2001 From: Oliver Tacke Date: Tue, 30 Apr 2024 14:40:20 +0200 Subject: [PATCH] Fix echo color --- .github/scripts/run-playwright.sh | 2 +- .github/scripts/setup-test.sh | 2 +- .github/scripts/start-h5p-cli-server.sh | 6 +++--- .github/scripts/stop-h5p-cli-server.sh | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/scripts/run-playwright.sh b/.github/scripts/run-playwright.sh index ec1bae8..125df8c 100755 --- a/.github/scripts/run-playwright.sh +++ b/.github/scripts/run-playwright.sh @@ -1,5 +1,5 @@ #!/bin/bash -echo "${COLOR_BLUE}Running end-to-end tests${COLOR_OFF}" +echo -e "${COLOR_BLUE}Running end-to-end tests${COLOR_OFF}" npx playwright test "$H5P_CONTENT_REPOSITORY_DIR/tests/main.spec.js" diff --git a/.github/scripts/setup-test.sh b/.github/scripts/setup-test.sh index b724d95..a249d17 100755 --- a/.github/scripts/setup-test.sh +++ b/.github/scripts/setup-test.sh @@ -1,6 +1,6 @@ #!/bin/bash -echo "${COLOR_BLUE}Setting up test content${COLOR_OFF}" +echo -e "${COLOR_BLUE}Setting up test content${COLOR_OFF}" if [ ! -d "$H5P_CONTENT_REPOSITORY_DIR/assets" ]; then mkdir assets diff --git a/.github/scripts/start-h5p-cli-server.sh b/.github/scripts/start-h5p-cli-server.sh index 26aa561..a6d168c 100755 --- a/.github/scripts/start-h5p-cli-server.sh +++ b/.github/scripts/start-h5p-cli-server.sh @@ -1,6 +1,6 @@ #!/bin/bash -echo "${COLOR_BLUE}Starting H5P CLI server${COLOR_OFF}" +echo -e "${COLOR_BLUE}Starting H5P CLI server${COLOR_OFF}" if ! netstat -tln | grep ":8080 " >/dev/null; then cd "$H5P_CLI_DIR" @@ -12,8 +12,8 @@ if ! netstat -tln | grep ":8080 " >/dev/null; then H5P_CLI_SERVER_PID=$! export H5P_CLI_SERVER_PID - echo "${COLOR_BLUE}...Started H5P CLI server detached with PID $H5P_CLI_SERVER_PID${COLOR_OFF}" + echo -e "${COLOR_BLUE}...Started H5P CLI server detached with PID $H5P_CLI_SERVER_PID${COLOR_OFF}" cd "$H5P_CONTENT_REPOSITORY_DIR" else - echo "${COLOR_RED}...Could not start H5P CLI server, is it running already? Will assume it is.${COLOR_OFF}" + echo -e "${COLOR_RED}...Could not start H5P CLI server, is it running already? Will assume it is.${COLOR_OFF}" fi diff --git a/.github/scripts/stop-h5p-cli-server.sh b/.github/scripts/stop-h5p-cli-server.sh index 216dd75..0698d85 100755 --- a/.github/scripts/stop-h5p-cli-server.sh +++ b/.github/scripts/stop-h5p-cli-server.sh @@ -1,6 +1,6 @@ #!/bin/bash -echo "${COLOR_BLUE}Stopping H5P CLI server${COLOR_OFF}" +echo -e "${COLOR_BLUE}Stopping H5P CLI server${COLOR_OFF}" if [ -n "$H5P_CLI_SERVER_PID" ]; then kill $H5P_CLI_SERVER_PID @@ -9,6 +9,6 @@ else PROBABLE_ID=$(lsof -i :8080 -sTCP:LISTEN -n -P | grep LISTEN | grep node | grep $(whoami) | awk '{print $2}') if [ -n "$PROBABLE_ID" ]; then - echo "${COLOR_RED}... A server seems to have been running before running the test. You should be able to stop it manually yourself or by running 'kill -9 $PROBABLE_ID'${COLOR_OFF}" + echo -e "${COLOR_RED}... A server seems to have been running before running the test. You should be able to stop it manually yourself or by running 'kill -9 $PROBABLE_ID'${COLOR_OFF}" fi fi