(filepath: str)
| 10 | |
| 11 | |
| 12 | def find_in_python_root(filepath: str): |
| 13 | filefullpath = "" |
| 14 | found = False |
| 15 | for package_root in site.getsitepackages(): |
| 16 | # Find the path of the real executable. |
| 17 | filefullpath = os.path.join(package_root, filepath) |
| 18 | |
| 19 | if os.path.exists(filefullpath): |
| 20 | found = True |
| 21 | return found, filefullpath |
| 22 | |
| 23 | return found, "" |
| 24 | |
| 25 | |
| 26 | def exec_cmd(cmd: str, args): |