Skip to content

Crate checks

Crate checks #2048

Workflow file for this run

name: Crate checks
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
merge_group:
types: [ "checks_requested" ]
jobs:
verify-crate:
name: Verify crate
runs-on: ubuntu-22.04
strategy:
matrix:
crate:
- mountpoint-s3-crt-sys
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
submodules: true
- name: Set up Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
# setup-rust-toolchain sets "-D warnings" by default, and Rust treats any warning as compile error.
# We need to this currently because `vendor/fuser` contains some warnings and it breaks the build.
rustflags: ""
- name: Package ${{ matrix.crate }} crate
# `--no-verify` avoids building using crates.io dependencies, which for local packages may not be updated yet
run: cargo package -p ${{ matrix.crate }} --no-verify
- name: Verify compressed crate size is smaller than crates.io limit
run: |
ls -alh target/package/*.crate
test `cat target/package/*.crate | wc -c` -le 10485760