3 from __future__ import print_function
9 toppath = os.path.dirname(__file__)
11 # do not blindly scan this directory, as when using devel tools
12 # like `make sync` we can easily end up with more files than needed
13 # which breaks in production
16 ('.', '[A-Z][a-zA-Z]*.py'),
17 ('system', '[a-zA-Z]*.py'),
20 for dir, pattern in contents:
21 matches = glob.glob("{}/{}/{}".format(toppath, dir, pattern))
23 prefix = len(toppath) + 1 + len(dir) + 1
25 filename = match[prefix:][:-3]
26 python_name = filename if dir == '.' \
27 else "{}.{}".format(dir, filename)
28 native_methods.append(python_name)
30 if __name__ == '__main__':