MCPcopy Create free account
hub / github.com/carbonengine/trinity / flatten_paths

Function flatten_paths

shadercompiler/pythonBuildScript/build.py:40–53  ·  view source on GitHub ↗
(paths)

Source from the content-addressed store, hash-verified

38
39
40def flatten_paths(paths):
41 for each in paths:
42 path = Path(each)
43 if not path.exists():
44 continue
45 if path.suffix.lower() == '.code-workspace':
46 with path.open() as f:
47 workspace = json.load(f)
48 for folder in workspace.get('folders', []):
49 if 'path' in folder:
50 folder_path = path.parent / folder['path']
51 yield from expand_directories(folder_path)
52 else:
53 yield from expand_directories(each)
54
55
56def get_output_file(path, sm, platform):

Callers 1

buildFunction · 0.85

Calls 2

expand_directoriesFunction · 0.85
getMethod · 0.80

Tested by

no test coverage detected