Skip to content

Commit

Permalink
ci: allow some nightly lints
Browse files Browse the repository at this point in the history
  • Loading branch information
xJonathanLEI committed Apr 29, 2024
1 parent f33d352 commit 5528f94
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
14 changes: 11 additions & 3 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,19 @@ jobs:
components: "clippy"
override: true

- name: "Set allowed lints"
run: |
if [ "${{ matrix.toolchain }}" == "nightly" ] then
echo "ALLOWED=-A non_local_definitions" >> $GITHUB_ENV
else
echo "ALLOWED=" >> $GITHUB_ENV
fi
- name: "Run Clippy (default)"
run: |
cargo clippy --all --all-targets -- -D warnings
cargo clippy --all --all-targets -- -D warnings $ALLOWED
- name: "Run Clippy (no_std)"
run: |
cargo clippy --package starknet-crypto --no-default-features -- -D warnings
cargo clippy --package starknet-crypto --no-default-features --features alloc -- -D warnings
cargo clippy --package starknet-crypto --no-default-features -- -D warnings $ALLOWED
cargo clippy --package starknet-crypto --no-default-features --features alloc -- -D warnings $ALLOWED
2 changes: 0 additions & 2 deletions starknet-crypto/src/test_utils.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#![cfg(test)]

use crate::FieldElement;

pub fn field_element_from_be_hex(hex: &str) -> FieldElement {
Expand Down

0 comments on commit 5528f94

Please sign in to comment.