mirror of https://gitee.com/bigwinds/arangodb
Added readme for creating the documentation and changed printout of the makefile
This commit is contained in:
parent
9716a482cd
commit
fd2c22c435
|
@ -13,7 +13,6 @@ def walk_on_files(dirpath):
|
|||
else:
|
||||
full_path= os.path.join(root, file)
|
||||
f=open(full_path,"rU")
|
||||
print "checking file: " + full_path + file
|
||||
textFile=f.read()
|
||||
f.close()
|
||||
findStartCode(textFile,full_path)
|
||||
|
@ -93,9 +92,9 @@ def replaceCodeIndex(pathOfFile):
|
|||
f.write(lines)
|
||||
f.close()
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
path = ["Documentation/Books/Users"]
|
||||
for i in path:
|
||||
dirpath = os.path.abspath(os.path.join(os.path.dirname( __file__ ), os.pardir,"ArangoDB/../../"+i))
|
||||
path = ["Documentation/Books/Users"]
|
||||
for i in path:
|
||||
dirpath = os.path.abspath(os.path.join(os.path.dirname( __file__ ), os.pardir,"ArangoDB/../../"+i))
|
||||
print "Replacing docublocks with content..."
|
||||
walk_on_files(dirpath)
|
|
@ -196,9 +196,6 @@ if __name__ == "__main__":
|
|||
"js/actions","js/client","js/apps/databases","js/apps/system/cerberus","js/apps/system/gharial","js/common","js/server"]
|
||||
for i in path:
|
||||
dirpath = os.path.abspath(os.path.join(os.path.dirname( __file__ ), os.pardir,"ArangoDB/../../"+i))
|
||||
print "Reading" + i
|
||||
fetch_comments(dirpath)
|
||||
|
||||
|
||||
os.path.abspath(os.path.join(os.path.dirname( __file__ ), '..', 'templates'))
|
||||
|
||||
print "Searching for docublocks in " + i
|
||||
os.path.abspath(os.path.join(os.path.dirname( __file__ ), '..', 'templates'))
|
|
@ -6,17 +6,8 @@ def walk_on_files(dirpath):
|
|||
for root, dirs, files in os.walk(dirpath):
|
||||
for file in files:
|
||||
if file.endswith(".html"):
|
||||
if file == "SUMMARY.md":
|
||||
pass
|
||||
elif file == "Index.md":
|
||||
pass
|
||||
else:
|
||||
full_path= os.path.join(root, file)
|
||||
f=open(full_path,"rU")
|
||||
print "checking file: " + full_path
|
||||
textFile=f.read()
|
||||
f.close()
|
||||
replaceCode(full_path)
|
||||
full_path= os.path.join(root, file)
|
||||
replaceCode(full_path)
|
||||
return
|
||||
|
||||
def replaceCode(pathOfFile):
|
||||
|
@ -25,22 +16,23 @@ def replaceCode(pathOfFile):
|
|||
s=f.read()
|
||||
f.close()
|
||||
f=open(pathOfFile,'w')
|
||||
lines = s.replace("<a href=\"../Blueprint-Graphs/README.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../Blueprint-Graphs/README.html\">")
|
||||
lines = lines.replace("<a href=\"../Blueprint-Graphs/VertexMethods.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../Blueprint-Graphs/VertexMethods.html\">")
|
||||
lines = lines.replace("<a href=\"../Blueprint-Graphs/GraphConstructor.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../Blueprint-Graphs/GraphConstructor.html\">")
|
||||
lines = lines.replace("<a href=\"../Blueprint-Graphs/EdgeMethods.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../Blueprint-Graphs/EdgeMethods.html\">")
|
||||
lines = lines.replace("<a href=\"../HttpGraphs/README.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../HttpGraphs/README.html\">")
|
||||
lines = lines.replace("<a href=\"../HttpGraphs/Vertex.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../HttpGraphs/Vertex.html\">")
|
||||
lines = lines.replace("<a href=\"../HttpGraphs/Edge.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../HttpGraphs/Edge.html\">")
|
||||
lines = lines.replace("<a href=\"../ModuleGraph/README.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../ModuleGraph/README.html\">")
|
||||
lines = lines.replace("<a href=\"../ModuleGraph/GraphConstructor.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../ModuleGraph/GraphConstructor.html\">")
|
||||
lines = lines.replace("<a href=\"../ModuleGraph/VertexMethods.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../ModuleGraph/VertexMethods.html\">")
|
||||
lines = lines.replace("<a href=\"../ModuleGraph/EdgeMethods.html\">","<a class=\"fa fa-exclamation-triangle\"href=\"../ModuleGraph/EdgeMethods.html\">")
|
||||
lines = s.replace("<a href=\"../Blueprint-Graphs/README.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../Blueprint-Graphs/README.html\">")
|
||||
lines = lines.replace("<a href=\"../Blueprint-Graphs/VertexMethods.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../Blueprint-Graphs/VertexMethods.html\">")
|
||||
lines = lines.replace("<a href=\"../Blueprint-Graphs/GraphConstructor.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../Blueprint-Graphs/GraphConstructor.html\">")
|
||||
lines = lines.replace("<a href=\"../Blueprint-Graphs/EdgeMethods.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../Blueprint-Graphs/EdgeMethods.html\">")
|
||||
lines = lines.replace("<a href=\"../HttpGraphs/README.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../HttpGraphs/README.html\">")
|
||||
lines = lines.replace("<a href=\"../HttpGraphs/Vertex.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../HttpGraphs/Vertex.html\">")
|
||||
lines = lines.replace("<a href=\"../HttpGraphs/Edge.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../HttpGraphs/Edge.html\">")
|
||||
lines = lines.replace("<a href=\"../ModuleGraph/README.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../ModuleGraph/README.html\">")
|
||||
lines = lines.replace("<a href=\"../ModuleGraph/GraphConstructor.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../ModuleGraph/GraphConstructor.html\">")
|
||||
lines = lines.replace("<a href=\"../ModuleGraph/VertexMethods.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../ModuleGraph/VertexMethods.html\">")
|
||||
lines = lines.replace("<a href=\"../ModuleGraph/EdgeMethods.html\">","<a class=\"fa fa-exclamation-triangle\" style=\"color:rgba(240,210,0,1)\" href=\"../ModuleGraph/EdgeMethods.html\">")
|
||||
f.write(lines)
|
||||
f.close()
|
||||
|
||||
if __name__ == '__main__':
|
||||
path = ["Documentation/Books/books/Users"]
|
||||
for i in path:
|
||||
dirpath = os.path.abspath(os.path.join(os.path.dirname( __file__ ), os.pardir,"ArangoDB/../../"+i))
|
||||
path = ["Documentation/Books/books/Users"]
|
||||
for i in path:
|
||||
dirpath = os.path.abspath(os.path.join(os.path.dirname( __file__ ), os.pardir,"ArangoDB/../../"+i))
|
||||
print "Tagging deprecated files"
|
||||
walk_on_files(dirpath)
|
|
@ -0,0 +1,5 @@
|
|||
How to generate the documentation:
|
||||
|
||||
1. Install markdown-pp from our repository (https://github.com/triAGENS/markdown-pp)
|
||||
2. Install gitbook (https://github.com/GitbookIO/gitbook)
|
||||
3. Run "make" in this folder
|
Loading…
Reference in New Issue