[flake8-executable] Add pytest and uv run to help message for shebang-missing-python (EXE003) (#16855)
Followup to #16849 per https://github.com/astral-sh/ruff/pull/16849#issuecomment-2737316564
This commit is contained in:
@@ -36,7 +36,7 @@ pub(crate) struct ShebangMissingPython;
|
||||
impl Violation for ShebangMissingPython {
|
||||
#[derive_message_formats]
|
||||
fn message(&self) -> String {
|
||||
"Shebang should contain `python`".to_string()
|
||||
"Shebang should contain `python`, `pytest`, or `uv run`".to_string()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
---
|
||||
source: crates/ruff_linter/src/rules/flake8_executable/mod.rs
|
||||
---
|
||||
EXE003.py:1:1: EXE003 Shebang should contain `python`
|
||||
EXE003.py:1:1: EXE003 Shebang should contain `python`, `pytest`, or `uv run`
|
||||
|
|
||||
1 | #!/usr/bin/bash
|
||||
| ^^^^^^^^^^^^^^^ EXE003
|
||||
2 | print("hello world")
|
||||
|
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user