From 0492ca26ec49dbf94b475e7541ea2faffecd599d Mon Sep 17 00:00:00 2001 From: ChillerDragon Date: Tue, 25 Jun 2024 12:18:42 +0800 Subject: [PATCH] Fix sys/game check in CI --- .github/workflows/main.yml | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 739013c..7efa949 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -71,11 +71,17 @@ jobs: - name: Check game messages run: | - errors="$(grep -FA1 'System()' $(grep MsgGame -lr messages7/) | grep "return true")" - [ "$errors" = "" ] || { printf '%s\n' "$errors"; exit 1; } + if errors="$(grep -FA1 'System()' $(grep MsgGame -lr messages7/) | grep "return true")" + then + printf '%s\n' "$errors" + exit 1 + fi - name: Check system messages run: | - errors="$(grep -FA1 'System()' $(grep MsgSys -lr messages7/) | grep "return false")" - [ "$errors" = "" ] || { printf '%s\n' "$errors"; exit 1; } + if errors="$(grep -FA1 'System()' $(grep MsgSys -lr messages7/) | grep "return false")" + then + printf '%s\n' "$errors" + exit 1 + fi