wrenpp/subprojects/packagefiles/wren/find_scripts.py

18 lines
407 B
Python
Raw Permalink Normal View History

#!/usr/bin/env python
from pathlib import Path
import sys
import os
if len(sys.argv) < 3:
sys.stderr.write("Usage: {0} <prefix> <paths>...\n".format(sys.argv[0]))
exit(2)
prefix = sys.argv[1]
search_paths = sys.argv[2:]
for search_path in search_paths:
curr_path = os.path.join(prefix, search_path)
for path in Path(curr_path).rglob('*.wren'):
sys.stdout.write(str(path) + "\n")