diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f2df7d9a9e..a4f8bee898 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -93,34 +93,12 @@ jobs: uses: actions-rs/cargo@v1 with: command: clippy - args: > - --tests --verbose -- - -D warnings - -A clippy::literal_string_with_formatting_args - -A clippy::tabs_in_doc_comments + args: --tests --verbose -- -D warnings - name: Check the pedantic lints uses: actions-rs/cargo@v1 with: command: clippy - args: > - --all-targets --verbose -- -W clippy::pedantic - -A clippy::needless_raw_string_hashes - -A clippy::unreadable_literal - -A clippy::redundant_else - -A clippy::items_after_statements - -A clippy::missing_errors_doc - -A clippy::module_name_repetitions - -A clippy::uninlined_format_args - -A clippy::manual_string_new - -A clippy::must_use_candidate - -A clippy::too_many_lines - -A clippy::wildcard_imports - -A clippy::missing_panics_doc - -A clippy::inefficient_to_string - -A clippy::redundant_closure_for_method_calls - -A clippy::map_unwrap_or - -A clippy::struct_excessive_bools - -A clippy::unnecessary_wraps + args: --all-targets --verbose -- -W clippy::pedantic rustfmt: name: Formatting diff --git a/Cargo.toml b/Cargo.toml index 63c163ea62..939a7b4f04 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -32,3 +32,24 @@ strip = true opt-level = 3 debug = true # used by the profiler strip = false # keep symbols for the profiler + +[workspace.lints.clippy] +literal_string_with_formatting_args = "allow" +tabs_in_doc_comments = "allow" +needless_raw_string_hashes = "allow" +unreadable_literal = "allow" +redundant_else = "allow" +items_after_statements = "allow" +missing_errors_doc = "allow" +module_name_repetitions = "allow" +uninlined_format_args = "allow" +manual_string_new = "allow" +must_use_candidate = "allow" +too_many_lines = "allow" +wildcard_imports = "allow" +missing_panics_doc = "allow" +inefficient_to_string = "allow" +redundant_closure_for_method_calls = "allow" +map_unwrap_or = "allow" +struct_excessive_bools = "allow" +unnecessary_wraps = "allow" diff --git a/git-cliff-core/Cargo.toml b/git-cliff-core/Cargo.toml index 2240faee85..e7224f9990 100644 --- a/git-cliff-core/Cargo.toml +++ b/git-cliff-core/Cargo.toml @@ -106,3 +106,6 @@ temp-dir = "0.1.14" [package.metadata.docs.rs] all-features = true rustdoc-args = ["--cfg", "docsrs"] + +[lints] +workspace = true diff --git a/git-cliff/Cargo.toml b/git-cliff/Cargo.toml index 6194a0ece9..881e61c3ad 100644 --- a/git-cliff/Cargo.toml +++ b/git-cliff/Cargo.toml @@ -66,6 +66,9 @@ path = "../git-cliff-core" [dev-dependencies] pretty_assertions = "1.4.1" +[lints] +workspace = true + # metadata for cargo-binstall to get the right artifacts [package.metadata.binstall] pkg-url = "{ repo }/releases/download/v{ version }/{ name }-{ version }-{ target }{ archive-suffix }"