Skip to content

Rust: strengthen linting script#18822

Merged
redsun82 merged 1 commit intomainfrom
redsun82/rust-lint
Feb 24, 2025
Merged

Rust: strengthen linting script#18822
redsun82 merged 1 commit intomainfrom
redsun82/rust-lint

Conversation

@redsun82
Copy link
Contributor

  • bazel run //rust/ast-generator:inject-sources could fail on macOS if a non-coreutils cp was used
  • that is now also run by lint.py to ensure the sources cargo needs are present

* `bazel run //rust/ast-generator:inject-sources` could fail on macOS
  if a non-coreutils `cp` was used
* that is now also run by `lint.py` to ensure the sources cargo needs
  are present
Copilot AI review requested due to automatic review settings February 20, 2025 09:41
@github-actions github-actions bot added the Rust Pull requests that update Rust code label Feb 20, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Overview

This PR strengthens the linting script to ensure that required binaries are present and the necessary source injections are performed for Rust projects.

  • Refactors binary detection using a helper function.
  • Introduces a uniform run function to execute commands and log their calls.
  • Integrates bazel source injection alongside cargo formatting and clippy corrections.

Reviewed Changes

File Description
rust/lint.py Improved binary detection, command execution, and source injection.

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

Tip: If you use Visual Studio Code, you can request a review from Copilot before you push from the "Source Control" tab. Learn more

Copy link
Contributor

@aibaars aibaars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

@redsun82 redsun82 merged commit 81b6848 into main Feb 24, 2025
13 checks passed
@redsun82 redsun82 deleted the redsun82/rust-lint branch February 24, 2025 11:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Rust Pull requests that update Rust code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants