Skip to content

Make Serde into an optional dependency #202

Make Serde into an optional dependency

Make Serde into an optional dependency #202

Workflow file for this run

name: Build
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
release:
types: [ published ]
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-latest
env:
RUST_BACKTRACE: 1
steps:
- uses: actions/checkout@v4
- name: rust-info
run: rustc --version && cargo --version
- uses: Swatinem/rust-cache@v2
if: github.event_name != 'release' && github.event_name != 'workflow_dispatch'
- name: install varnish-dev
run: |
curl -s https://packagecloud.io/install/repositories/varnishcache/varnish75/script.deb.sh | sudo bash
sudo apt-get install -y varnish-dev
- name: test-fmt
run: cargo fmt --all -- --check
- name: build
run: cargo build --workspace --all-targets
- name: test
run: cargo test --workspace --all-targets
- name: build-all
run: cargo build --workspace --all-targets --all-features
- name: test-all
run: cargo test --workspace --all-targets --all-features
- name: test-doc
run: |
cargo test --doc
cargo doc --no-deps
- name: clippy
run: cargo clippy --workspace --all-targets
# Ensure that the docs can be built at docs.rs without varnish dependencies
test-docs-rs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: rust-info
run: rustc --version && cargo --version
- uses: Swatinem/rust-cache@v2
if: github.event_name != 'release' && github.event_name != 'workflow_dispatch'
- name: Ensure docs can be built at docs.rs without varnish dependencies
run: cargo doc --no-deps