38 lines
1.1 KiB
YAML
38 lines
1.1 KiB
YAML
on:
|
|
push:
|
|
paths-ignore:
|
|
- "**/*.md"
|
|
- "**/*.sh"
|
|
- "**/*.sh.in"
|
|
- "**/*.yml"
|
|
|
|
env:
|
|
CARGO_TERM_COLOR: always
|
|
DEBIAN_FRONTEND: noninteractive
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: docker
|
|
container:
|
|
image: betaco.de/mirror/rust:nightly-bookworm-slim
|
|
options: --user root
|
|
steps:
|
|
- name: Determine prerequisites
|
|
id: prereq
|
|
run: |
|
|
echo "install_node=$(command -v node >/dev/null 2>&1 && echo 0 || echo 1)" >> $GITHUB_OUTPUT
|
|
- name: Install node
|
|
if: ${{ steps.prereq.outputs.install_node == '1' }}
|
|
run: apt-get -qq update && apt-get -qq install -y --no-install-recommends nodejs
|
|
- name: Install git
|
|
run: apt-get -qq install -y --no-install-recommends git
|
|
- name: Install clippy
|
|
run: rustup component add clippy
|
|
- name: Clone repository
|
|
uses: actions/checkout@v4
|
|
- name: Build
|
|
run: cargo build --workspace --all-targets
|
|
- name: Run tests
|
|
run: cargo test --workspace
|
|
- name: Run clippy
|
|
run: cargo clippy --no-deps
|