Skip to content

Commit

Permalink
Modify script to split docs
Browse files Browse the repository at this point in the history
  • Loading branch information
alexpeters1208 committed Sep 6, 2024
1 parent 22ecc44 commit 4e16aa4
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion proto/proto-backplane-grpc/docs/generate_docs.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
#!/bin/bash

protoc -I/usr/include -I/protos --doc_out=/out `find /protos/ -name \*.proto`
# Find all .proto files in the /protos directory
for proto_file in `find /protos/ -name \*.proto`; do
# Extract the base name of the .proto file (e.g., myfile.proto -> myfile)
base_name=$(basename "$proto_file" .proto)

# Generate documentation for each .proto file
protoc \
-I/usr/include -I/protos \
--doc_out=/out --doc_opt=markdown,"${base_name}.md" \
"$proto_file"
done

0 comments on commit 4e16aa4

Please sign in to comment.