Skip to content

Commit

Permalink
Merge pull request #1 from jbovet/add-actions-for-pr
Browse files Browse the repository at this point in the history
add basic rust github action
  • Loading branch information
jbovet authored May 30, 2024
2 parents 6385382 + 690477f commit 7c953f4
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Rust

on:
push:
branches:
- main
pull_request:
types:
- opened
- synchronize
- reopened
branches:
- main

env:
CARGO_TERM_COLOR: always

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Setup cache
uses: Swatinem/rust-cache@v2

- name: Build
run: cargo build --verbose

- name: Run all workspace tests
run: cargo test --workspace --verbose

lint:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Check formats
run: cargo fmt --check

- name: Setup cache
uses: Swatinem/rust-cache@v2

- name: Check code quality
run: cargo clippy -- -D warnings

0 comments on commit 7c953f4

Please sign in to comment.