Skip to content

Commit

Permalink
fixup! Add github action to update parliament data
Browse files Browse the repository at this point in the history
  • Loading branch information
ajparsons committed Feb 26, 2025
1 parent 168e1dd commit 6e34f76
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions .github/workflows/update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,10 @@ jobs:
id: update
run: |
output=$(poetry run scripts/dataupdate --verbose)
echo "update_output=$output" >> "$GITHUB_OUTPUT"
output=$(echo "$output" | jq -sR .)
echo "update_output<<EOF" >> "$GITHUB_OUTPUT"
echo "$output" >> "$GITHUB_OUTPUT"
echo "EOF" >> "$GITHUB_OUTPUT"
- name: Push new data
id: auto-commit-action
Expand All @@ -48,8 +51,8 @@ jobs:
payload: |
{
"repo_url": "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}",
"status:" "success",
"content": "${{ steps.update.outputs.update_output }}"
"status": "success",
"content": ${{ steps.update.outputs.update_output }}
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.PARLPARSE_SLACK_WEBHOOK }}
Expand All @@ -61,9 +64,9 @@ jobs:
with:
payload: |
{
"repo_url": "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
"status:" "failed"
"content": "${{ steps.update.outputs.update_output }}"
"repo_url": "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}",
"status": "failed",
"content": ${{ steps.update.outputs.update_output }}
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.PARLPARSE_SLACK_WEBHOOK }}

0 comments on commit 6e34f76

Please sign in to comment.