make+scripts: fix rpc-check command

This commit is contained in:
Oliver Gugger
2021-07-27 12:59:54 +02:00
parent 4a0025c1b7
commit 36a316e29a
2 changed files with 12 additions and 1 deletions

View File

@@ -0,0 +1,11 @@
#!/bin/bash
for proto in $(find . -name "*.proto"); do
for rpc in $(awk '/ rpc /{print $2}' "$proto"); do
yaml=${proto%%.proto}.yaml
if ! grep -q "$rpc" "$yaml"; then
echo "RPC $rpc not added to $yaml file"
exit 1
fi
done
done