Skip to content

Commit 40e8725

Browse files
Documentation generated automatically from .proto files 🔥 (#172)
1 parent fb5a760 commit 40e8725

File tree

3 files changed

+1613
-0
lines changed

3 files changed

+1613
-0
lines changed

‎devops/generate_proto_files.py‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,15 @@ def update_java():
8484
shutil.rmtree(join(java_proto_path, 'trinsic', 'okapi'))
8585

8686

87+
def update_markdown():
88+
lang_path = get_language_dir('docs')
89+
lang_proto_path = join(lang_path, 'reference', 'proto')
90+
# https://github.com/pseudomuto/protoc-gen-doc
91+
# go get -u github.com/pseudomuto/protoc-gen-doc/cmd/protoc-gen-doc
92+
# Add to path and rename to `protoc-gen-grpc-java`
93+
run_protoc({'doc_out': lang_proto_path}, {'doc_opt': 'markdown,index.md'}, get_proto_files())
94+
95+
8796
def update_python():
8897
"""
8998
Generate the protobuf interface files using the python library https://github.com/danielgtaylor/python-betterproto
@@ -111,6 +120,7 @@ def main():
111120
update_ruby()
112121
update_java()
113122
update_python()
123+
update_markdown()
114124

115125

116126
if __name__ == "__main__":

0 commit comments

Comments
 (0)