Skip to content

Commit 883f1fb

Browse files
committed
Rename run_with_mypy to run
1 parent 6838c0f commit 883f1fb

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

tools/run.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
here = pathlib.Path(__file__).parent
1010

1111

12-
def run_with_mypy(*args: str, old: bool) -> None:
12+
def run(*args: str, old: bool) -> None:
1313
if old:
1414
withs = [
1515
"--with",
@@ -55,7 +55,7 @@ def docs(args: list[str], old: bool) -> None:
5555
(build_path / "html").mkdir(exist_ok=True, parents=True)
5656
(build_path / "doctrees").mkdir(exist_ok=True, parents=True)
5757

58-
run_with_mypy(
58+
run(
5959
"--package",
6060
"tools",
6161
"--extra",
@@ -131,13 +131,11 @@ def types(args: list[str], old: bool) -> None:
131131
os.chdir(example_root)
132132
locations = [str(path) for path in paths]
133133

134-
run_with_mypy(
135-
"python", "-m", "mypy", *locations, *args, "--enable-incomplete-feature=Unpack", old=old
136-
)
134+
run("python", "-m", "mypy", *locations, *args, "--enable-incomplete-feature=Unpack", old=old)
137135

138136
if not specified:
139137
os.chdir(here.parent / "example")
140-
run_with_mypy("python", "-m", "mypy", ".", *args, old=old)
138+
run("python", "-m", "mypy", ".", *args, old=old)
141139

142140

143141
@cli.command(context_settings=dict(ignore_unknown_options=True))
@@ -147,7 +145,7 @@ def tests(args: list[str], old: bool) -> None:
147145
"""
148146
Run pytest
149147
"""
150-
run_with_mypy("python", "-m", "pytest", *args, old=old)
148+
run("python", "-m", "pytest", *args, old=old)
151149

152150

153151
if __name__ == "__main__":

0 commit comments

Comments
 (0)