diff --git a/.github/workflows/translations-pull.yml b/.github/workflows/translations-pull.yml index 057381f8a..eb12ddda1 100644 --- a/.github/workflows/translations-pull.yml +++ b/.github/workflows/translations-pull.yml @@ -41,11 +41,11 @@ jobs: author: github-actions # owner of the commit body: | Pulled all translated strings from [Transifex][1]. - + --- *This PR is automatically generated and updated by the workflow at `.github/workflows/translations-pull.yml`. Review [action runs][2].*
*After merging, all new languages and translations are available in the next build.* - + [1]: https://explore.transifex.com/cockatrice/cockatrice/ [2]: https://github.com/Cockatrice/Cockatrice/actions/workflows/translations-pull.yml?query=branch%3Amaster branch: ci-update_translations @@ -61,11 +61,16 @@ jobs: if: github.event_name != 'pull_request' shell: bash env: - STATUS: ${{ steps.create_pr.outputs.pull-request-operation }} + PR_NUMBER: ${{ steps.create_pr.outputs.pull-request-number }} + PR_URL: ${{ steps.create_pr.outputs.pull-request-url }} + STATUS: >- + ${{ + case( + steps.create_pr.outputs.pull-request-operation == 'none', + 'unchanged', + steps.create_pr.outputs.pull-request-operation + ) + }} run: | - if [[ "$STATUS" == "none" ]]; then - echo "PR #${{ steps.create_pr.outputs.pull-request-number }} unchanged!" >> $GITHUB_STEP_SUMMARY - else - echo "PR #${{ steps.create_pr.outputs.pull-request-number }} $STATUS!" >> $GITHUB_STEP_SUMMARY - fi - echo "URL: ${{ steps.create_pr.outputs.pull-request-url }}" >> $GITHUB_STEP_SUMMARY + echo "PR #$PR_NUMBER $STATUS!" >> "$GITHUB_STEP_SUMMARY" + echo "URL: $PR_URL" >> "$GITHUB_STEP_SUMMARY" diff --git a/.github/workflows/translations-push.yml b/.github/workflows/translations-push.yml index 4adcaf4a4..a4a32b979 100644 --- a/.github/workflows/translations-push.yml +++ b/.github/workflows/translations-push.yml @@ -29,12 +29,13 @@ jobs: sudo apt-get install -y --no-install-recommends qttools5-dev-tools - name: "Update Cockatrice translation source" + env: + FILE: cockatrice/cockatrice_en@source.ts id: cockatrice shell: bash - run: | - FILE="cockatrice/cockatrice_en@source.ts" - export DIRS="cockatrice/src $(find . -maxdepth 1 -type d -name 'libcockatrice_*')" - FILE="$FILE" DIRS="$DIRS" .ci/update_translation_source_strings.sh + run: > + DIRS="cockatrice/src $(find . -maxdepth 1 -type d -name 'libcockatrice_*')" + .ci/update_translation_source_strings.sh - name: "Update Oracle translation source" id: oracle @@ -77,11 +78,16 @@ jobs: if: github.event_name != 'pull_request' shell: bash env: - STATUS: ${{ steps.create_pr.outputs.pull-request-operation }} + PR_NUMBER: ${{ steps.create_pr.outputs.pull-request-number }} + PR_URL: ${{ steps.create_pr.outputs.pull-request-url }} + STATUS: >- + ${{ + case( + steps.create_pr.outputs.pull-request-operation == 'none', + 'unchanged', + steps.create_pr.outputs.pull-request-operation + ) + }} run: | - if [[ "$STATUS" == "none" ]]; then - echo "PR #${{ steps.create_pr.outputs.pull-request-number }} unchanged!" >> $GITHUB_STEP_SUMMARY - else - echo "PR #${{ steps.create_pr.outputs.pull-request-number }} $STATUS!" >> $GITHUB_STEP_SUMMARY - fi - echo "URL: ${{ steps.create_pr.outputs.pull-request-url }}" >> $GITHUB_STEP_SUMMARY + echo "PR #$PR_NUMBER $STATUS!" >> "$GITHUB_STEP_SUMMARY" + echo "URL: $PR_URL" >> "$GITHUB_STEP_SUMMARY"