File tree Expand file tree Collapse file tree 1 file changed +27
-29
lines changed Expand file tree Collapse file tree 1 file changed +27
-29
lines changed Original file line number Diff line number Diff line change @@ -54,86 +54,84 @@ Rebuild docs and run server via one terminal: `make dev_docs` (requires above, a
54
54
55
55
## Linting
56
56
57
- ### black
57
+ ### ruff
58
58
59
- [ black ] is used for formatting.
59
+ The project uses [ ruff ] to handles formatting, sorting imports and linting .
60
60
61
61
```` {tab} Command
62
62
63
63
poetry:
64
64
65
65
```console
66
- $ poetry run black .
66
+ $ poetry run ruff
67
67
```
68
68
69
69
If you setup manually:
70
70
71
71
```console
72
- $ black .
72
+ $ ruff .
73
73
```
74
74
75
75
````
76
76
77
77
```` {tab} make
78
78
79
79
```console
80
- $ make black
80
+ $ make ruff
81
81
```
82
82
83
83
````
84
84
85
- In the future, ` ruff ` (below) may replace black as formatter.
85
+ ```` {tab} Watch
86
86
87
- ### ruff
87
+ ```console
88
+ $ make watch_ruff
89
+ ```
88
90
89
- The project uses [ ruff ] to handles formatting, sorting imports and linting .
91
+ requires [`entr(1)`] .
90
92
91
- ```` {tab} Command
93
+ ````
94
+
95
+ ```` {tab} Fix files
92
96
93
97
poetry:
94
98
95
99
```console
96
- $ poetry run ruff
100
+ $ poetry run ruff . --fix
97
101
```
98
102
99
103
If you setup manually:
100
104
101
105
```console
102
- $ ruff .
106
+ $ ruff . --fix
103
107
```
104
108
105
109
````
106
110
107
- ```` {tab} make
111
+ #### ruff format
108
112
109
- ```console
110
- $ make ruff
111
- ```
113
+ [ ruff format] is used for formatting.
112
114
113
- ````
115
+ ```` {tab} Command
114
116
115
- ```` {tab} Watch
117
+ poetry:
116
118
117
119
```console
118
- $ make watch_ruff
120
+ $ poetry run ruff format .
119
121
```
120
122
121
- requires [`entr(1)`].
122
-
123
- ````
124
-
125
- ```` {tab} Fix files
126
-
127
- poetry:
123
+ If you setup manually:
128
124
129
125
```console
130
- $ poetry run ruff . --fix
126
+ $ ruff format .
131
127
```
132
128
133
- If you setup manually:
129
+ ````
130
+
131
+ ```` {tab} make
134
132
135
133
```console
136
- $ ruff . --fix
134
+ $ make ruff_format
137
135
```
138
136
139
137
````
@@ -236,6 +234,6 @@ Update `__version__` in `__about__.py` and `pyproject.toml`::
236
234
[ poetry ] : https://python-poetry.org/
237
235
[ entr(1) ] : http://eradman.com/entrproject/
238
236
[ `entr(1)` ] : http://eradman.com/entrproject/
239
- [ black ] : https://github.com/psf/black
237
+ [ ruff format ] : https://docs.astral.sh/ruff/formatter/
240
238
[ ruff ] : https://ruff.rs
241
239
[ mypy ] : http://mypy-lang.org/
You can’t perform that action at this time.
0 commit comments