-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (32 loc) · 1.05 KB
/
leaderboard_work.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: Publish Advent of Code Statistics to Work Slack
on:
schedule:
# 10pm Central time, December 1-30
- cron: '0 4 2-31 12 *'
# 10pm Central time, December 31 & January 1
- cron: '0 4 1-2 1 *'
workflow_dispatch:
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.8
- name: Install Poetry
uses: snok/[email protected]
with:
virtualenvs-create: true
virtualenvs-in-project: true
- name: Install dependencies with poetry
run: poetry install --no-interaction --no-dev --extras leaderboard
- name: Run Python script
run: |
poetry run python .github/leaderboard.py
env:
LEADERBOARD_ID: ${{ secrets.LEADERBOARD_ID }}
SESSION_ID: ${{ secrets.SESSION_ID }}
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_WORK }}