From 7cba23f4976ac6448ad9b7a17ab331bef108ed70 Mon Sep 17 00:00:00 2001 From: Alan Du Date: Fri, 10 Nov 2023 09:33:45 -0500 Subject: [PATCH] Update docs --- crates/ruff_workspace/src/options.rs | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/crates/ruff_workspace/src/options.rs b/crates/ruff_workspace/src/options.rs index 031d0503112d6..73480d815d696 100644 --- a/crates/ruff_workspace/src/options.rs +++ b/crates/ruff_workspace/src/options.rs @@ -2397,9 +2397,26 @@ pub struct PydocstyleOptions { /// convention = "google" /// ``` /// - /// As conventions force-disable all rules not included in the convention, - /// enabling _additional_ rules on top of a convention is currently - /// unsupported. + /// If you must, you can enable rules not included in a convention by + /// requesting the specific error code: + /// + /// ```toml + /// [tool.ruff.lint] + /// extend-select = ["D400"] # will enable D400 rule + /// + /// [tool.ruff.lint.pydocstyle] + /// convention = "google" + /// ``` + /// + /// Just adding a rule prefix will not enable convention-specified rules. + /// + /// ```toml + /// [tool.ruff.lint] + /// extend-select = ["D40"] # will *not* enable D400 rule + /// + /// [tool.ruff.lint.pydocstyle] + /// convention = "google" + /// ``` #[option( default = r#"null"#, value_type = r#""google" | "numpy" | "pep257""#,