source: sasmodels/doc/genmodel.py @ d1fe925

gh-pages
Last change on this file since d1fe925 was d1fe925, checked in by ajj, 8 years ago

Creating gh_pages branch for docs

  • Property mode set to 100644
File size: 487 bytes
Line 
1import sys
2import os
3sys.path.insert(0,'..')
4
5# Convert ../sasmodels/models/name.py to sasmodels.models.name
6module_name = sys.argv[1][3:-3].replace('/','.').replace('\\','.')
7print module_name
8module = __import__(module_name)
9for part in module_name.split('.')[1:]:
10    module = getattr(module, part)
11print module
12
13# Load the doc string from the module definition file and store it in rst
14from sasmodels import generate
15docstr = generate.doc(module)
16open(sys.argv[2],'w').write(docstr)
Note: See TracBrowser for help on using the repository browser.