All checks were successful
Release Docker Image / define-variables (push) Successful in 1s
Documentation / Build and Deploy Documentation (push) Successful in 33s
Rust Checks / Format (push) Successful in 35s
Rust Checks / Cargo Test (push) Successful in 3m24s
Rust Checks / Clippy (push) Successful in 2m45s
Release Docker Image / build-image (linux/amd64, linux-amd64) (push) Successful in 24m57s
Release Docker Image / build-image (linux/arm64, linux-arm64) (push) Successful in 24m4s
Release Docker Image / merge (push) Successful in 26s
142 lines
3.7 KiB
YAML
142 lines
3.7 KiB
YAML
name: Rust Checks
|
|
|
|
on:
|
|
push:
|
|
|
|
jobs:
|
|
format:
|
|
name: Format
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- name: Install rust
|
|
uses: ./.forgejo/actions/rust-toolchain
|
|
with:
|
|
toolchain: "nightly"
|
|
components: "rustfmt"
|
|
|
|
- name: Check formatting
|
|
run: |
|
|
cargo +nightly fmt --all -- --check
|
|
|
|
clippy:
|
|
name: Clippy
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- name: Install rust
|
|
uses: ./.forgejo/actions/rust-toolchain
|
|
|
|
- uses: https://github.com/actions/create-github-app-token@v2
|
|
id: app-token
|
|
with:
|
|
app-id: ${{ vars.GH_APP_ID }}
|
|
private-key: ${{ secrets.GH_APP_PRIVATE_KEY }}
|
|
github-api-url: https://api.github.com
|
|
owner: ${{ vars.GH_APP_OWNER }}
|
|
repositories: ""
|
|
- name: Install sccache
|
|
uses: ./.forgejo/actions/sccache
|
|
with:
|
|
token: ${{ steps.app-token.outputs.token }}
|
|
- run: sudo apt-get update
|
|
- name: Install system dependencies
|
|
uses: https://github.com/awalsh128/cache-apt-pkgs-action@v1
|
|
with:
|
|
packages: clang liburing-dev
|
|
version: 1
|
|
- name: Cache Rust registry
|
|
uses: actions/cache@v3
|
|
with:
|
|
path: |
|
|
~/.cargo/git
|
|
!~/.cargo/git/checkouts
|
|
~/.cargo/registry
|
|
!~/.cargo/registry/src
|
|
key: rust-registry-${{hashFiles('**/Cargo.lock') }}
|
|
- name: Timelord
|
|
uses: ./.forgejo/actions/timelord
|
|
with:
|
|
key: sccache-v0
|
|
path: .
|
|
- name: Clippy
|
|
run: |
|
|
cargo clippy \
|
|
--workspace \
|
|
--locked \
|
|
--no-deps \
|
|
--profile test \
|
|
-- \
|
|
-D warnings
|
|
|
|
- name: Show sccache stats
|
|
if: always()
|
|
run: sccache --show-stats
|
|
|
|
cargo-test:
|
|
name: Cargo Test
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- name: Install rust
|
|
uses: ./.forgejo/actions/rust-toolchain
|
|
|
|
- uses: https://github.com/actions/create-github-app-token@v2
|
|
id: app-token
|
|
with:
|
|
app-id: ${{ vars.GH_APP_ID }}
|
|
private-key: ${{ secrets.GH_APP_PRIVATE_KEY }}
|
|
github-api-url: https://api.github.com
|
|
owner: ${{ vars.GH_APP_OWNER }}
|
|
repositories: ""
|
|
- name: Install sccache
|
|
uses: ./.forgejo/actions/sccache
|
|
with:
|
|
token: ${{ steps.app-token.outputs.token }}
|
|
- run: sudo apt-get update
|
|
- name: Install system dependencies
|
|
uses: https://github.com/awalsh128/cache-apt-pkgs-action@v1
|
|
with:
|
|
packages: clang liburing-dev
|
|
version: 1
|
|
- name: Cache Rust registry
|
|
uses: actions/cache@v3
|
|
with:
|
|
path: |
|
|
~/.cargo/git
|
|
!~/.cargo/git/checkouts
|
|
~/.cargo/registry
|
|
!~/.cargo/registry/src
|
|
key: rust-registry-${{hashFiles('**/Cargo.lock') }}
|
|
- name: Timelord
|
|
uses: ./.forgejo/actions/timelord
|
|
with:
|
|
key: sccache-v0
|
|
path: .
|
|
- name: Cargo Test
|
|
run: |
|
|
cargo test \
|
|
--workspace \
|
|
--locked \
|
|
--profile test \
|
|
--all-targets \
|
|
--no-fail-fast
|
|
|
|
- name: Show sccache stats
|
|
if: always()
|
|
run: sccache --show-stats
|