Skip to content

Commit 6adfb71

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent e686fb0 commit 6adfb71

3 files changed

Lines changed: 5 additions & 14 deletions

File tree

babelizer/_files/bmi_py.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,15 +59,10 @@ def _render_bmi_py(context: Mapping[str, Any]) -> str:
5959
for cls, component in context["library"].items()
6060
]
6161

62-
rename = [
63-
f"""\
62+
rename = [f"""\
6463
{cls}.__name__ = {cls!r}
6564
{cls}.METADATA = str(importlib_resources.files(__name__) / "data/{cls}")
66-
""".replace(
67-
"'", '"'
68-
)
69-
for cls in context["library"]
70-
]
65+
""".replace("'", '"') for cls in context["library"]]
7166

7267
names = [f" {cls!r},".replace("'", '"') for cls in context["library"]]
7368

babelizer/_files/meson_build.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,16 +70,14 @@ def _render_install_block(install: Iterable[str]) -> str:
7070
files_to_install = []
7171
for subdir, files in sorted(install_sources.items()):
7272
lines = [f" {os.path.join(subdir, f)!r}," for f in files]
73-
files_to_install.append(
74-
f"""\
73+
files_to_install.append(f"""\
7574
py.install_sources(
7675
[
7776
{os.linesep.join(sorted(lines))}
7877
],
7978
subdir: {subdir!r},
8079
)\
81-
"""
82-
)
80+
""")
8381
return os.linesep.join(files_to_install)
8482

8583

babelizer/_post_hook.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,7 @@ def write_api_yaml(folderpath: Path, **kwds: str) -> Path:
8585
language: {language}
8686
package: {package_name}
8787
class: {plugin_class}
88-
""".format(
89-
**kwds
90-
)
88+
""".format(**kwds)
9189
with open(api_yaml, "w") as fp:
9290
fp.write(contents)
9391

0 commit comments

Comments
 (0)