mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 10:31:03 +00:00
66 lines
1.8 KiB
YAML
66 lines
1.8 KiB
YAML
name: Check style
|
|
|
|
on:
|
|
pull_request:
|
|
push:
|
|
branches:
|
|
- master
|
|
tags:
|
|
- v*
|
|
paths-ignore:
|
|
- '**.md'
|
|
- diagrams/*
|
|
- docs/*
|
|
schedule: # Weekly build
|
|
- cron: '0 0 * * 0'
|
|
jobs:
|
|
## Check stage
|
|
check-fmt:
|
|
name: Check RustFmt
|
|
runs-on: ubuntu-latest
|
|
env:
|
|
RUST_BACKTRACE: full
|
|
steps:
|
|
|
|
- name: Cancel Previous Runs
|
|
uses: styfle/cancel-workflow-action@0.4.1
|
|
with:
|
|
access_token: ${{ github.token }}
|
|
|
|
- name: Checkout sources & submodules
|
|
uses: actions/checkout@master
|
|
with:
|
|
fetch-depth: 5
|
|
submodules: recursive
|
|
|
|
- name: Add rustfmt
|
|
run: rustup component add rustfmt
|
|
|
|
- name: rust-fmt check
|
|
uses: actions-rs/cargo@master
|
|
with:
|
|
command: fmt
|
|
args: --all -- --check
|
|
check-spellcheck:
|
|
name: Check For Spelling and/or Grammar Mistakes
|
|
runs-on: ubuntu-latest
|
|
env:
|
|
RUST_BACKTRACE: full
|
|
steps:
|
|
- name: Cancel Previous Runs
|
|
uses: styfle/cancel-workflow-action@0.4.1
|
|
with:
|
|
access_token: ${{ github.token }}
|
|
|
|
- name: Checkout sources & submodules
|
|
uses: actions/checkout@master
|
|
with:
|
|
fetch-depth: 5
|
|
submodules: recursive
|
|
|
|
- name: Add cargo-spellcheck
|
|
run: cargo install cargo-spellcheck
|
|
|
|
- name: Run spellcheck
|
|
run: cargo spellcheck check -m 1 -vv $(find modules/currency-exchange/src -name "*.rs")
|