diff options
author | aqua <aqua@iserlohn-fortress.net> | 2024-08-17 17:28:00 +0300 |
---|---|---|
committer | aqua <aqua@iserlohn-fortress.net> | 2024-08-17 17:28:00 +0300 |
commit | 4f95c7062448c569830f4e2819adc1190efbfc55 (patch) | |
tree | fb68a30b3669793af4d57ca56d141d97f99a4e30 /tools/interface_generator/interface_generator.py | |
parent | Added bazel rule for interface_generator (diff) | |
download | kernel-4f95c7062448c569830f4e2819adc1190efbfc55.tar.xz |
interface_generator: added pytest wrapper
Diffstat (limited to 'tools/interface_generator/interface_generator.py')
-rwxr-xr-x | tools/interface_generator/interface_generator.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/interface_generator/interface_generator.py b/tools/interface_generator/interface_generator.py index 4d3afa4..0693897 100755 --- a/tools/interface_generator/interface_generator.py +++ b/tools/interface_generator/interface_generator.py @@ -28,7 +28,7 @@ def generate_file(template: Path, templates: Path, output, kwargs): if isinstance(output, Path): # print(f"writing to {(output / output_name).absolute()}") - with open(output / output_name, "w") as output_file: + with open(output / output_name, "w", encoding="utf-8") as output_file: print(result, file=output_file) else: print(result, file=output) @@ -38,7 +38,7 @@ def main(): """main function""" parser = ArgumentParser( prog="interface_generator", - description="Generate a C header file from an interface definition", + description="Generate C header and mock files from an interface definition", ) parser.add_argument( "-i", |