Skip to content

Commit 4da5cc5

Browse files
committed
docs: Lint
1 parent ce41279 commit 4da5cc5

16 files changed

Lines changed: 55 additions & 22 deletions

File tree

docs/code-of-conduct.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,5 @@
1+
---
2+
title: Code of Conduct
3+
---
4+
15
--8<-- "CODE_OF_CONDUCT.md"

docs/community.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Griffe is part of is the [mkdocstrings](https://mkdocstrings.github.io/) ecosyst
44

55
You can start new discussions on GitHub, in the following repositories, depending on the specificity of the discussion: [griffe](https://github.com/mkdocstrings/griffe), [mkdocstrings-python](https://github.com/mkdocstrings/python), [mkdocstrings](https://github.com/mkdocstrings/mkdocstrings), and [MkDocs](https://github.com/mkdocs/mkdocs).
66

7-
You can also join our dedicated Gitter channels: [Griffe channel](https://app.gitter.im/#/room/#mkdocstrings_griffe:gitter.im){ target="_blank" }, [mkdocstrings-python channel](https://app.gitter.im/#/room/#mkdocstrings_python:gitter.im){ target="_blank" }, [mkdocstrings channel](https://app.gitter.im/#/room/#mkdocstrings_community:gitter.im){ target="_blank" }, and [MkDocs channel](https://app.gitter.im/#/room/#mkdocs_community:gitter.im){ target="_blank" }.
7+
You can also join our dedicated Gitter channels: [Griffe channel](https://app.gitter.im/#/room/#mkdocstrings_griffe:gitter.im){ target="_blank" }, [mkdocstrings-python channel](https://app.gitter.im/#/room/#mkdocstrings_python:gitter.im){ target="_blank" }, [mkdocstrings channel](https://app.gitter.im/#/room/#mkdocstrings_community:gitter.im){ target="_blank" }, and [MkDocs channel](https://app.gitter.im/#/room/#mkdocs_community:gitter.im){ target="_blank" }.
88

99
The best place to share about Griffe is of course our Gitter channel.
1010

docs/extensions/official.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ Official extensions are developed and maintained within the mkdocstrings organiz
55
Extension | Description | Sponsors only?
66
--------- | ----------- | --------------
77
[`autodocstringstyle`](official/autodocstringstyle.md) | Set docstring style to `auto` for external packages. | [:octicons-heart-fill-24:{ .pulse }](../insiders/index.md){ .insiders }
8-
[`inherited-docstrings`](official/inherited-docstrings.md) | Inherit docstrings from parent classes.
8+
[`inherited-docstrings`](official/inherited-docstrings.md) | Inherit docstrings from parent classes. |
99
[`public-redundant-aliases`](official/public-redundant-aliases.md) | Mark objects imported with redundant aliases as public. | [:octicons-heart-fill-24:{ .pulse }](../insiders/index.md){ .insiders }
1010
[`public-wildcard-imports`](official/public-wildcard-imports.md) | Mark wildcard imported objects as public. | [:octicons-heart-fill-24:{ .pulse }](../insiders/index.md){ .insiders }
11-
[`pydantic`](official/pydantic.md) | Support for [Pydantic](https://docs.pydantic.dev/latest/) models.
11+
[`pydantic`](official/pydantic.md) | Support for [Pydantic](https://docs.pydantic.dev/latest/) models. |
1212
[`runtime-objects`](official/runtime-objects.md) | Access runtime objects corresponding to each loaded Griffe object through their `extra` attribute. | [:octicons-heart-fill-24:{ .pulse }](../insiders/index.md){ .insiders }
1313
[`sphinx`](official/sphinx.md) | Parse [Sphinx](https://www.sphinx-doc.org/)-comments above attributes (`#:`) as docstrings. | [:octicons-heart-fill-24:{ .pulse }](../insiders/index.md){ .insiders }
14-
[`typing-doc`](official/typingdoc.md) | Support for [PEP 727](https://peps.python.org/pep-0727/)'s [`typing.Doc`][typing_extensions.Doc], "Documentation in Annotated Metadata".
15-
[`warnings-deprecated`](official/warnings-deprecated.md) | Support for [PEP 702](https://peps.python.org/pep-0702/)'s [`warnings.deprecated`][], "Marking deprecations using the type system".
14+
[`typing-doc`](official/typingdoc.md) | Support for [PEP 727](https://peps.python.org/pep-0727/)'s [`typing.Doc`][typing_extensions.Doc], "Documentation in Annotated Metadata". |
15+
[`warnings-deprecated`](official/warnings-deprecated.md) | Support for [PEP 702](https://peps.python.org/pep-0702/)'s [`warnings.deprecated`][], "Marking deprecations using the type system". |

docs/guide/contributors/architecture.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ The test suite is based on [pytest](https://docs.pytest.org/en/8.2.x/). Test mod
110110

111111
The internal API is contained within the `src/griffe/_internal` folder. The top-level `griffe/__init__.py` module exposes all the public API, by importing the internal objects from various submodules of `griffe._internal`.
112112

113-
Users then import `griffe` directly, or import objects from it.
113+
Users then import `griffe` directly, or import objects from it.
114114

115115
We'll be honest: our code organization is not the most elegant, but it works :shrug: Have a look at the following module dependency graph, which will basically tell you nothing except that we have a lot of inter-module dependencies. Arrows read as "imports from". The code base is generally pleasant to work with though.
116116

docs/guide/contributors/commands.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ $ make
1414
Commands are always available: they don't require any Python dependency to be installed.
1515

1616
[](){#command-setup}
17+
1718
### `setup`
1819

1920
::: make.setup
@@ -25,6 +26,7 @@ Commands are always available: they don't require any Python dependency to be in
2526
parameter_headings: false
2627

2728
[](){#command-help}
29+
2830
### `help`
2931

3032
::: make.help
@@ -36,6 +38,7 @@ Commands are always available: they don't require any Python dependency to be in
3638
parameter_headings: false
3739

3840
[](){#command-run}
41+
3942
### `run`
4043

4144
::: make.run
@@ -47,6 +50,7 @@ Commands are always available: they don't require any Python dependency to be in
4750
parameter_headings: false
4851

4952
[](){#command-multirun}
53+
5054
### `multirun`
5155

5256
::: make.multirun
@@ -58,6 +62,7 @@ Commands are always available: they don't require any Python dependency to be in
5862
parameter_headings: false
5963

6064
[](){#command-allrun}
65+
6166
### `allrun`
6267

6368
::: make.allrun
@@ -69,6 +74,7 @@ Commands are always available: they don't require any Python dependency to be in
6974
parameter_headings: false
7075

7176
[](){#command-3.x}
77+
7278
### `3.x`
7379

7480
::: make.run3x
@@ -80,6 +86,7 @@ Commands are always available: they don't require any Python dependency to be in
8086
parameter_headings: false
8187

8288
[](){#command-clean}
89+
8390
### `clean`
8491

8592
::: make.clean
@@ -91,6 +98,7 @@ Commands are always available: they don't require any Python dependency to be in
9198
parameter_headings: false
9299

93100
[](){#command-vscode}
101+
94102
### `vscode`
95103

96104
::: make.vscode
@@ -112,6 +120,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
112120
- `make 3.x duty TASK`, to run a task on a specific Python version
113121

114122
[](){#task-build}
123+
115124
### `build`
116125

117126
::: duties.build
@@ -123,6 +132,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
123132
parameter_headings: false
124133

125134
[](){#task-changelog}
135+
126136
### `changelog`
127137

128138
::: duties.changelog
@@ -134,6 +144,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
134144
parameter_headings: false
135145

136146
[](){#task-check}
147+
137148
### `check`
138149

139150
::: duties.check
@@ -145,6 +156,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
145156
parameter_headings: false
146157

147158
[](){#task-check-api}
159+
148160
### `check-api`
149161

150162
::: duties.check_api
@@ -156,6 +168,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
156168
parameter_headings: false
157169

158170
[](){#task-check-docs}
171+
159172
### `check-docs`
160173

161174
::: duties.check_docs
@@ -167,6 +180,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
167180
parameter_headings: false
168181

169182
[](){#task-check-quality}
183+
170184
### `check-quality`
171185

172186
::: duties.check_quality
@@ -178,6 +192,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
178192
parameter_headings: false
179193

180194
[](){#task-check-types}
195+
181196
### `check-types`
182197

183198
::: duties.check_types
@@ -189,6 +204,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
189204
parameter_headings: false
190205

191206
[](){#task-coverage}
207+
192208
### `coverage`
193209

194210
::: duties.coverage
@@ -200,6 +216,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
200216
parameter_headings: false
201217

202218
[](){#task-docs}
219+
203220
### `docs`
204221

205222
::: duties.docs
@@ -211,6 +228,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
211228
parameter_headings: false
212229

213230
[](){#task-docs-deploy}
231+
214232
### `docs-deploy`
215233

216234
::: duties.docs_deploy
@@ -222,6 +240,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
222240
parameter_headings: false
223241

224242
[](){#task-format}
243+
225244
### `format`
226245

227246
::: duties.format
@@ -233,6 +252,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
233252
parameter_headings: false
234253

235254
[](){#task-fuzz}
255+
236256
### `fuzz`
237257

238258
::: duties.fuzz
@@ -244,6 +264,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
244264
parameter_headings: false
245265

246266
[](){#task-publish}
267+
247268
### `publish`
248269

249270
::: duties.publish
@@ -255,6 +276,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
255276
parameter_headings: false
256277

257278
[](){#task-release}
279+
258280
### `release`
259281

260282
::: duties.release
@@ -266,6 +288,7 @@ Tasks require the Python dependencies to be installed. They use various tools an
266288
parameter_headings: false
267289

268290
[](){#task-test}
291+
269292
### `test`
270293

271294
::: duties.test

docs/guide/contributors/workflow.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,15 +79,15 @@ If you are unsure about how to deprecate something or mark legacy code, let us d
7979

8080
Commit messages must follow our convention based on the [Angular style](https://gist.github.com/stephenparish/9941e89d80e2bc58a153#format-of-the-commit-message) or the [Karma convention](https://karma-runner.github.io/4.0/dev/git-commit-msg.html):
8181

82-
```
82+
```text
8383
type(scope): Subject
8484
8585
Body.
8686
```
8787

8888
**Subject and body must be valid Markdown.** Subject must have proper casing (uppercase for first letter if it makes sense), but no dot at the end, and no punctuation in general. Example:
8989

90-
```
90+
```text
9191
feat: Add CLI option to run in verbose mode
9292
```
9393

@@ -107,7 +107,7 @@ Scope and body are optional. Type can be:
107107

108108
If you write a body, please add trailers at the end (for example issues and PR references, or co-authors), without relying on GitHub's flavored Markdown:
109109

110-
```
110+
```text
111111
This is the body of the commit message.
112112
113113
Issue-10: https://github.com/namespace/project/issues/10

docs/guide/users/checking.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,10 +108,10 @@ jobs:
108108
runs-on: ubuntu-latest
109109
steps:
110110
- uses: actions/checkout@v4
111-
111+
112112
# Griffe requires that Git tags are available.
113113
- run: git fetch --depth=1 --tags
114-
114+
115115
- uses: actions/setup-python@v5
116116
with:
117117
python-version: "3.11"
@@ -644,6 +644,7 @@ NOTE: Unless inherited members are lost in the process, removing a class base is
644644
Griffe supports writing detected breakages in multiple formats, or styles.
645645

646646
[](){#format-oneline}
647+
647648
### One-line
648649

649650
- **CLI**: `-f oneline` / no flags
@@ -657,6 +658,7 @@ $ griffe check griffe -ssrc -b0.46.0 -a0.45.0
657658
```
658659

659660
[](){#format-verbose}
661+
660662
### Verbose
661663

662664
- **CLI**: `-f verbose` / `-v`
@@ -670,6 +672,7 @@ $ griffe check griffe -ssrc -b0.46.0 -a0.45.0 --verbose
670672
```
671673

672674
[](){#format-markdown}
675+
673676
### Markdown
674677

675678
[:octicons-tag-24: Insiders 1.0.0](../../insiders/changelog.md#1.0.0)
@@ -703,6 +706,7 @@ The Markdown format is adapted for changelogs. It doesn't show the file and line
703706
```
704707

705708
[](){#format-github}
709+
706710
### GitHub
707711

708712
[:octicons-tag-24: Insiders 1.0.0](../../insiders/changelog.md#1.0.0)

docs/guide/users/extending.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -674,7 +674,6 @@ See [how to use extensions](#using-extensions) to learn more about how to load a
674674
[^5]: Now `ExceptHandler`, in the `handlers` attribute of `Try` nodes.
675675
[^6]: Now a list of expressions in the `finalbody` attribute of `Try` nodes.
676676

677-
678677
## Next steps
679678

680679
Extensions are a powerful mechanism to customize or enhance the data loaded by Griffe. But sometimes, all you need to do to improve the data is to make Griffe happy by following a few conventions. We therefore invite you to read our recommendations on [public APIs](recommendations/public-apis.md), [Python code best practices](recommendations/python-code.md) and [docstrings](recommendations/docstrings.md).

docs/guide/users/how-to/set-docstring-styles.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Depending on the markup you use in docstrings, you can add a comment that tells
3737
"""
3838
```
3939

40-
Your Griffe extension can then use regular expressions to search for such comments. For example with Markdown (HTML) comments:
40+
Your Griffe extension can then use regular expressions to search for such comments. For example with Markdown (HTML) comments:
4141

4242
```python
4343
import re

docs/guide/users/recommendations/docstrings.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ class Ghost:
188188

189189
def wander(self) -> None:
190190
"""Wander the earth.
191-
191+
192192
That's it, really.
193193
194194
Examples:
@@ -252,7 +252,7 @@ def yield_athletes(quantity: int) -> Iterator[Ghost]:
252252
253253
Parameters:
254254
quantity: How many ghost athletes you want.
255-
255+
256256
Yields:
257257
Ghost athletes. They're just regular ghosts.
258258
"""

0 commit comments

Comments
 (0)