Initial version of CI/CD #9
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Rust | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
container: | |
image: rust:1.81-alpine3.20 | |
steps: | |
- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 #v4.2.0 | |
- name: Install deps | |
run: | | |
apk add --no-cache pcsc-lite-libs # For pcsc dependency | |
apk add --no-cache musl-dev # For tracing-attributes dependency (needs crti.o) | |
apk add --no-cache pkgconf openssl-dev gcc make perl-dev # For openssl dependency (see https://github.com/Fethbita/emrtd/pull/3) | |
- name: Build | |
run: cargo build --verbose | |
- name: Run tests | |
run: cargo test --all-features --verbose | |
- name: Audit | |
run: | | |
cargo install --version 0.20.1 cargo-audit | |
cargo audit | |
- name: Lint | |
run: cargo clippy -- -D warnings | |
- name: Build release | |
run: cargo build --release --verbose |