Skip to content

Update rust.yml

Update rust.yml #13

Workflow file for this run

name: Rust
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: ubuntu-latest
container:
image: ubuntu:22.04
steps:
- name: Install packages
run: |
apt-get update && apt-get install -y curl \
wget unzip pkg-config libssl-dev cmake build-essential
- uses: actions/checkout@v4
- name: Install rust toolchain
uses: dtolnay/rust-toolchain@v1
with:
toolchain: stable
components: rustfmt, clippy
- name: Install protoc
run: |
PROTOC_VERSION=27.2
PROTOC_ZIP=protoc-$PROTOC_VERSION-linux-x86_64.zip
wget https://github.com/protocolbuffers/protobuf/releases/download/v$PROTOC_VERSION/$PROTOC_ZIP
unzip -o $PROTOC_ZIP -d /usr/local bin/protoc
unzip -o $PROTOC_ZIP -d /usr/local 'include/*'
- name: Run clippy
run: cargo clippy
- name: Build tomis
run: cargo build
- name: Run tests
run: cargo test