Skip to content

Commit 8bfae4e

Browse files
committed
Add pyrefly and pyrefly-docs configuration
1 parent 56a75ff commit 8bfae4e

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

.pre-commit-config.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@ ci:
3838
- vulture
3939
- vulture-docs
4040
- yamlfix
41+
- pyrefly
42+
- pyrefly-docs
4143

4244
# See https://pre-commit.com for more information
4345
# See https://pre-commit.com/hooks.html for more hooks
@@ -389,3 +391,21 @@ repos:
389391
types_or: [rst]
390392
additional_dependencies: [uv==0.9.5]
391393
stages: [pre-commit]
394+
395+
- id: pyrefly
396+
name: pyrefly
397+
stages: [pre-push]
398+
entry: uv run --extra=dev pyrefly check
399+
language: python
400+
types_or: [python, toml]
401+
pass_filenames: false
402+
additional_dependencies: [uv==0.9.5]
403+
404+
- id: pyrefly-docs
405+
name: pyrefly-docs
406+
stages: [pre-push]
407+
entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python
408+
--command="pyrefly check"
409+
language: python
410+
types_or: [markdown, rst]
411+
additional_dependencies: [uv==0.9.5]

pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ optional-dependencies.dev = [
7070
"pylint[spelling]==4.0.4",
7171
"pylint-per-file-ignores==3.2.0",
7272
"pyproject-fmt==2.11.1",
73+
"pyrefly==0.46.1",
7374
"pyright==1.1.407",
7475
"pyroma==5.0.1",
7576
"pytest==9.0.2",

0 commit comments

Comments
 (0)