summaryrefslogtreecommitdiff
path: root/rtems_spec_to_x.py
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2020-04-17 14:12:42 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2020-04-17 14:13:20 +0200
commit4733ad338ba7dc74061db4272e7eacaf1107ee57 (patch)
tree1a5bd0b4304cf11b3dad4ba77f0aba5075683779 /rtems_spec_to_x.py
parent8be2ee2f3bfa5c226146e4f64d7b2201b43676ec (diff)
util: New module
Add recursive include for configuration file.
Diffstat (limited to 'rtems_spec_to_x.py')
-rwxr-xr-xrtems_spec_to_x.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/rtems_spec_to_x.py b/rtems_spec_to_x.py
index c9619f3a..06f4d98e 100755
--- a/rtems_spec_to_x.py
+++ b/rtems_spec_to_x.py
@@ -30,12 +30,12 @@ import shutil
import string
import subprocess
from typing import List
-import yaml
import rtemsqual.applconfig
import rtemsqual.build
from rtemsqual.items import ItemCache
import rtemsqual.glossary
+import rtemsqual.util
def _run_command(args: List[str], cwd: str) -> int:
@@ -71,8 +71,7 @@ def _run_pre_qualified_only_build(config: dict, item_cache: ItemCache) -> None:
def main() -> None:
""" Generates glossaries of terms according to the configuration. """
- with open("config.yml", "r") as out:
- config = yaml.safe_load(out.read())
+ config = rtemsqual.util.load_config("config.yml")
item_cache = ItemCache(config["spec"])
rtemsqual.glossary.generate(config["glossary"], item_cache)
rtemsqual.applconfig.generate(config["appl-config"], item_cache)