ruff/docs/rules
Martin Fischer 28c9263722 Automatically linkify option references in rule documentation
Previously the rule documentation referenced configuration options
via full https:// URLs, which was bad for several reasons:

* changing the website would mean you'd have to change all URLs
* the links didn't work when building mkdocs locally
* the URLs showed up in the `ruff rule` output
* broken references weren't detected by our CI

This commit solves all of these problems by post-processing the
Markdown, recognizing sections such as:

    ## Options

    * `flake8-tidy-imports.ban-relative-imports`

`cargo dev generate-all` will automatically linkify such references
and panic if the referenced option doesn't exist.
Note that the option can also be linked in the other Markdown sections
via e.g. [`flake8-tidy-imports.ban-relative-imports`] since
the post-processing code generates a CommonMark link definition.

Resolves #2766.
2023-02-12 13:19:11 -05:00
..
any-type.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
assert-raises-exception.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
avoidable-escaped-quote.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
bad-quotes-docstring.md Automatically linkify option references in rule documentation 2023-02-12 13:19:11 -05:00
bad-quotes-inline-string.md Automatically linkify option references in rule documentation 2023-02-12 13:19:11 -05:00
bad-quotes-multiline-string.md Automatically linkify option references in rule documentation 2023-02-12 13:19:11 -05:00
bad-string-format-type.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
banned-api.md [flake8-tidy-imports] add documentation for banned-api (#2819) 2023-02-12 18:09:39 +00:00
bare-except.md Add E722 bare-except documentation (#2796) 2023-02-12 16:51:32 +00:00
commented-out-code.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
complex-structure.md Automatically linkify option references in rule documentation 2023-02-12 13:19:11 -05:00
f-string-missing-placeholders.md Improve f-string-missing-placeholders documentation (#2800) 2023-02-12 04:58:24 +00:00
hardcoded-sql-expression.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
implicit-namespace-package.md Automatically linkify option references in rule documentation 2023-02-12 13:19:11 -05:00
missing-required-import.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-return-type-class-method.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-return-type-private-function.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-return-type-public-function.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-return-type-special-method.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-return-type-static-method.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-type-args.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-type-cls.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-type-function-argument.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-type-kwargs.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
missing-type-self.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
model-dunder-str.md Implement flake8-django plugin rules (#2586) 2023-02-12 17:47:59 +00:00
model-string-field-nullable.md Implement flake8-django plugin rules (#2586) 2023-02-12 17:47:59 +00:00
prefix-type-params.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
raise-vanilla-class.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
receiver-decorator-checker.md Implement flake8-django plugin rules (#2586) 2023-02-12 17:47:59 +00:00
relative-imports.md Automatically linkify option references in rule documentation 2023-02-12 13:19:11 -05:00
unconventional-import-alias.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
unnecessary-call-around-sorted.md [flake8-comprehensions] bugfix for C413 autofix (#2804) 2023-02-12 15:56:07 +00:00
unnecessary-double-cast-or-process.md [flake8-comprehensions] autofix C414 and C417 + bugfix (#2693) 2023-02-12 05:20:42 +00:00
unnecessary-generator-dict.md [flake8-comprehensions] improve autofix for C401, C402 and C417 (#2806) 2023-02-12 16:03:37 +00:00
unnecessary-generator-list.md [flake8-comprehensions] improve autofix for C401, C402 and C417 (#2806) 2023-02-12 16:03:37 +00:00
unnecessary-generator-set.md [flake8-comprehensions] improve autofix for C401, C402 and C417 (#2806) 2023-02-12 16:03:37 +00:00
unnecessary-map.md [flake8-comprehensions] autofix C414 and C417 + bugfix (#2693) 2023-02-12 05:20:42 +00:00
unrecognized-platform-check.md [flake8-pyi]: add rules for unrecognized platform check (PYI007, PYI008) (#2805) 2023-02-12 18:02:38 +00:00
unrecognized-platform-name.md [flake8-pyi]: add rules for unrecognized platform check (PYI007, PYI008) (#2805) 2023-02-12 18:02:38 +00:00
unsorted-imports.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00
unused-variable.md Automatically linkify option references in rule documentation 2023-02-12 13:19:11 -05:00
use-of-inplace-argument.md Add PD002 use-of-inplace-argument documentation (#2799) 2023-02-12 18:10:34 +00:00
yield-in-init.md Adjust heading level in rule documentation (#2749) 2023-02-10 19:10:42 -05:00