-
-
Notifications
You must be signed in to change notification settings - Fork 92
37 lines (29 loc) · 1005 Bytes
/
check.yaml
File metadata and controls
37 lines (29 loc) · 1005 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: "Check formating & lints"
on:
workflow_dispatch:
pull_request:
branches: [ "main" ]
push:
branches-ignore:
- 'update-*'
jobs:
treewide-checks:
runs-on: ubuntu-latest
steps:
- uses: cachix/install-nix-action@master
with:
github_access_token: ${{ secrets.GITHUB_TOKEN }}
- name: Checkout repository
uses: actions/checkout@v4
# Unlike the clippy lints below, this should always pass.
- name: Check Formatting
run: |
# Run cargo fmt in check mode
cargo fmt --check
# We run clippy with lints that help avoid overall low-quality code or what is called "code smell."
# Stylistic lints (e.g., clippy::style and clippy::complexity) are avoided but it is a good idea to
# follow those while working on the codebase.
- name: Clippy Lints
run: |
# Lint Changes
cargo clippy -- -W clippy::pedantic -W clippy::correctness -W clippy::suspicious