Spaces:
Sleeping
Sleeping
File size: 417 Bytes
6b1e8b6 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | # devggn
import glob
from os.path import basename, dirname, isfile
def __list_all_modules():
mod_paths = glob.glob(dirname(__file__) + "/*.py")
all_modules = [
basename(f)[:-3]
for f in mod_paths
if isfile(f) and f.endswith(".py") and not f.endswith("__init__.py")
]
return all_modules
ALL_MODULES = sorted(__list_all_modules())
__all__ = ALL_MODULES + ["ALL_MODULES"]
|