From a7efeb7e32e4a4e46ba136c212ecd6bd391a3f8d Mon Sep 17 00:00:00 2001
From: thibault allenet <thibault.allenet@cea.fr>
Date: Fri, 13 Dec 2024 15:20:31 +0000
Subject: [PATCH] Update export.py to include new F7 board, fix a typo & remove
 unecessary copy tree

---
 aidge_export_arm_cortexm/export.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/aidge_export_arm_cortexm/export.py b/aidge_export_arm_cortexm/export.py
index d1f6595..cd1b205 100644
--- a/aidge_export_arm_cortexm/export.py
+++ b/aidge_export_arm_cortexm/export.py
@@ -13,6 +13,7 @@ BOARD_PATH : str = ROOT / "boards"
 
 BOARDS_MAP: dict[str, Path] = {
     "stm32h7" : BOARD_PATH / "stm32" / "H7",
+    "stm32f7" : BOARD_PATH / "stm32" / "F7",
 }
 
 def export(export_folder_name,
@@ -37,7 +38,7 @@ def supported_boards() -> list[str]:
 
 def gen_board_files(path:str, board:str)->None:
     if board not in supported_boards():
-        raise ValueError(f"Board {board} is not supported, supported board are:\n\t-{'\n\t-'.join(supported_boards())}")
+        raise ValueError(f"Board {board} is not supported, supported board are:{supported_boards()}")
 
     if isinstance(path, str): path = Path(path)
     # Create dnn directory is not exist
@@ -51,5 +52,4 @@ def gen_board_files(path:str, board:str)->None:
     shutil.copytree(BOARDS_MAP[board], str(path), dirs_exist_ok=True)
     # For N2D2 library, copy static folder to export/include
     dnn_include_folder = dnn_folder / "include"
-    os.makedirs(str(dnn_include_folder), exist_ok=True)
-    shutil.copytree(str(ROOT / "_N2D2" / "static"), str(dnn_include_folder), dirs_exist_ok=True)
+    os.makedirs(str(dnn_include_folder), exist_ok=True)
\ No newline at end of file
-- 
GitLab