From f5eba91d51715079d2c7ca2666dfc1fd9804ca90 Mon Sep 17 00:00:00 2001 From: Techcable Date: Tue, 5 Sep 2023 16:31:56 -0700 Subject: [PATCH] Setup a clippy configuration file This requires including the Minimum Supported Rust Version (MSRV). Additionally, document in Cargo.toml the different places where the MSRV needs to be kept in sync. --- Cargo.toml | 5 +++++ clippy.toml | 6 ++++++ 2 files changed, 11 insertions(+) create mode 100644 clippy.toml diff --git a/Cargo.toml b/Cargo.toml index 79bdf226..6f05b006 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -25,6 +25,11 @@ edition = "2018" # # The first version of Cargo that supports this field was in Rust 1.56.0. # In older releases, the field will be ignored, and Cargo will display a warning. +# +# This must be kept in sync with the following places: +# - .github/workflows/test.yml (Github Actions) +# - README.md +# - clippy.toml (Clippy config) rust-version = "1.49.0" [profile.release] diff --git a/clippy.toml b/clippy.toml new file mode 100644 index 00000000..55c067ff --- /dev/null +++ b/clippy.toml @@ -0,0 +1,6 @@ +msrv = "1.49.0" +# TODO: Consider adding this? +# +# I would much prefer supressing lints that break +# API compatibility on a case-by-case basis. +# avoid-breaking-exported-api = true