summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtools/protobuf/compile.sh10
-rwxr-xr-xtools/protobuf/format.sh3
2 files changed, 13 insertions, 0 deletions
diff --git a/tools/protobuf/compile.sh b/tools/protobuf/compile.sh
new file mode 100755
index 0000000..f669fe0
--- /dev/null
+++ b/tools/protobuf/compile.sh
@@ -0,0 +1,10 @@
+#!/usr/bin/env sh
+DEPS=$(find api -type f -name "*.proto")
+protoc --proto_path=./ \
+ --proto_path=third_party/googleapis \
+ --proto_path=third_party/grpc-proto \
+ --go_out=. \
+ --go_opt=paths=source_relative \
+ --go-grpc_out=. \
+ --go-grpc_opt=paths=source_relative \
+ "$DEPS" \ No newline at end of file
diff --git a/tools/protobuf/format.sh b/tools/protobuf/format.sh
new file mode 100755
index 0000000..11c9164
--- /dev/null
+++ b/tools/protobuf/format.sh
@@ -0,0 +1,3 @@
+#!/usr/bin/env sh
+DEPS=$(find api -type f -name "*.proto")
+clang-format -i --sort-includes "$DEPS" \ No newline at end of file