Skip to content

Commit

Permalink
feature: build.py now allows for space separated lists of files.
Browse files Browse the repository at this point in the history
this is a stepping stone to going to a full Makefile build system. All
src files can be provided in the make and sent to build.py with minimal
issues now that we don't have to build a comma separated list.
  • Loading branch information
awschult002 authored and RobLoach committed Nov 17, 2024
1 parent 01d7828 commit 5eea89c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ def print_help():
"""usage: python single_header_packer.py --macro <macro> [--intro <files>] --extern <files> --pub <files> --priv1 <files> --priv2 <files> [--outro <files>]
where <files> can be a comma-separated list of files. e.g. --priv *.c,inc/*.h
or a space separated list encapsulated in quotes. e.g. --priv1 "file.c file2.c file3.c"
The 'extern' files are placed between 'priv1' and 'priv2'.
Expand All @@ -33,7 +34,8 @@ def print_help():

def parse_files(arg):
files = []
paths = arg.split(",")
paths = re.split(r'[,\s]', arg)

for path in paths:
if "*" in path:
# Wildcard
Expand Down

0 comments on commit 5eea89c

Please sign in to comment.