Skip to content
This repository has been archived by the owner on Jul 1, 2024. It is now read-only.

Merge branch 'main' #52

Merge branch 'main'

Merge branch 'main' #52

Workflow file for this run

name: GET scoreboard
on:
workflow_dispatch:
branches: [ main ]
push:
branches: [ main ]
env:
SCORE_FILE: "scores.json"
jobs:
scores:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: "3.11"
- name: Get scores
id: score
run: |
curl --location '${{ vars.BASE_URL }}scoreboard' --header ${{ secrets.TOKEN }} -o ${{ env.SCORE_FILE }}
echo "latest=$(make SCORES=${{ env.SCORE_FILE }} score)" >> $GITHUB_OUTPUT
- name: Discord post
if: ${{ env.DISCORD_WEBHOOK != '' && vars.DISCORD_ON != 0 }}
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
uses: Ilshidur/action-discord@master
with:
args: "**ICFPC Scoreboard** ${{ steps.score.outputs.latest }}"