diff --git a/.github/workflows/cmake-build.yaml b/.github/workflows/cmake-build.yaml index f96f6ebab..d03813c66 100644 --- a/.github/workflows/cmake-build.yaml +++ b/.github/workflows/cmake-build.yaml @@ -282,3 +282,28 @@ jobs: steps: - name: No relevant C++ or CMake changes detected run: echo "::notice::No relevant C++ or CMake changes detected; build skipped." + + build-complete: + needs: [pre-check, build] + if: > + always() && + github.event_name == 'issue_comment' && + needs.pre-check.result == 'success' + runs-on: ubuntu-latest + permissions: + pull-requests: write + + steps: + - name: Comment on build completion + uses: thollander/actions-comment-pull-request@24bffb9b452ba05a4f3f77933840a6a841d1b32b # v3.0.1 + with: + message: | + Build and test workflow completed. + + **Result:** ${{ needs.build.result == 'success' && '✅ All builds and tests passed.' + || needs.build.result == 'failure' && '❌ Some builds or tests failed.' + || needs.build.result == 'cancelled' && '⚠️ Build was cancelled before completion.' + || needs.build.result == 'skipped' && 'ℹ️ Build job was skipped.' + || format('ℹ️ Build job completed with status: {0}.', needs.build.result) }} + + See the [workflow run](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}) for detailed results. diff --git a/.github/workflows/markdown-fix.yaml b/.github/workflows/markdown-fix.yaml index 70ee10695..fb658d3ed 100644 --- a/.github/workflows/markdown-fix.yaml +++ b/.github/workflows/markdown-fix.yaml @@ -76,14 +76,19 @@ jobs: repository: ${{ needs.pre-check.outputs.repo }} token: ${{ secrets.WORKFLOW_PAT }} - - name: Run markdownlint - uses: DavidAnson/markdownlint-cli2-action@07035fd053f7be764496c0f8d8f9f41f98305101 # v22.0.0 + - name: Set up Node.js + uses: actions/setup-node@42a6b3698c7ed2d0a0c63ba202543c60838be1e7 # v6.0.0 with: - globs: | - ${{ env.local_checkout_path }}/**/*.md - !${{ env.local_checkout_path }}/**/CHANGELOG.md - fix: true - continue-on-error: true + node-version: '20' + + - name: Install markdownlint-cli2 + run: npm install -g markdownlint-cli2 + + - name: Run markdownlint-cli2 fix + working-directory: ${{ env.local_checkout_path }} + run: | + echo "Fixing Markdown format with markdownlint-cli2..." + markdownlint-cli2 --fix "**/*.md" "!**/CHANGELOG.md" || true - name: Handle fix commit uses: Framework-R-D/phlex/.github/actions/handle-fix-commit@main