Skip to content

Commit b19931a

Browse files
committed
ci(stm32variant): delete folder with no ldscript
Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
1 parent 575baf5 commit b19931a

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

CI/update/stm32variant.py

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2381,14 +2381,20 @@ def aggregate_dir():
23812381
dir_str = "Directories" if nb_old > 1 else "Directory"
23822382
print(f"\n{dir_str} not updated for {mcu_family.name}:\n")
23832383
for d in old_dirs:
2384-
print(f" - {d.name}")
2384+
# Check if ldsript.ld file exists in the folder
2385+
if not (d / "ldscript.ld").exists():
2386+
deleteFolder(d)
2387+
print(f" - {d.name} (deleted)")
2388+
else:
2389+
print(f" - {d.name}")
23852390
print(
23862391
"""
2387-
--> Please, check if it is due to directory name update (renamed), if true then:
2392+
--> For each directory not deleted, it requires manual update as it was renamed:
2393+
- Find new directory name.
23882394
- Move custom boards definition files, if any.
2389-
- Move linker script(s), if any.
2395+
- Move linker script(s).
23902396
- Copy 'SystemClock_Config(void)' function to the new generic clock config file.
2391-
--> Then remove it, update old path in boards.txt
2397+
--> Then remove it and update old path in boards.txt
23922398
(for custom board(s) as well as generic ones).
23932399
"""
23942400
)

0 commit comments

Comments
 (0)