Fix YAML syntax error in release workflow #4
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: CI | |
on: | |
push: | |
branches: [ main, develop ] | |
pull_request: | |
branches: [ main ] | |
env: | |
CARGO_TERM_COLOR: always | |
RUST_BACKTRACE: 1 | |
jobs: | |
test: | |
name: Test | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
components: rustfmt, clippy | |
- name: Cache cargo | |
uses: actions/cache@v3 | |
with: | |
path: | | |
~/.cargo/registry | |
~/.cargo/git | |
target | |
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
restore-keys: | | |
${{ runner.os }}-cargo- | |
- name: Check formatting | |
run: cargo fmt --all -- --check | |
- name: Run clippy | |
run: cargo clippy --all-features --all-targets -- -D warnings | |
- name: Run tests | |
run: cargo test --all-features --all-targets | |
- name: Build all binaries | |
run: | | |
cargo build --all-features --package blg | |
cargo build --all-features --package mcp-backlog-server | |
- name: Check documentation | |
run: cargo doc --all-features --no-deps | |
test-minimal: | |
name: Test Minimal Features | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@stable | |
- name: Test with minimal features | |
run: | | |
cargo test --package backlog-api-client --no-default-features | |
cargo test --package blg --no-default-features | |
coverage: | |
name: Code Coverage | |
runs-on: ubuntu-latest | |
if: github.event_name == 'pull_request' | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@stable | |
- name: Install tarpaulin | |
run: cargo install cargo-tarpaulin | |
- name: Generate coverage | |
run: cargo tarpaulin --all-features --out xml | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
files: ./cobertura.xml | |
fail_ci_if_error: false |