Skip to content

0-7 Update Branch Status #2

0-7 Update Branch Status

0-7 Update Branch Status #2

name: 0-7 Update Branch Status
on:
workflow_run:
workflows: ["0-7 Cron"]
types:
- completed
jobs:
update_status:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
ref: 0-7
- name: get SHA
run: echo "SHA=$(git rev-parse HEAD)" >> $GITHUB_ENV
- name: Update commit status
run: |
env
curl \
-X POST \
-H "Authorization: token ${{ secrets.GH_TOKEN }}" \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/${{ github.repository }}/statuses/${{ env.SHA }} \
-d '{"state": "${{ github.event.workflow_run.conclusion }}", "context": "Cron"}'