Update Icon Pack #233
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update Icon Pack | |
on: | |
# everyday at 08:15 UTC (arknights typically updates at 16:00 UTC+8) | |
schedule: | |
- cron: "15 8 * * *" | |
# trigger on manual dispatch | |
workflow_dispatch: | |
inputs: | |
force: | |
# use a dropdown to choose between true and false | |
description: "Force update even if there is no new version? " | |
required: true | |
type: choice | |
default: "false" | |
options: | |
- "true" | |
- "false" | |
jobs: | |
update: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.10" | |
- name: Install Poetry | |
run: | | |
pip install poetry==1.3.1 | |
- name: Install Dependencies | |
run: | | |
poetry install | |
- name: Run MultiServerIconPackUpdater | |
run: | | |
poetry run python penguin_recognizer_tools/icon/MultiServerIconPackUpdater.py | |
env: | |
CHAT_MASK: ${{ secrets.CHAT_MASK }} | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }} | |
AWS_S3_REGION: ${{ secrets.AWS_S3_REGION }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
UPYUN_ENDPOINT: ${{ secrets.UPYUN_ENDPOINT }} | |
UPYUN_PASSWORD: ${{ secrets.UPYUN_PASSWORD }} | |
UPYUN_USERNAME: ${{ secrets.UPYUN_USERNAME }} | |
PENGUIN_V3_ADMIN_KEY: ${{ secrets.PENGUIN_V3_ADMIN_KEY }} | |
PYTHONUNBUFFERED: "1" | |
# if force is true, set SKIP_UPDATE_CHECK to "1" | |
SKIP_UPDATE_CHECK: ${{ github.event.inputs.force == 'true' && '1' || '' }} |