From 8aa38070ca0ea2c488d5e29447397c8517e993a3 Mon Sep 17 00:00:00 2001 From: Joscha Date: Sat, 2 Mar 2024 23:21:06 +0100 Subject: [PATCH] Set up workspace-wide lints --- Cargo.toml | 9 +++++++++ showbits-common/Cargo.toml | 3 +++ showbits-thermal-printer/Cargo.toml | 3 +++ 3 files changed, 15 insertions(+) diff --git a/Cargo.toml b/Cargo.toml index ad2405a..5ef05e2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,3 +8,12 @@ edition = "2021" [workspace.dependencies] showbits-common.path = "./showbits-common" + +[workspace.lints] +rust.unsafe_code = "forbid" +rust.future_incompatible = "warn" +rust.rust_2018_idioms = "warn" +rust.unused = "warn" +rust.noop_method_call = "warn" +rust.single_use_lifetimes = "warn" +clippy.use_self = "warn" diff --git a/showbits-common/Cargo.toml b/showbits-common/Cargo.toml index 99e0271..ec7ce3b 100644 --- a/showbits-common/Cargo.toml +++ b/showbits-common/Cargo.toml @@ -2,3 +2,6 @@ name = "showbits-common" version.workspace = true edition.workspace = true + +[lints] +workspace = true diff --git a/showbits-thermal-printer/Cargo.toml b/showbits-thermal-printer/Cargo.toml index 8339475..68140a7 100644 --- a/showbits-thermal-printer/Cargo.toml +++ b/showbits-thermal-printer/Cargo.toml @@ -5,3 +5,6 @@ edition.workspace = true [dependencies] showbits-common.workspace = true + +[lints] +workspace = true