mirror of
https://github.com/uutils/coreutils.git
synced 2026-06-10 15:48:22 -07:00
Consolidate lint management with workspaces
At the moment, most crates rely on build scripts and other methods to keep lint-consistency. As of recent, Rust can use workspaces to globally set all the lint configurations. This PR only adds lint configuration to each crate, but it does not introduce any changes to the code or lint configuration. In the subsequent PRs, I plan to gradually move lints from `uucore` to workspace, making all code consistent. Note that `seq` relies on a custom lint config - which means its configuration may need to be managed by hand until Cargo introduces per-crate overrides.
This commit is contained in:
+10
@@ -584,3 +584,13 @@ manual_let_else = "warn"
|
||||
all = { level = "deny", priority = -1 }
|
||||
cargo = { level = "warn", priority = -1 }
|
||||
pedantic = { level = "deny", priority = -1 }
|
||||
|
||||
# This is the linting configuration for all crates.
|
||||
# Eventually the clippy settings from the `[lints]` section should be moved here.
|
||||
# In order to use these, all crates have `[lints] workspace = true` section.
|
||||
[workspace.lints.rust]
|
||||
# unused_qualifications = "warn"
|
||||
|
||||
[workspace.lints.clippy]
|
||||
all = { level = "deny", priority = -1 }
|
||||
#cargo = { level = "warn", priority = -1 }
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/arch.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/base32.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/base64.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/basename.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/basenc.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/cat.rs"
|
||||
|
||||
|
||||
@@ -12,6 +12,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/chcon.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/chgrp.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/chmod.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/chown.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/chroot.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/cksum.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/comm.rs"
|
||||
|
||||
|
||||
@@ -17,6 +17,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/cp.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/csplit.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/cut.rs"
|
||||
|
||||
|
||||
@@ -14,6 +14,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/date.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/dd.rs"
|
||||
|
||||
|
||||
@@ -13,6 +13,9 @@ edition = "2024"
|
||||
|
||||
readme.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
[lib]
|
||||
path = "src/df.rs"
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user