-
Notifications
You must be signed in to change notification settings - Fork 100
Code Cleanup #950
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Code Cleanup #950
Changes from all commits
4435e9e
a3a4124
a6b3df0
656afb2
ebeee21
177c94c
33c1f85
61a6c61
ab4ca41
fa305ae
2918cb0
3cea721
39a0d5e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,8 +1,7 @@ | ||
| on: | ||
| push: | ||
| branches: | ||
| - master | ||
| - the-merge | ||
| - main | ||
| pull_request: | ||
| name: Contracts (NEAR) | ||
| jobs: | ||
|
|
||
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| name: Rust Linting | ||
|
|
||
| on: | ||
| push: | ||
| branches: [ main ] | ||
| paths: | ||
| - 'eth2near/**' | ||
| pull_request: | ||
| branches: [ main ] | ||
| paths: | ||
| - 'eth2near/**' | ||
|
|
||
| env: | ||
| CARGO_TERM_COLOR: always | ||
|
|
||
| jobs: | ||
| lint: | ||
| runs-on: ubuntu-latest | ||
| defaults: | ||
| run: | ||
| working-directory: ./eth2near | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up Rust | ||
| uses: dtolnay/rust-toolchain@stable | ||
| with: | ||
| toolchain: 1.86.0 | ||
| components: clippy, rustfmt | ||
| target: wasm32-unknown-unknown | ||
|
|
||
| - name: Cache Rust dependencies | ||
| uses: Swatinem/rust-cache@v2 | ||
| with: | ||
| workspaces: | | ||
| ./eth2near | ||
| cache-on-failure: true | ||
| cache-all-crates: true | ||
|
|
||
| - name: Run linters | ||
| run: cargo clippy --all-targets --all-features -- -D warnings -D clippy::all | ||
| - name: Check formatting | ||
| run: cargo fmt --all -- --check | ||
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium
Copilot Autofix
AI 11 months ago
To fix the issue, we will add a
permissionsblock at the root level of the workflow file. This block will explicitly set the permissions tocontents: read, which is sufficient for the linting job since it only needs to read the repository's contents. This change ensures that the workflow adheres to the principle of least privilege and avoids granting unnecessary permissions.