Skip to content

Commit

Permalink
here-docs code improvement for GHA summary to maven-cd.yml runs (#33) (
Browse files Browse the repository at this point in the history
…#34)

* here-docs code improvement for GHA summary to maven-cd.yml runs (#33)

* Simplify  .github/workflows/maven-cd.yml - enclose markdown code format wrapper with single quotessingle quote

Co-authored-by: Jesse Glick <jglick@cloudbees.com>

* Simplify .github/workflows/maven-cd.yml - make use of cat ... | tee -a in a single line

Co-authored-by: Jesse Glick <jglick@cloudbees.com>

---------

Co-authored-by: Jesse Glick <jglick@cloudbees.com>
  • Loading branch information
mhoffrog and jglick authored Sep 20, 2024
1 parent 83dcb44 commit 4f9dc4e
Showing 1 changed file with 14 additions and 11 deletions.
25 changes: 14 additions & 11 deletions .github/workflows/maven-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,17 +51,20 @@ jobs:
- name: Log should_release details
id: log-should_release-details
run: |
echo "## Job Filter Summary" >> $GITHUB_STEP_SUMMARY
echo "\`\`\`" >> $GITHUB_STEP_SUMMARY
echo "================================" | tee -a $GITHUB_STEP_SUMMARY
echo "Release job filter details:" | tee -a $GITHUB_STEP_SUMMARY
echo " VALIDATE_ONLY: ${VALIDATE_ONLY}" | tee -a $GITHUB_STEP_SUMMARY
echo " CI_STATUS: ${CI_STATUS}" | tee -a $GITHUB_STEP_SUMMARY
echo " INTERESTING_CATEGORY: ${INTERESTING_CATEGORY}" | tee -a $GITHUB_STEP_SUMMARY
echo "--------------------------------" | tee -a $GITHUB_STEP_SUMMARY
echo "=> SHOULD_RELEASE: ${SHOULD_RELEASE}" | tee -a $GITHUB_STEP_SUMMARY
echo "================================" | tee -a $GITHUB_STEP_SUMMARY
echo "\`\`\`" >> $GITHUB_STEP_SUMMARY
MD_CODE='```'
cat << END_OF_SUMMARY | tee -a $GITHUB_STEP_SUMMARY
## Job Filter Summary
${MD_CODE}
================================
Release job filter details:
VALIDATE_ONLY: ${VALIDATE_ONLY}
CI_STATUS: ${CI_STATUS}
INTERESTING_CATEGORY: ${INTERESTING_CATEGORY}
--------------------------------
=> SHOULD_RELEASE: ${SHOULD_RELEASE}
================================
${MD_CODE}
END_OF_SUMMARY
env:
VALIDATE_ONLY: ${{ inputs.validate_only }}
CI_STATUS: ${{ steps.verify-ci-status.outputs.result }}
Expand Down

0 comments on commit 4f9dc4e

Please sign in to comment.