This repository has been archived on 2024-10-16. You can view files and clone it, but cannot push or open issues or pull requests.
pt/.gitea/workflows/cargo.yaml
PlexSheep 6dcc45d722
Some checks failed
Cargo Format, Check and Test / cargo fmt (push) Successful in 1m0s
Cargo Format, Check and Test / cargo check (push) Successful in 1m20s
Cargo Format, Check and Test / cargo test (push) Failing after 1m16s
remove trailing whitespaces
2024-01-10 21:45:40 +01:00

32 lines
986 B
YAML

name: Cargo Format, Check and Test
on: [push, pull_request]
jobs:
format:
name: cargo fmt
permissions:
# Give the default GITHUB_TOKEN write permission to commit and push the
# added or changed files to the repository.
contents: write
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: rustup component add rustfmt
- run: cargo fmt
- uses: stefanzweifel/git-auto-commit-action@v5
with:
# Optional. Commit message for the created commit.
# Defaults to "Apply automatic changes"
commit_message: Automatical formatting
check:
name: cargo check
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: cargo check --all-features --verbose
test:
name: cargo test
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: cargo test --all-features --verbose