MCPcopy Create free account
hub / github.com/bfbbdecomp/bfbb / import_h_file

Function import_h_file

tools/decompctx.py:31–41  ·  view source on GitHub ↗
(in_file: str, r_path: str)

Source from the content-addressed store, hash-verified

29
30
31def import_h_file(in_file: str, r_path: str) -> str:
32 rel_path = os.path.join(root_dir, r_path, in_file)
33 if os.path.exists(rel_path):
34 return import_c_file(rel_path)
35 for include_dir in include_dirs:
36 inc_path = os.path.join(include_dir, in_file)
37 if os.path.exists(inc_path):
38 return import_c_file(inc_path)
39 else:
40 print("Failed to locate", in_file)
41 return ""
42
43
44def import_c_file(in_file: str) -> str:

Callers 1

process_fileFunction · 0.85

Calls 2

import_c_fileFunction · 0.85
existsMethod · 0.80

Tested by

no test coverage detected