Skip to content

Instantly share code, notes, and snippets.

@Bidski
Created September 10, 2019 00:36
Show Gist options
  • Save Bidski/a27a6f1a2823f09e8ced9c3d96a0f2f0 to your computer and use it in GitHub Desktop.
Save Bidski/a27a6f1a2823f09e8ced9c3d96a0f2f0 to your computer and use it in GitHub Desktop.
Only copy data files for a specific host/platform
# Get list of data files
# Only get data files that are for the current target
regex = re.compile(
r"([a-zA-Z_/-]+)(config|scripts)(/(nu|i)gus({})?)?/([a-zA-Z]+\.yaml)".format(target.split(".")[3])
)
data_files = [
data_file.group(0)
for data_file in [regex.match(data_file) for data_file in b.cmake_cache["NUCLEAR_MODULE_DATA_FILES"]]
if data_file is not None
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment