Update assets #2893
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 assets | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "0 0,6,12,18 * * *" | |
jobs: | |
main: | |
runs-on: ubuntu-24.04 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Convert pyproject.toml to requirements.txt | |
run: | | |
curl -LsSf https://astral.sh/uv/install.sh | sh | |
uv pip compile pyproject.toml -o requirements.txt | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: "3.13" | |
cache: "pip" | |
- name: Install Python dependencies | |
run: pip install -r requirements.txt | |
- name: Set up Rust | |
uses: dtolnay/rust-toolchain@stable | |
- name: Set up Rust cache | |
uses: Swatinem/rust-cache@v2 | |
- name: Build app | |
run: cargo build --release | |
- name: Run app | |
run: ./target/release/arkdata | |
- name: Commit updates | |
run: | | |
git config --global user.name "Kawabot" | |
git config --global user.email "[email protected]" | |
git pull --all | |
git add cache | |
git add assets | |
git diff-index --quiet HEAD || git commit -m "Update data" && git push |