Skip to content

Commit bd99f12

Browse files
committed
[stm32variant] Add option to generate only one family
Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
1 parent 0c72de2 commit bd99f12

File tree

1 file changed

+13
-2
lines changed

1 file changed

+13
-2
lines changed

CI/utils/stm32variant.py

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1696,6 +1696,13 @@ def manage_repo():
16961696
),
16971697
)
16981698

1699+
group.add_argument(
1700+
"-f",
1701+
"--family",
1702+
metavar="name",
1703+
help="Generate all files for specified mcu family.",
1704+
)
1705+
16991706
parser.add_argument(
17001707
"-c",
17011708
"--cube",
@@ -1775,11 +1782,15 @@ def manage_repo():
17751782
)
17761783

17771784
for mcu_file in mcu_list:
1778-
print("Generating files for '{}'...".format(mcu_file.name))
1779-
17801785
# Open input file
17811786
xml_mcu = parse(str(mcu_file))
17821787
parse_mcu_file()
1788+
# Generate only for one family
1789+
if args.family and args.family.upper() not in mcu_family:
1790+
xml_mcu.unlink()
1791+
continue
1792+
1793+
print("Generating files for '{}'...".format(mcu_file.name))
17831794
if not gpiofile:
17841795
print("Could not find GPIO file")
17851796
quit()

0 commit comments

Comments
 (0)