From 2413dc91684347de7f3527fbaf41bcdc118e78bc Mon Sep 17 00:00:00 2001 From: Yuri Astrakhan Date: Wed, 9 Apr 2025 03:12:36 -0400 Subject: [PATCH] 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. --- Cargo.toml | 10 ++++++++++ src/uu/arch/Cargo.toml | 3 +++ src/uu/base32/Cargo.toml | 3 +++ src/uu/base64/Cargo.toml | 3 +++ src/uu/basename/Cargo.toml | 3 +++ src/uu/basenc/Cargo.toml | 3 +++ src/uu/cat/Cargo.toml | 3 +++ src/uu/chcon/Cargo.toml | 3 +++ src/uu/chgrp/Cargo.toml | 3 +++ src/uu/chmod/Cargo.toml | 3 +++ src/uu/chown/Cargo.toml | 3 +++ src/uu/chroot/Cargo.toml | 3 +++ src/uu/cksum/Cargo.toml | 3 +++ src/uu/comm/Cargo.toml | 3 +++ src/uu/cp/Cargo.toml | 3 +++ src/uu/csplit/Cargo.toml | 3 +++ src/uu/cut/Cargo.toml | 3 +++ src/uu/date/Cargo.toml | 3 +++ src/uu/dd/Cargo.toml | 3 +++ src/uu/df/Cargo.toml | 3 +++ src/uu/dir/Cargo.toml | 3 +++ src/uu/dircolors/Cargo.toml | 3 +++ src/uu/dirname/Cargo.toml | 3 +++ src/uu/du/Cargo.toml | 3 +++ src/uu/echo/Cargo.toml | 3 +++ src/uu/env/Cargo.toml | 3 +++ src/uu/expand/Cargo.toml | 3 +++ src/uu/expr/Cargo.toml | 3 +++ src/uu/factor/Cargo.toml | 3 +++ src/uu/false/Cargo.toml | 3 +++ src/uu/fmt/Cargo.toml | 3 +++ src/uu/fold/Cargo.toml | 3 +++ src/uu/groups/Cargo.toml | 3 +++ src/uu/hashsum/Cargo.toml | 3 +++ src/uu/head/Cargo.toml | 3 +++ src/uu/hostid/Cargo.toml | 3 +++ src/uu/hostname/Cargo.toml | 3 +++ src/uu/id/Cargo.toml | 3 +++ src/uu/install/Cargo.toml | 3 +++ src/uu/join/Cargo.toml | 3 +++ src/uu/kill/Cargo.toml | 3 +++ src/uu/link/Cargo.toml | 3 +++ src/uu/ln/Cargo.toml | 3 +++ src/uu/logname/Cargo.toml | 3 +++ src/uu/ls/Cargo.toml | 3 +++ src/uu/mkdir/Cargo.toml | 3 +++ src/uu/mkfifo/Cargo.toml | 3 +++ src/uu/mknod/Cargo.toml | 3 +++ src/uu/mktemp/Cargo.toml | 3 +++ src/uu/more/Cargo.toml | 3 +++ src/uu/mv/Cargo.toml | 3 +++ src/uu/nice/Cargo.toml | 3 +++ src/uu/nl/Cargo.toml | 3 +++ src/uu/nohup/Cargo.toml | 3 +++ src/uu/nproc/Cargo.toml | 3 +++ src/uu/numfmt/Cargo.toml | 3 +++ src/uu/od/Cargo.toml | 3 +++ src/uu/paste/Cargo.toml | 3 +++ src/uu/pathchk/Cargo.toml | 3 +++ src/uu/pinky/Cargo.toml | 3 +++ src/uu/pr/Cargo.toml | 3 +++ src/uu/printenv/Cargo.toml | 3 +++ src/uu/printf/Cargo.toml | 3 +++ src/uu/ptx/Cargo.toml | 3 +++ src/uu/pwd/Cargo.toml | 3 +++ src/uu/readlink/Cargo.toml | 3 +++ src/uu/realpath/Cargo.toml | 3 +++ src/uu/rm/Cargo.toml | 3 +++ src/uu/rmdir/Cargo.toml | 3 +++ src/uu/runcon/Cargo.toml | 3 +++ src/uu/seq/Cargo.toml | 5 +++++ src/uu/shred/Cargo.toml | 3 +++ src/uu/shuf/Cargo.toml | 3 +++ src/uu/sleep/Cargo.toml | 3 +++ src/uu/sort/Cargo.toml | 3 +++ src/uu/split/Cargo.toml | 3 +++ src/uu/stat/Cargo.toml | 3 +++ src/uu/stdbuf/Cargo.toml | 3 +++ src/uu/stty/Cargo.toml | 3 +++ src/uu/sum/Cargo.toml | 3 +++ src/uu/sync/Cargo.toml | 3 +++ src/uu/tac/Cargo.toml | 3 +++ src/uu/tail/Cargo.toml | 3 +++ src/uu/tee/Cargo.toml | 3 +++ src/uu/test/Cargo.toml | 3 +++ src/uu/timeout/Cargo.toml | 3 +++ src/uu/touch/Cargo.toml | 3 +++ src/uu/tr/Cargo.toml | 3 +++ src/uu/true/Cargo.toml | 3 +++ src/uu/truncate/Cargo.toml | 3 +++ src/uu/tsort/Cargo.toml | 3 +++ src/uu/tty/Cargo.toml | 3 +++ src/uu/uname/Cargo.toml | 3 +++ src/uu/unexpand/Cargo.toml | 3 +++ src/uu/uniq/Cargo.toml | 3 +++ src/uu/unlink/Cargo.toml | 3 +++ src/uu/uptime/Cargo.toml | 3 +++ src/uu/users/Cargo.toml | 3 +++ src/uu/vdir/Cargo.toml | 3 +++ src/uu/wc/Cargo.toml | 3 +++ src/uu/who/Cargo.toml | 3 +++ src/uu/whoami/Cargo.toml | 3 +++ src/uu/yes/Cargo.toml | 3 +++ 103 files changed, 318 insertions(+) diff --git a/Cargo.toml b/Cargo.toml index 85525c9b7..c12b1edb1 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -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 } diff --git a/src/uu/arch/Cargo.toml b/src/uu/arch/Cargo.toml index 736e12d01..b7ca5c79c 100644 --- a/src/uu/arch/Cargo.toml +++ b/src/uu/arch/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/arch.rs" diff --git a/src/uu/base32/Cargo.toml b/src/uu/base32/Cargo.toml index 96c60ac9e..a85fc0749 100644 --- a/src/uu/base32/Cargo.toml +++ b/src/uu/base32/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/base32.rs" diff --git a/src/uu/base64/Cargo.toml b/src/uu/base64/Cargo.toml index 9ebc6b508..1e1d81a04 100644 --- a/src/uu/base64/Cargo.toml +++ b/src/uu/base64/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/base64.rs" diff --git a/src/uu/basename/Cargo.toml b/src/uu/basename/Cargo.toml index d910d54d8..5d4c82282 100644 --- a/src/uu/basename/Cargo.toml +++ b/src/uu/basename/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/basename.rs" diff --git a/src/uu/basenc/Cargo.toml b/src/uu/basenc/Cargo.toml index 4fa6519ba..121fd290d 100644 --- a/src/uu/basenc/Cargo.toml +++ b/src/uu/basenc/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/basenc.rs" diff --git a/src/uu/cat/Cargo.toml b/src/uu/cat/Cargo.toml index 04a70c20f..ca75a9c39 100644 --- a/src/uu/cat/Cargo.toml +++ b/src/uu/cat/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/cat.rs" diff --git a/src/uu/chcon/Cargo.toml b/src/uu/chcon/Cargo.toml index 36eebf2dd..832f13450 100644 --- a/src/uu/chcon/Cargo.toml +++ b/src/uu/chcon/Cargo.toml @@ -12,6 +12,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/chcon.rs" diff --git a/src/uu/chgrp/Cargo.toml b/src/uu/chgrp/Cargo.toml index 118b0826c..ac59c42e3 100644 --- a/src/uu/chgrp/Cargo.toml +++ b/src/uu/chgrp/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/chgrp.rs" diff --git a/src/uu/chmod/Cargo.toml b/src/uu/chmod/Cargo.toml index 77f5746ed..eb4a2d864 100644 --- a/src/uu/chmod/Cargo.toml +++ b/src/uu/chmod/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/chmod.rs" diff --git a/src/uu/chown/Cargo.toml b/src/uu/chown/Cargo.toml index 890a12b9f..1faf6d2b5 100644 --- a/src/uu/chown/Cargo.toml +++ b/src/uu/chown/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/chown.rs" diff --git a/src/uu/chroot/Cargo.toml b/src/uu/chroot/Cargo.toml index 20fd98ee4..6d43041f2 100644 --- a/src/uu/chroot/Cargo.toml +++ b/src/uu/chroot/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/chroot.rs" diff --git a/src/uu/cksum/Cargo.toml b/src/uu/cksum/Cargo.toml index 46f6099fd..eade905a6 100644 --- a/src/uu/cksum/Cargo.toml +++ b/src/uu/cksum/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/cksum.rs" diff --git a/src/uu/comm/Cargo.toml b/src/uu/comm/Cargo.toml index 572a95c94..dd8a3a4d8 100644 --- a/src/uu/comm/Cargo.toml +++ b/src/uu/comm/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/comm.rs" diff --git a/src/uu/cp/Cargo.toml b/src/uu/cp/Cargo.toml index a6bab6ea8..f55a3a2b8 100644 --- a/src/uu/cp/Cargo.toml +++ b/src/uu/cp/Cargo.toml @@ -17,6 +17,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/cp.rs" diff --git a/src/uu/csplit/Cargo.toml b/src/uu/csplit/Cargo.toml index db752c1d8..70bdc05bf 100644 --- a/src/uu/csplit/Cargo.toml +++ b/src/uu/csplit/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/csplit.rs" diff --git a/src/uu/cut/Cargo.toml b/src/uu/cut/Cargo.toml index 9305028e2..f0d3a78d3 100644 --- a/src/uu/cut/Cargo.toml +++ b/src/uu/cut/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/cut.rs" diff --git a/src/uu/date/Cargo.toml b/src/uu/date/Cargo.toml index f9d96c605..dc1f71783 100644 --- a/src/uu/date/Cargo.toml +++ b/src/uu/date/Cargo.toml @@ -14,6 +14,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/date.rs" diff --git a/src/uu/dd/Cargo.toml b/src/uu/dd/Cargo.toml index 9a34631f2..422516b41 100644 --- a/src/uu/dd/Cargo.toml +++ b/src/uu/dd/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/dd.rs" diff --git a/src/uu/df/Cargo.toml b/src/uu/df/Cargo.toml index 61a7e8377..523723f70 100644 --- a/src/uu/df/Cargo.toml +++ b/src/uu/df/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/df.rs" diff --git a/src/uu/dir/Cargo.toml b/src/uu/dir/Cargo.toml index d7a463b77..d4a06a83a 100644 --- a/src/uu/dir/Cargo.toml +++ b/src/uu/dir/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/dir.rs" diff --git a/src/uu/dircolors/Cargo.toml b/src/uu/dircolors/Cargo.toml index ffa0ade1f..55ca7512b 100644 --- a/src/uu/dircolors/Cargo.toml +++ b/src/uu/dircolors/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/dircolors.rs" diff --git a/src/uu/dirname/Cargo.toml b/src/uu/dirname/Cargo.toml index b64492c6e..594a9acea 100644 --- a/src/uu/dirname/Cargo.toml +++ b/src/uu/dirname/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/dirname.rs" diff --git a/src/uu/du/Cargo.toml b/src/uu/du/Cargo.toml index 5bceda4b1..e8af6cc68 100644 --- a/src/uu/du/Cargo.toml +++ b/src/uu/du/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/du.rs" diff --git a/src/uu/echo/Cargo.toml b/src/uu/echo/Cargo.toml index e16d0c342..6c03e1477 100644 --- a/src/uu/echo/Cargo.toml +++ b/src/uu/echo/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/echo.rs" diff --git a/src/uu/env/Cargo.toml b/src/uu/env/Cargo.toml index f1a50b8b9..ae4fdc15d 100644 --- a/src/uu/env/Cargo.toml +++ b/src/uu/env/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/env.rs" diff --git a/src/uu/expand/Cargo.toml b/src/uu/expand/Cargo.toml index ad25d7dd6..c72fa6539 100644 --- a/src/uu/expand/Cargo.toml +++ b/src/uu/expand/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/expand.rs" diff --git a/src/uu/expr/Cargo.toml b/src/uu/expr/Cargo.toml index 1e947d0af..486a92454 100644 --- a/src/uu/expr/Cargo.toml +++ b/src/uu/expr/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/expr.rs" diff --git a/src/uu/factor/Cargo.toml b/src/uu/factor/Cargo.toml index 9488241e5..b3d5eb3a0 100644 --- a/src/uu/factor/Cargo.toml +++ b/src/uu/factor/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [build-dependencies] num-traits = { workspace = true } # used in src/numerics.rs, which is included by build.rs diff --git a/src/uu/false/Cargo.toml b/src/uu/false/Cargo.toml index 692e26045..c597a57be 100644 --- a/src/uu/false/Cargo.toml +++ b/src/uu/false/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/false.rs" diff --git a/src/uu/fmt/Cargo.toml b/src/uu/fmt/Cargo.toml index aca576b33..a95c3ab47 100644 --- a/src/uu/fmt/Cargo.toml +++ b/src/uu/fmt/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/fmt.rs" diff --git a/src/uu/fold/Cargo.toml b/src/uu/fold/Cargo.toml index e140830ab..f8480d821 100644 --- a/src/uu/fold/Cargo.toml +++ b/src/uu/fold/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/fold.rs" diff --git a/src/uu/groups/Cargo.toml b/src/uu/groups/Cargo.toml index 953096805..04a4e77fc 100644 --- a/src/uu/groups/Cargo.toml +++ b/src/uu/groups/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/groups.rs" diff --git a/src/uu/hashsum/Cargo.toml b/src/uu/hashsum/Cargo.toml index d3d8d27ea..04bf393db 100644 --- a/src/uu/hashsum/Cargo.toml +++ b/src/uu/hashsum/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/hashsum.rs" diff --git a/src/uu/head/Cargo.toml b/src/uu/head/Cargo.toml index d1fc4bc15..b23474831 100644 --- a/src/uu/head/Cargo.toml +++ b/src/uu/head/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/head.rs" diff --git a/src/uu/hostid/Cargo.toml b/src/uu/hostid/Cargo.toml index a1f0ad808..73828736e 100644 --- a/src/uu/hostid/Cargo.toml +++ b/src/uu/hostid/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/hostid.rs" diff --git a/src/uu/hostname/Cargo.toml b/src/uu/hostname/Cargo.toml index fe9d1c651..994a33b84 100644 --- a/src/uu/hostname/Cargo.toml +++ b/src/uu/hostname/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/hostname.rs" diff --git a/src/uu/id/Cargo.toml b/src/uu/id/Cargo.toml index 0163d10a2..2d8cbcd04 100644 --- a/src/uu/id/Cargo.toml +++ b/src/uu/id/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/id.rs" diff --git a/src/uu/install/Cargo.toml b/src/uu/install/Cargo.toml index 47da45d18..ac10818d9 100644 --- a/src/uu/install/Cargo.toml +++ b/src/uu/install/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/install.rs" diff --git a/src/uu/join/Cargo.toml b/src/uu/join/Cargo.toml index d8c4935ff..cfdeeda47 100644 --- a/src/uu/join/Cargo.toml +++ b/src/uu/join/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/join.rs" diff --git a/src/uu/kill/Cargo.toml b/src/uu/kill/Cargo.toml index 616293135..75203a359 100644 --- a/src/uu/kill/Cargo.toml +++ b/src/uu/kill/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/kill.rs" diff --git a/src/uu/link/Cargo.toml b/src/uu/link/Cargo.toml index 052bfdd8d..52dd99c5b 100644 --- a/src/uu/link/Cargo.toml +++ b/src/uu/link/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/link.rs" diff --git a/src/uu/ln/Cargo.toml b/src/uu/ln/Cargo.toml index 507a7f619..1906d58f2 100644 --- a/src/uu/ln/Cargo.toml +++ b/src/uu/ln/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/ln.rs" diff --git a/src/uu/logname/Cargo.toml b/src/uu/logname/Cargo.toml index 9b71c91e7..09463b803 100644 --- a/src/uu/logname/Cargo.toml +++ b/src/uu/logname/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/logname.rs" diff --git a/src/uu/ls/Cargo.toml b/src/uu/ls/Cargo.toml index e8f9a14ec..5edb0c713 100644 --- a/src/uu/ls/Cargo.toml +++ b/src/uu/ls/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/ls.rs" diff --git a/src/uu/mkdir/Cargo.toml b/src/uu/mkdir/Cargo.toml index dc8531d44..43ec6ba57 100644 --- a/src/uu/mkdir/Cargo.toml +++ b/src/uu/mkdir/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/mkdir.rs" diff --git a/src/uu/mkfifo/Cargo.toml b/src/uu/mkfifo/Cargo.toml index de134e68e..13b8b44f4 100644 --- a/src/uu/mkfifo/Cargo.toml +++ b/src/uu/mkfifo/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/mkfifo.rs" diff --git a/src/uu/mknod/Cargo.toml b/src/uu/mknod/Cargo.toml index a0f4e3866..a20c82bdb 100644 --- a/src/uu/mknod/Cargo.toml +++ b/src/uu/mknod/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] name = "uu_mknod" path = "src/mknod.rs" diff --git a/src/uu/mktemp/Cargo.toml b/src/uu/mktemp/Cargo.toml index a46ededb8..9ea77c544 100644 --- a/src/uu/mktemp/Cargo.toml +++ b/src/uu/mktemp/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/mktemp.rs" diff --git a/src/uu/more/Cargo.toml b/src/uu/more/Cargo.toml index 15967372d..9d4a40157 100644 --- a/src/uu/more/Cargo.toml +++ b/src/uu/more/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/more.rs" diff --git a/src/uu/mv/Cargo.toml b/src/uu/mv/Cargo.toml index f53b295e1..ae712d474 100644 --- a/src/uu/mv/Cargo.toml +++ b/src/uu/mv/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/mv.rs" diff --git a/src/uu/nice/Cargo.toml b/src/uu/nice/Cargo.toml index 693684536..9aa4e6028 100644 --- a/src/uu/nice/Cargo.toml +++ b/src/uu/nice/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/nice.rs" diff --git a/src/uu/nl/Cargo.toml b/src/uu/nl/Cargo.toml index 3db7f5758..4c8efb767 100644 --- a/src/uu/nl/Cargo.toml +++ b/src/uu/nl/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/nl.rs" diff --git a/src/uu/nohup/Cargo.toml b/src/uu/nohup/Cargo.toml index 72c0cd8f8..482b27a22 100644 --- a/src/uu/nohup/Cargo.toml +++ b/src/uu/nohup/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/nohup.rs" diff --git a/src/uu/nproc/Cargo.toml b/src/uu/nproc/Cargo.toml index 3f734b559..2e4a58dc4 100644 --- a/src/uu/nproc/Cargo.toml +++ b/src/uu/nproc/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/nproc.rs" diff --git a/src/uu/numfmt/Cargo.toml b/src/uu/numfmt/Cargo.toml index 0b121f1f6..1e01fef13 100644 --- a/src/uu/numfmt/Cargo.toml +++ b/src/uu/numfmt/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/numfmt.rs" diff --git a/src/uu/od/Cargo.toml b/src/uu/od/Cargo.toml index dcae75171..cb0a5075d 100644 --- a/src/uu/od/Cargo.toml +++ b/src/uu/od/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/od.rs" diff --git a/src/uu/paste/Cargo.toml b/src/uu/paste/Cargo.toml index 98ae07728..346741eb7 100644 --- a/src/uu/paste/Cargo.toml +++ b/src/uu/paste/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/paste.rs" diff --git a/src/uu/pathchk/Cargo.toml b/src/uu/pathchk/Cargo.toml index 4fe6946b8..08fab78d4 100644 --- a/src/uu/pathchk/Cargo.toml +++ b/src/uu/pathchk/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/pathchk.rs" diff --git a/src/uu/pinky/Cargo.toml b/src/uu/pinky/Cargo.toml index 89c780bad..004218266 100644 --- a/src/uu/pinky/Cargo.toml +++ b/src/uu/pinky/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/pinky.rs" diff --git a/src/uu/pr/Cargo.toml b/src/uu/pr/Cargo.toml index 27863962a..4110617e4 100644 --- a/src/uu/pr/Cargo.toml +++ b/src/uu/pr/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/pr.rs" diff --git a/src/uu/printenv/Cargo.toml b/src/uu/printenv/Cargo.toml index 00cd6ad98..3d63e9291 100644 --- a/src/uu/printenv/Cargo.toml +++ b/src/uu/printenv/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/printenv.rs" diff --git a/src/uu/printf/Cargo.toml b/src/uu/printf/Cargo.toml index 91727d560..2325545d3 100644 --- a/src/uu/printf/Cargo.toml +++ b/src/uu/printf/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/printf.rs" diff --git a/src/uu/ptx/Cargo.toml b/src/uu/ptx/Cargo.toml index d703a4f40..133d6b436 100644 --- a/src/uu/ptx/Cargo.toml +++ b/src/uu/ptx/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/ptx.rs" diff --git a/src/uu/pwd/Cargo.toml b/src/uu/pwd/Cargo.toml index a927e1929..62e19d77a 100644 --- a/src/uu/pwd/Cargo.toml +++ b/src/uu/pwd/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/pwd.rs" diff --git a/src/uu/readlink/Cargo.toml b/src/uu/readlink/Cargo.toml index 17ec518e5..2b65e460c 100644 --- a/src/uu/readlink/Cargo.toml +++ b/src/uu/readlink/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/readlink.rs" diff --git a/src/uu/realpath/Cargo.toml b/src/uu/realpath/Cargo.toml index dc2bcc273..6ba3d3ca9 100644 --- a/src/uu/realpath/Cargo.toml +++ b/src/uu/realpath/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/realpath.rs" diff --git a/src/uu/rm/Cargo.toml b/src/uu/rm/Cargo.toml index d529e0853..4a0705a48 100644 --- a/src/uu/rm/Cargo.toml +++ b/src/uu/rm/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/rm.rs" diff --git a/src/uu/rmdir/Cargo.toml b/src/uu/rmdir/Cargo.toml index 80e896641..c6a6d7501 100644 --- a/src/uu/rmdir/Cargo.toml +++ b/src/uu/rmdir/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/rmdir.rs" diff --git a/src/uu/runcon/Cargo.toml b/src/uu/runcon/Cargo.toml index fd8259274..efd69ed3f 100644 --- a/src/uu/runcon/Cargo.toml +++ b/src/uu/runcon/Cargo.toml @@ -12,6 +12,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/runcon.rs" diff --git a/src/uu/seq/Cargo.toml b/src/uu/seq/Cargo.toml index f90c039cd..cfec01c15 100644 --- a/src/uu/seq/Cargo.toml +++ b/src/uu/seq/Cargo.toml @@ -34,6 +34,11 @@ uucore = { workspace = true, features = [ name = "seq" path = "src/main.rs" +# FIXME: this is the only crate that has a separate lints configuration, +# which for now means a full copy of all clippy and rust lints here. +[lints.clippy] +all = { level = "deny", priority = -1 } + # Allow "fuzzing" as a "cfg" condition name # https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html [lints.rust] diff --git a/src/uu/shred/Cargo.toml b/src/uu/shred/Cargo.toml index e8e901a29..7675bf2ac 100644 --- a/src/uu/shred/Cargo.toml +++ b/src/uu/shred/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/shred.rs" diff --git a/src/uu/shuf/Cargo.toml b/src/uu/shuf/Cargo.toml index 73446acea..bc87befaf 100644 --- a/src/uu/shuf/Cargo.toml +++ b/src/uu/shuf/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/shuf.rs" diff --git a/src/uu/sleep/Cargo.toml b/src/uu/sleep/Cargo.toml index 89ddfe229..c4c03b0cf 100644 --- a/src/uu/sleep/Cargo.toml +++ b/src/uu/sleep/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/sleep.rs" diff --git a/src/uu/sort/Cargo.toml b/src/uu/sort/Cargo.toml index 4e87db3df..a23a61b86 100644 --- a/src/uu/sort/Cargo.toml +++ b/src/uu/sort/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/sort.rs" diff --git a/src/uu/split/Cargo.toml b/src/uu/split/Cargo.toml index 1bcfcb0c1..572cb98b4 100644 --- a/src/uu/split/Cargo.toml +++ b/src/uu/split/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/split.rs" diff --git a/src/uu/stat/Cargo.toml b/src/uu/stat/Cargo.toml index d47254b0c..fdd648ffe 100644 --- a/src/uu/stat/Cargo.toml +++ b/src/uu/stat/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/stat.rs" diff --git a/src/uu/stdbuf/Cargo.toml b/src/uu/stdbuf/Cargo.toml index b0e229c76..367d4e109 100644 --- a/src/uu/stdbuf/Cargo.toml +++ b/src/uu/stdbuf/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/stdbuf.rs" diff --git a/src/uu/stty/Cargo.toml b/src/uu/stty/Cargo.toml index a995b60dc..fb3730308 100644 --- a/src/uu/stty/Cargo.toml +++ b/src/uu/stty/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/stty.rs" diff --git a/src/uu/sum/Cargo.toml b/src/uu/sum/Cargo.toml index a6e23148d..9dc272923 100644 --- a/src/uu/sum/Cargo.toml +++ b/src/uu/sum/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/sum.rs" diff --git a/src/uu/sync/Cargo.toml b/src/uu/sync/Cargo.toml index b4cc7b4d1..467020ddf 100644 --- a/src/uu/sync/Cargo.toml +++ b/src/uu/sync/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/sync.rs" diff --git a/src/uu/tac/Cargo.toml b/src/uu/tac/Cargo.toml index e6ded1a4a..b4715cc55 100644 --- a/src/uu/tac/Cargo.toml +++ b/src/uu/tac/Cargo.toml @@ -15,6 +15,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/tac.rs" diff --git a/src/uu/tail/Cargo.toml b/src/uu/tail/Cargo.toml index cf2b1e308..a9fa69ed9 100644 --- a/src/uu/tail/Cargo.toml +++ b/src/uu/tail/Cargo.toml @@ -14,6 +14,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/tail.rs" diff --git a/src/uu/tee/Cargo.toml b/src/uu/tee/Cargo.toml index b6e52fb1a..2072444c8 100644 --- a/src/uu/tee/Cargo.toml +++ b/src/uu/tee/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/tee.rs" diff --git a/src/uu/test/Cargo.toml b/src/uu/test/Cargo.toml index 70de22acd..188f794e3 100644 --- a/src/uu/test/Cargo.toml +++ b/src/uu/test/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/test.rs" diff --git a/src/uu/timeout/Cargo.toml b/src/uu/timeout/Cargo.toml index 9a9e2987d..03801a8ca 100644 --- a/src/uu/timeout/Cargo.toml +++ b/src/uu/timeout/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/timeout.rs" diff --git a/src/uu/touch/Cargo.toml b/src/uu/touch/Cargo.toml index 15fdba163..a7b356cc8 100644 --- a/src/uu/touch/Cargo.toml +++ b/src/uu/touch/Cargo.toml @@ -14,6 +14,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/touch.rs" diff --git a/src/uu/tr/Cargo.toml b/src/uu/tr/Cargo.toml index e07420ee4..cc41fe237 100644 --- a/src/uu/tr/Cargo.toml +++ b/src/uu/tr/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/tr.rs" diff --git a/src/uu/true/Cargo.toml b/src/uu/true/Cargo.toml index 744786528..73febe4ac 100644 --- a/src/uu/true/Cargo.toml +++ b/src/uu/true/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/true.rs" diff --git a/src/uu/truncate/Cargo.toml b/src/uu/truncate/Cargo.toml index 8cd4cd1d3..6fc412a79 100644 --- a/src/uu/truncate/Cargo.toml +++ b/src/uu/truncate/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/truncate.rs" diff --git a/src/uu/tsort/Cargo.toml b/src/uu/tsort/Cargo.toml index 51c972dcc..868253449 100644 --- a/src/uu/tsort/Cargo.toml +++ b/src/uu/tsort/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/tsort.rs" diff --git a/src/uu/tty/Cargo.toml b/src/uu/tty/Cargo.toml index 2739aac23..9d7d661f2 100644 --- a/src/uu/tty/Cargo.toml +++ b/src/uu/tty/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/tty.rs" diff --git a/src/uu/uname/Cargo.toml b/src/uu/uname/Cargo.toml index 0aea36546..6d71ebcd0 100644 --- a/src/uu/uname/Cargo.toml +++ b/src/uu/uname/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/uname.rs" diff --git a/src/uu/unexpand/Cargo.toml b/src/uu/unexpand/Cargo.toml index 79248a70f..d6edba406 100644 --- a/src/uu/unexpand/Cargo.toml +++ b/src/uu/unexpand/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/unexpand.rs" diff --git a/src/uu/uniq/Cargo.toml b/src/uu/uniq/Cargo.toml index e47a2cfcb..1a87afb7d 100644 --- a/src/uu/uniq/Cargo.toml +++ b/src/uu/uniq/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/uniq.rs" diff --git a/src/uu/unlink/Cargo.toml b/src/uu/unlink/Cargo.toml index 3bab76a1e..ec5c538bd 100644 --- a/src/uu/unlink/Cargo.toml +++ b/src/uu/unlink/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/unlink.rs" diff --git a/src/uu/uptime/Cargo.toml b/src/uu/uptime/Cargo.toml index e5a031c11..45821bcd1 100644 --- a/src/uu/uptime/Cargo.toml +++ b/src/uu/uptime/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/uptime.rs" diff --git a/src/uu/users/Cargo.toml b/src/uu/users/Cargo.toml index 6341b4a94..df0d0884b 100644 --- a/src/uu/users/Cargo.toml +++ b/src/uu/users/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/users.rs" diff --git a/src/uu/vdir/Cargo.toml b/src/uu/vdir/Cargo.toml index 26c8bac00..d53605785 100644 --- a/src/uu/vdir/Cargo.toml +++ b/src/uu/vdir/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/vdir.rs" diff --git a/src/uu/wc/Cargo.toml b/src/uu/wc/Cargo.toml index 1e3fc7056..877c78a97 100644 --- a/src/uu/wc/Cargo.toml +++ b/src/uu/wc/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/wc.rs" diff --git a/src/uu/who/Cargo.toml b/src/uu/who/Cargo.toml index 24bf451c1..ae143320d 100644 --- a/src/uu/who/Cargo.toml +++ b/src/uu/who/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/who.rs" diff --git a/src/uu/whoami/Cargo.toml b/src/uu/whoami/Cargo.toml index 22bd2a26c..6ab5d48e5 100644 --- a/src/uu/whoami/Cargo.toml +++ b/src/uu/whoami/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/whoami.rs" diff --git a/src/uu/yes/Cargo.toml b/src/uu/yes/Cargo.toml index e33766f3d..4e208c5c7 100644 --- a/src/uu/yes/Cargo.toml +++ b/src/uu/yes/Cargo.toml @@ -13,6 +13,9 @@ edition = "2024" readme.workspace = true +[lints] +workspace = true + [lib] path = "src/yes.rs"