Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions .github/workflows/smoke-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,15 @@ jobs:
grep -Eq '^/contracts/lending/\s+@MettaChain/lending$' .github/CODEOWNERS
grep -Eq '^/contracts/oracle/\s+@MettaChain/oracle$' .github/CODEOWNERS

- name: Install Stable Rust Toolchain
- name: Install Nightly Rust Toolchain (for fmt)
uses: dtolnay/rust-toolchain@nightly
with:
components: rustfmt

- name: Install Stable Rust Toolchain (for clippy & test)
uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt, clippy
components: clippy

- name: Cache Cargo Build Artifacts
uses: actions/cache@v4
Expand All @@ -44,8 +49,8 @@ jobs:
restore-keys: |
${{ runner.os }}-cargo-smoke-

- name: Check Code Formatting Style (fmt)
run: cargo fmt --check
- name: Check Code Formatting Style (nightly fmt)
run: cargo +nightly fmt --check

- name: Execute Static Analysis Compiler Lints (clippy)
run: cargo clippy --all-targets --all-features -- -D warnings
Expand Down
8 changes: 8 additions & 0 deletions rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Pins the nightly toolchain so that `format_macro_matchers` and other
# nightly-only rustfmt options work consistently across all contributors
# and in CI. The `rustfmt` component is listed explicitly so that
# `cargo fmt` resolves to the nightly formatter regardless of any system
# default.
[toolchain]
channel = "nightly"
components = ["rustfmt", "clippy"]
Loading