mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Mergeruff.toml
into pyproject.toml
(#37741)
add a pyproject.toml config file that includes the settings for ruff --------- Signed-off-by: Jerens Lensun <jerensslensun@gmail.com>
This commit is contained in:
parent
b9347bf302
commit
5eb7c397fe
5 changed files with 6 additions and 7 deletions
|
@ -87,7 +87,7 @@ impl phf_shared::PhfHash for Bytes<'_> {
|
|||
/// Note: This function should be kept in sync with the version in `components/script/build.rs`
|
||||
fn find_python() -> Command {
|
||||
let mut command = Command::new("uv");
|
||||
command.args(["run", "python"]);
|
||||
command.args(["run", "--no-project", "python"]);
|
||||
|
||||
if command.output().is_ok_and(|out| out.status.success()) {
|
||||
return command;
|
||||
|
|
|
@ -34,7 +34,7 @@ fn main() {
|
|||
/// Note: This function should be kept in sync with the version in `components/script/build.rs`
|
||||
fn find_python() -> Command {
|
||||
let mut command = Command::new("uv");
|
||||
command.args(["run", "python"]);
|
||||
command.args(["run", "--no-project", "python"]);
|
||||
|
||||
if command.output().is_ok_and(|out| out.status.success()) {
|
||||
return command;
|
||||
|
|
2
mach
2
mach
|
@ -30,7 +30,7 @@
|
|||
fi
|
||||
}
|
||||
|
||||
run_in_nix_if_needed uv run python ${MACH_DIR}/mach "$@"
|
||||
run_in_nix_if_needed uv run --no-project python ${MACH_DIR}/mach "$@"
|
||||
}
|
||||
'''
|
||||
|
||||
|
|
2
mach.bat
2
mach.bat
|
@ -1,4 +1,4 @@
|
|||
@echo off
|
||||
|
||||
set workdir=%~dp0
|
||||
uv run python %workdir%mach %*
|
||||
uv run --no-project python %workdir%mach %*
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
[tool.ruff]
|
||||
line-length = 120
|
||||
|
||||
extend-exclude = [
|
||||
# temporary local files
|
||||
"target/**",
|
||||
|
@ -12,13 +12,12 @@ extend-exclude = [
|
|||
"tests/**",
|
||||
]
|
||||
|
||||
[lint]
|
||||
[tool.ruff.lint]
|
||||
select = [
|
||||
"E",
|
||||
"W",
|
||||
"F",
|
||||
]
|
||||
|
||||
ignore = [
|
||||
# Trailing whitespace; the standard tidy process will enforce no trailing whitespace
|
||||
"W291",
|
Loading…
Add table
Add a link
Reference in a new issue