Skip to content

Commit df18dfb

Browse files
committed
lib_build: exclude file from example
1 parent 15249bb commit df18dfb

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

build_as_lib.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,11 @@
5858
example_name = item[1]
5959
src_filter.append(f"+<../examples/{example_name}>")
6060

61+
# EXCLUDE A SOURCE FILE FROM AN EXAMPLE (must be placed after example name or boom)
62+
elif isinstance(item, tuple) and item[0] == "EXCLUDE_FROM_EXAMPLE":
63+
exclude_name = item[1]
64+
src_filter.append(f"-<../examples/{example_name}/{exclude_name}>")
65+
6166
menv.Replace(SRC_FILTER=src_filter)
6267

6368
#print (menv.Dump())

0 commit comments

Comments
 (0)