feat: write ui file to qt/ dir on new service creation

This commit is contained in:
Benjamin Labrecque
2026-07-27 08:39:07 +02:00
parent b78ac12a2f
commit ce1ff1148a
4 changed files with 9 additions and 0 deletions
+1
View File
@@ -13,6 +13,7 @@ class Paths(BaseSettings):
repo_root: DirectoryPath = REPO_ROOT
services_dir: DirectoryPath = Path("services")
qt_dir: DirectoryPath = Path("qt")
service_registry_file: FilePath = Path("config/services_registry.yml")
iocs_overview_filename: FilePath = Path("docs/user/ioc/iocs_overview.md")
+8
View File
@@ -17,6 +17,7 @@ logger = logging.getLogger(__name__)
REPO_ROOT = get_git_root(__file__)
SERVICE_TEMPLATES_DIR = REPO_ROOT / "templates" / "service"
QT_TEMPLATES_DIR = REPO_ROOT / "templates" / "qt"
class ServiceCreator:
@@ -88,6 +89,13 @@ class ServiceCreator:
"service_name_lower": service.name_lower,
"service_name_lower_underscores": service.name_lower_underscores,
"user": user,
},
)
copier.run_copy(
src_path=str(QT_TEMPLATES_DIR),
dst_path=str(self.ctx.write_paths.qt_dir),
data={
"service_name_upper": service.name_upper,
"ui_filename": ui_filename,
},
)