MCPcopy Create free account
hub / github.com/danvk/webdiff / determine_path

Function determine_path

webdiff/app.py:33–43  ·  view source on GitHub ↗

Borrowed from wxglade.py

()

Source from the content-addressed store, hash-verified

31
32
33def determine_path():
34 """Borrowed from wxglade.py"""
35 try:
36 root = __file__
37 if os.path.islink(root):
38 root = os.path.realpath(root)
39 return os.path.dirname(os.path.abspath(root))
40 except Exception as e:
41 print(f"I'm sorry, but something is wrong. Error: {e}")
42 print('There is no __file__ variable. Please contact the author.')
43 sys.exit()
44
45
46GIT_CONFIG = {}

Callers 1

app.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected