1
2
3
4
5 from os import path as os_path
6 from sys import path as sys_path
7
8 from pkgutil import extend_path
9
10 __extended_path = "/data/users/imcmahon/dev/baxter_xenial/src/intera_sdk/intera_interface/src".split(";")
11 for p in reversed(__extended_path):
12 sys_path.insert(0, p)
13 del p
14 del sys_path
15
16 __path__ = extend_path(__path__, __name__)
17 del extend_path
18
19 __execfiles = []
20 for p in __extended_path:
21 src_init_file = os_path.join(p, __name__ + '.py')
22 if os_path.isfile(src_init_file):
23 __execfiles.append(src_init_file)
24 else:
25 src_init_file = os_path.join(p, __name__, '__init__.py')
26 if os_path.isfile(src_init_file):
27 __execfiles.append(src_init_file)
28 del src_init_file
29 del p
30 del os_path
31 del __extended_path
32
33 for __execfile in __execfiles:
34 with open(__execfile, 'r') as __fh:
35 exec(__fh.read())
36 del __fh
37 del __execfile
38 del __execfiles
39