Last change
on this file since 947 was
939,
checked in by toby, 10 years ago
|
fix & cleanup unit tests; add/change doc strings for sphinx; add all G2 py files to sphinx
|
-
Property svn:eol-style set to
native
|
File size:
949 bytes
|
Line | |
---|
1 | '''Find Python files in GSASII that are not referenced in the sphinx documentation |
---|
2 | ''' |
---|
3 | import glob |
---|
4 | import os.path |
---|
5 | import subprocess as sp |
---|
6 | |
---|
7 | # get list of documented files (misses out on data files -- with no functions or classes) |
---|
8 | loc = os.path.split(os.path.realpath(__file__))[0] |
---|
9 | documented = [os.path.splitext(os.path.split(fil)[1])[0] for |
---|
10 | fil in glob.iglob(os.path.join(loc,'build/html/_modules/','*.html'))] |
---|
11 | |
---|
12 | # loop over python files in subversion |
---|
13 | #for fil in glob.iglob(os.path.join(loc,'..','GSAS*.py')): |
---|
14 | proc = sp.Popen(["svn","list",os.path.join(loc,'..')],stdout=sp.PIPE) |
---|
15 | for fil in proc.stdout.readlines(): |
---|
16 | if os.path.splitext(fil.strip())[1] != ".py": continue |
---|
17 | if os.path.splitext(os.path.split(fil)[1])[0] in documented: |
---|
18 | #print 'doc' |
---|
19 | continue |
---|
20 | else: |
---|
21 | print ".. automodule:: "+os.path.splitext(os.path.split(fil)[1])[0] |
---|
22 | print " :members: " |
---|
23 | print "" |
---|
Note: See
TracBrowser
for help on using the repository browser.