diff options
| author | Loic Guegan <manzerbredes@mailbox.org> | 2022-09-13 10:46:44 +0200 |
|---|---|---|
| committer | Loic Guegan <manzerbredes@mailbox.org> | 2022-09-13 10:46:44 +0200 |
| commit | e188ca4040ba59b7e61402a3d48c888463b3a4bd (patch) | |
| tree | b6b72ca4838b4b3edf4b6cdf82356e71365fe840 /esds/__main__.py | |
| parent | 3ae36dadc19f62d2da64915e18f26da9aa65c314 (diff) | |
Debug entry point
Diffstat (limited to 'esds/__main__.py')
| -rw-r--r-- | esds/__main__.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/esds/__main__.py b/esds/__main__.py index bf05b24..4bb167d 100644 --- a/esds/__main__.py +++ b/esds/__main__.py @@ -1,8 +1,5 @@ import sys, argparse, os -import platform - -# Allow importlib to import file from current working directory -sys.path.insert(0, os.getcwd()) +from .platform import YAMLPlatformFile def run(arguments): parser = argparse.ArgumentParser(description='Run a simulation') @@ -10,6 +7,8 @@ def run(arguments): args = parser.parse_args(arguments[1:]) if args.platform: simulation=YAMLPlatformFile(args.platform) + # Allow importlib (in simulator.run()) to import file from the platform.yaml directory + sys.path.insert(0, simulation.location) simulation.run() else: parser.print_help() |
