ci back
This commit is contained in:
parent
f4ee184734
commit
4c51adb903
3 changed files with 106 additions and 15 deletions
58
.github/workflows/release.yaml
vendored
Normal file
58
.github/workflows/release.yaml
vendored
Normal file
|
@ -0,0 +1,58 @@
|
|||
name: CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- 'main'
|
||||
- 'feat/*'
|
||||
pull_request:
|
||||
branches:
|
||||
- 'main'
|
||||
- 'feat/*'
|
||||
|
||||
env:
|
||||
CARGO_TERM_COLOR: always
|
||||
|
||||
jobs:
|
||||
{%- if ci-tests %}
|
||||
test:
|
||||
name: Tests
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v4
|
||||
- name: Install toolchain
|
||||
uses: dtolnay/rust-toolchain@nightly
|
||||
- name: Run cargo test
|
||||
run: cargo test
|
||||
{%- endif %}
|
||||
{% if ci-clippy %}
|
||||
clippy_check:
|
||||
name: Clippy
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 30
|
||||
steps:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v4
|
||||
- name: Install toolchain
|
||||
uses: dtolnay/rust-toolchain@nightly
|
||||
with:
|
||||
components: clippy
|
||||
- name: Run clippy
|
||||
run: cargo clippy -- -D warnings
|
||||
{%- endif %}
|
||||
{% if ci-fmt %}
|
||||
format:
|
||||
name: Format
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 30
|
||||
steps:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v4
|
||||
- name: Install toolchain
|
||||
uses: dtolnay/rust-toolchain@nightly
|
||||
with:
|
||||
components: rustfmt
|
||||
- name: Run cargo fmt
|
||||
run: cargo fmt --all -- --check
|
||||
{%- endif -%}
|
Loading…
Add table
Add a link
Reference in a new issue