From f50196a67fe1c8186e43c3a029c5b3cc26a919fd Mon Sep 17 00:00:00 2001 From: Casey Rodarmor Date: Wed, 15 Jan 2020 02:30:24 -0800 Subject: [PATCH] Check long lines and FIXME/TODO on CI (#575) --- .github/workflows/rust.yaml | 4 ++- src/config.rs | 3 ++- src/lib.rs | 49 +++++++++++++++++-------------------- 3 files changed, 27 insertions(+), 29 deletions(-) diff --git a/.github/workflows/rust.yaml b/.github/workflows/rust.yaml index 7332dbc..05c96cc 100644 --- a/.github/workflows/rust.yaml +++ b/.github/workflows/rust.yaml @@ -19,8 +19,10 @@ jobs: rustup --version cargo --version cargo clippy --version - - name: Lint + - name: Clippy run: cargo clippy + - name: Lint + run: cargo run lint - name: Format run: cargo fmt -- --check - name: Completion Scripts diff --git a/src/config.rs b/src/config.rs index 7106cd9..1f79559 100644 --- a/src/config.rs +++ b/src/config.rs @@ -674,7 +674,8 @@ OPTIONS: Print colorful output [default: auto] [possible values: auto, always, never] --completions - Print shell completion script for [possible values: zsh, bash, fish, powershell, elvish] + Print shell completion script for \ + [possible values: zsh, bash, fish, powershell, elvish] -f, --justfile Use as justfile. --set Override with diff --git a/src/lib.rs b/src/lib.rs index 0a2c43b..740e254 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,36 +1,31 @@ #![deny(clippy::all, clippy::pedantic, clippy::restriction)] #![allow( - clippy::print_stdout, - clippy::else_if_without_else, - clippy::use_debug, - clippy::implicit_return, - clippy::if_not_else, - clippy::missing_docs_in_private_items, - clippy::enum_glob_use, - clippy::integer_arithmetic, - clippy::option_unwrap_used, - clippy::indexing_slicing, - clippy::non_ascii_literal, - clippy::missing_inline_in_public_items, - clippy::option_expect_used, clippy::comparison_chain, - clippy::wildcard_enum_match_arm, - clippy::too_many_lines, - clippy::shadow_unrelated, - clippy::needless_pass_by_value, - clippy::option_map_unwrap_or, + clippy::else_if_without_else, + clippy::enum_glob_use, clippy::filter_map, - clippy::result_expect_used, - clippy::unreachable, - clippy::string_add, + clippy::if_not_else, + clippy::implicit_return, + clippy::indexing_slicing, + clippy::integer_arithmetic, + clippy::match_same_arms, + clippy::missing_docs_in_private_items, + clippy::missing_inline_in_public_items, + clippy::needless_pass_by_value, + clippy::non_ascii_literal, + clippy::option_expect_used, + clippy::option_map_unwrap_or, + clippy::option_unwrap_used, clippy::panic, - clippy::match_same_arms + clippy::print_stdout, + clippy::result_expect_used, + clippy::shadow_unrelated, + clippy::string_add, + clippy::too_many_lines, + clippy::unreachable, + clippy::use_debug, + clippy::wildcard_enum_match_arm )] -// clippy::option_map_unwrap_or_else, -// clippy::result_expect_used, -// clippy::result_unwrap_used, -// clippy::unreachable -// )] #[macro_use] extern crate lazy_static;