#!python3
import os, glob, sys
import nustack
import nustack.doc.gen as gen

exportdir = sys.argv[1]

# Get module names
path = os.path.join(os.path.dirname(nustack.__file__), "stdlib")
print("Path to standard library:", path)
os.chdir(path)
modnames = (f[:-3] for f in glob.iglob("*.py") if f != '__init__.py')

for mod in modnames:
    print("Generating docs for %s..." % mod)
    gen.gendoc("nustack.stdlib.%s" % mod, os.path.join(exportdir, mod + ".md"))
print("Done!")

@@ -50,27 +50,8 @@
 ort 
-nustack.doc.gen as 
 gen%0A
@@ -119,24 +119,8 @@
 oin(
-os.path.dirname(
 nust
@@ -129,15 +129,17 @@
 k.__
-file__)
+path__%5B0%5D
 , %22s

Update documentation generator for new directory structure.