Skip to content

E: dynamically set release version using major & minor from Cargo.tom… #4

E: dynamically set release version using major & minor from Cargo.tom…

E: dynamically set release version using major & minor from Cargo.tom… #4

Workflow file for this run

name: build
on:
push:
branches:
- main
paths:
- 'src/**'
- 'Cargo.toml'
- 'Cargo.lock'
- '!**.md'
pull_request:
paths:
- 'src/**'
- 'Cargo.toml'
- 'Cargo.lock'
- '!**.md'
env:
TZ: Europe/Zurich
CARGO_TERM_COLOR: always
jobs:
build-and-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
components: rustfmt, clippy
target: x86_64-unknown-linux-musl
- uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- run: curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
- run: cargo binstall -y cross
- run: cargo clippy
- name: run the security audit check
run: cargo audit
- name: run the tests for x86_64 target
run: cross test --target x86_64-unknown-linux-musl
- name: run cargo clean
run: cargo clean
- name: run the test for arm64 target
run: cross test --target aarch64-unknown-linux-musl