Skip to content

Commit

Permalink
Update build.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
nixel2007 authored Oct 2, 2024
1 parent 7d19db1 commit a11bd84
Showing 1 changed file with 16 additions and 4 deletions.
20 changes: 16 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,21 @@ jobs:
run: |
docker run -d -p 5000:5000 --name registry registry:2
./${{ matrix.script }}
- name: Set Job Status
- name: Update PR Check Status
if: always()
uses: s4u/set-job-status-action@v1
uses: actions/github-script@v6
with:
status: ${{ job.status }}
github_token: ${{ secrets.GITHUB_TOKEN }}
script: |
const conclusion = '${{ job.status }}' === 'success' ? 'success' : 'failure';
await github.rest.checks.create({
owner: context.repo.owner,
repo: context.repo.repo,
name: 'Build Workflow - ${{ matrix.script }}',
head_sha: '${{ github.event.workflow_run.head_sha }}',
status: 'completed',
conclusion,
output: {
title: 'Build Workflow - ${{ matrix.script }}',
summary: `Workflow for script '${{ matrix.script }}' completed with conclusion: ${conclusion}`
}
});

0 comments on commit a11bd84

Please sign in to comment.