Skip to content

another try

another try #845

Workflow file for this run

on: [push, pull_request]
name: ci
env:
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
RUSTUP_MAX_RETRIES: 10
jobs:
rustfmt:
name: rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@v1
with:
toolchain: stable
components: rustfmt
- run: cargo fmt -- --check
# clippy:
# name: clippy
# runs-on: ubuntu-latest
# steps:
# - name: system dependencies
# run: sudo apt-get update && sudo apt-get install -y protobuf-compiler
# - uses: actions/checkout@v4
# - uses: dtolnay/rust-toolchain@v1
# with:
# toolchain: stable
# components: clippy
# - run: cargo clippy --locked
# build-gnu:
# strategy:
# matrix:
# target:
# - x86_64-unknown-linux-gnu
# - aarch64-unknown-linux-gnu
# runs-on: ubuntu-latest
# steps:
# - name: system dependencies
# run: sudo apt-get update && sudo apt-get install -y protobuf-compiler gcc-aarch64-linux-gnu
# - uses: actions/checkout@v4
# - uses: dtolnay/rust-toolchain@v1
# with:
# toolchain: stable
# targets: ${{ matrix.target }}
# - run: cargo build --target ${{ matrix.target }}
# - run: cargo test
# if: ${{ matrix.target == 'x86_64-unknown-linux-gnu' }}
# - run: cargo xtask --help
# if: ${{ matrix.target == 'x86_64-unknown-linux-gnu' }}
build-musl:
strategy:
fail-fast: false
matrix:
target:
- x86_64-unknown-linux-musl
# - aarch64-unknown-linux-musl
runs-on: ubuntu-latest
container:
image: rust:alpine
volumes:
- /usr/local/cargo/registry
steps:
- name: system dependencies
run: apk add --no-cache musl-dev lld protoc bash clang llvm
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@v1
with:
toolchain: stable
targets: ${{ matrix.target }}
- uses: Swatinem/rust-cache@v2
# - run: cargo build --target ${{ matrix.target }}
# - run: cargo test --target ${{ matrix.target }}
# if: ${{ matrix.target == 'x86_64-unknown-linux-musl' }}
- run: cargo run -p xtask --target ${{ matrix.target }} -- --help
if: ${{ matrix.target == 'x86_64-unknown-linux-musl' }}
# build-apple:
# strategy:
# matrix:
# target:
# - x86_64-apple-darwin
# - aarch64-apple-darwin
# runs-on: macos-latest
# env:
# SELECT_XCODE: /Applications/Xcode_13.2.app
# steps:
# - name: xcode
# run: sudo xcode-select -s "${SELECT_XCODE}"
# - uses: actions/checkout@v4
# - uses: dtolnay/rust-toolchain@v1
# with:
# toolchain: stable
# targets: ${{ matrix.target }}
# - run: cargo build --target ${{ matrix.target }}
# - run: cargo test
# if: ${{ matrix.target == 'x86_64-apple-darwin' }}
# - run: cargo xtask --help
# if: ${{ matrix.target == 'x86_64-apple-darwin' }}