unify workflows

This commit is contained in:
Jonas Kruckenberg
2022-12-14 20:36:30 +01:00
parent fb9f79dee1
commit 9a1fa9acbc
2 changed files with 19 additions and 42 deletions
-41
View File
@@ -1,41 +0,0 @@
name: Format Rust
on:
push:
branches:
- dev
paths:
- '.github/workflows/format-rust.yml'
- 'plugins/src/**'
- "**/Cargo.toml"
pull_request:
branches:
- dev
paths:
- '.github/workflows/format-rust.yml'
- 'plugins/src/**'
- "**/Cargo.toml"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
format:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v3
- name: Install rustfmt with nightly toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
override: true
components: rustfmt
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
+19 -1
View File
@@ -44,4 +44,22 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --all --all-targets --all-features -- -D warnings
name: clippy
name: clippy
fmt:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v3
- name: Install rustfmt with nightly toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
override: true
components: rustfmt
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check