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