feat: Add Readme examples (#45) #80
This file contains hidden or 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: Build, Lint, Test | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| jobs: | |
| build-test-lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup Rust | |
| run: | | |
| rustup toolchain install stable | |
| rustup default stable | |
| # Needed for the tests | |
| - name: Set git username | |
| run: git config --global user.name ${{ github.repository_owner}} | |
| - name: Check dependencies | |
| uses: EmbarkStudios/cargo-deny-action@v2 | |
| - name: Install dependencies | |
| run: cargo build --verbose | |
| - name: Run Clippy (Linting) | |
| run: cargo clippy -- -D warnings | |
| - name: Check formatting | |
| run: cargo fmt -- --check | |
| - name: Run tests | |
| run: cargo test --verbose |