forked from etcd-io/etcd
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: ensure the generated code is up-to-date
See etcd-io#14612 (comment) Signed-off-by: spacewander <spacewanderlzx@gmail.com>
- Loading branch information
1 parent
a1018db
commit a7f4c3d
Showing
7 changed files
with
230 additions
and
198 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#!/usr/bin/env bash | ||
# This scripts is automatically run by CI to prevent pull requests missing running genproto.sh | ||
# after changing *.proto file. | ||
|
||
set -o errexit | ||
set -o nounset | ||
set -o pipefail | ||
|
||
./scripts/genproto.sh | ||
diff=$(git diff --name-only | grep -c ".pb.") | ||
if [ "$diff" -eq 0 ]; then | ||
echo "PASSED genproto-verification!" | ||
exit 0 | ||
fi | ||
echo "Failed genproto-verification!" >&2 | ||
echo "* Found changed files $(git diff --name-only | grep '.pb.')" >&2 | ||
echo "* Please rerun genproto.sh after changing *.proto file" >&2 | ||
echo "* Run ./scripts/genproto.sh" >&2 | ||
exit 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.