diff options
| -rw-r--r-- | sources/pyside-tools/deploy.py | 14 | ||||
| -rw-r--r-- | sources/pyside-tools/deploy_lib/commands.py | 1 | ||||
| -rw-r--r-- | sources/pyside-tools/deploy_lib/nuitka_helper.py | 3 | ||||
| -rw-r--r-- | sources/pyside-tools/deploy_lib/python_helper.py | 14 |
4 files changed, 20 insertions, 12 deletions
diff --git a/sources/pyside-tools/deploy.py b/sources/pyside-tools/deploy.py index f2dc21f3e..dbc0e8571 100644 --- a/sources/pyside-tools/deploy.py +++ b/sources/pyside-tools/deploy.py @@ -79,6 +79,9 @@ def main(main_file: Path = None, config_file: Path = None, init: bool = False, else: config_file = Path.cwd() / "pysidedeploy.spec" + # Nuitka command to run + command_str = None + logging.info("[DEPLOY] Start") try: @@ -139,11 +142,11 @@ def main(main_file: Path = None, config_file: Path = None, init: bool = False, # create executable if not dry_run: print("[DEPLOY] Deploying application") - python.create_executable( - source_file=source_file, - extra_args=config.get_value("nuitka", "extra_args"), - config=config, - ) + command_str = python.create_executable( + source_file=source_file, + extra_args=config.get_value("nuitka", "extra_args"), + config=config, + ) except Exception: print(f"Exception occurred: {traceback.format_exc()}") finally: @@ -160,6 +163,7 @@ def main(main_file: Path = None, config_file: Path = None, init: bool = False, clean(generated_files_path) logging.info("[DEPLOY] End") + return command_str if __name__ == "__main__": diff --git a/sources/pyside-tools/deploy_lib/commands.py b/sources/pyside-tools/deploy_lib/commands.py index 92745367f..2733dd4c1 100644 --- a/sources/pyside-tools/deploy_lib/commands.py +++ b/sources/pyside-tools/deploy_lib/commands.py @@ -29,3 +29,4 @@ def run_command(command, dry_run: bool): except Exception as error: logging.exception(f"[DEPLOY]: Command {command_str} failed with error {error}") raise + return command_str diff --git a/sources/pyside-tools/deploy_lib/nuitka_helper.py b/sources/pyside-tools/deploy_lib/nuitka_helper.py index f7114db79..1f4e434c5 100644 --- a/sources/pyside-tools/deploy_lib/nuitka_helper.py +++ b/sources/pyside-tools/deploy_lib/nuitka_helper.py @@ -48,4 +48,5 @@ class Nuitka: linux_icon = str(Path(__file__).parent / "pyside_icon.jpg") command.append(f"--linux-onefile-icon={linux_icon}") - run_command(command=command, dry_run=dry_run) + command_str = run_command(command=command, dry_run=dry_run) + return command_str diff --git a/sources/pyside-tools/deploy_lib/python_helper.py b/sources/pyside-tools/deploy_lib/python_helper.py index 35c3fb35c..e92ce8e0c 100644 --- a/sources/pyside-tools/deploy_lib/python_helper.py +++ b/sources/pyside-tools/deploy_lib/python_helper.py @@ -73,10 +73,12 @@ class PythonExecutable: if config.qml_files: logging.info(f"[DEPLOY] Included QML files: {config.qml_files}") - self.nuitka.create_executable( - source_file=source_file, - extra_args=extra_args, - qml_files=config.qml_files, - dry_run=self.dry_run, - ) + command_str = self.nuitka.create_executable( + source_file=source_file, + extra_args=extra_args, + qml_files=config.qml_files, + dry_run=self.dry_run, + ) + + return command_str |
