fixed + completed type hints
This commit is contained in:
7
main.py
7
main.py
@@ -1,12 +1,13 @@
|
||||
#!/usr/bin/env python3
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import argparse
|
||||
import os
|
||||
|
||||
from schema import InstructionSetSchema
|
||||
|
||||
|
||||
description = """Examples:
|
||||
- Default theme (black on white):
|
||||
python main.py schema.xml -o out.jpg
|
||||
@@ -25,7 +26,7 @@ description = """Examples:
|
||||
"""
|
||||
|
||||
|
||||
def processFile(inPath, outPath, confPath, display):
|
||||
def processFile(inPath: str, outPath: str, confPath: str, display: bool) -> None:
|
||||
schema = InstructionSetSchema(inPath, confPath, display)
|
||||
schema.save(outPath)
|
||||
|
||||
@@ -66,4 +67,4 @@ if __name__ == "__main__":
|
||||
if output is None:
|
||||
output = os.path.splitext(args.schema)[0] + ".png"
|
||||
|
||||
processFile(args.schema, output, args.config, args.display)
|
||||
processFile(args.schema, output, args.config, args.display)
|
||||
|
||||
Reference in New Issue
Block a user