Skip to content

Commit

Permalink
Merge branch 'test2' into test3
Browse files Browse the repository at this point in the history
  • Loading branch information
galipremsagar committed Apr 3, 2024
2 parents 126571e + 05ee02f commit d879c4c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/status.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ jobs:
REPO_NAME: ${{ github.repository }}
ATTEMPTS: ${{ github.event.workflow_run.run_attempt }}
run: |
JOB_ID=$(gh api repos/$REPO_NAME/actions/runs/$WORKFLOW_RUN_ID/jobs | jq -r '.jobs[0].id')
CONTENT_JSON=$(echo $ARTIFACT_CONTENT | jq .)
CUSTOM_CONTEXT=$(echo $CONTENT_JSON | jq -r .context)
CUSTOM_DESCRIPTION=$(echo $CONTENT_JSON | jq -r .description)
Expand All @@ -50,11 +51,9 @@ jobs:
if [ -z "$CUSTOM_TARGET_URL" ] || [ "$CUSTOM_TARGET_URL" = "null" ]; then CUSTOM_TARGET_URL="https://github.com/$REPO_NAME/actions/runs/$WORKFLOW_RUN_ID/attempts/$ATTEMPTS#summary-$JOB_ID"; fi
if [ -z "$CUSTOM_STATE" ] || [ "$CUSTOM_STATE" = "null" ]; then CUSTOM_STATE="success"; fi
# Authenticate gh CLI
# echo "$GITHUB_TOKEN" | gh auth login --with-token
# Fetch the first job ID from the workflow run
JOB_ID=$(gh api repos/$REPO_NAME/actions/runs/$WORKFLOW_RUN_ID/jobs | jq -r '.jobs[0].id')
echo "Job ID: $JOB_ID"
echo $CUSTOM_CONTEXT
echo $CUSTOM_DESCRIPTION
Expand Down

0 comments on commit d879c4c

Please sign in to comment.