Files
nexus/.gitea/workflows/ci.yml
2026-11-16 10:30:09 +01:00

40 lines
1.2 KiB
YAML

# Prüfung bei jedem Push auf einen Branch: Format, clippy, Rust-Tests, SDK-Tests (→ #1067).
# Läuft auf dem Runner `nexus-runner` (Label `nexus`, nur für dieses Repository).
# Bewusst KEIN Auslöser `pull_request`: Das Repository ist öffentlich, und der Runner hat den Docker-Socket.
# Code aus fremden Forks darf dort nicht laufen.
name: ci
on:
push:
branches:
- '**'
jobs:
pruefen:
runs-on: nexus
steps:
- uses: actions/checkout@v4
- name: Werkzeuge installieren
run: |
SUDO=""; [ "$(id -u)" -ne 0 ] && SUDO="sudo"
$SUDO apt-get update -qq
$SUDO apt-get install -y -qq musl-tools python3-venv
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal -c clippy,rustfmt -t x86_64-unknown-linux-musl
echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
- name: Format
run: cargo fmt --check
- name: clippy
run: cargo clippy --workspace --all-targets -- -D warnings
- name: Rust-Tests
run: cargo test --workspace
- name: SDK-Tests
run: |
python3 -m venv .venv
.venv/bin/pip install -q openai
.venv/bin/python -m unittest discover -s tests/sdk