Skip to content

Commit

Permalink
Fancy little emoji upgrade to the fqpn script
Browse files Browse the repository at this point in the history
  • Loading branch information
Noctunus committed Sep 24, 2024
1 parent e4c4eb3 commit 3006216
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions scripts/fqpn_check.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
#!/bin/bash

echo -e "🔍 Checking if all the types used in the proto files are using a FQPN (full qualified package name)"

grep --include="*.proto" -r -h -oP "(\S+) (\S+) = \d+;" proto/ | cut -d" " -f1 | sort -u | grep -v "google\.protobuf" | grep -v "cmp\." | grep -vP "(double|float|int32|int64|uint32|uint64|sint32|sint64|fixed32|fixed64|sfixed32|sfixed64|bool|string|bytes|//)"

if [ $? != 1 ] ; then
echo "Error: Found non FQPN types!"
echo "Error: Found non FQPN types! See above."
exit 1
fi

echo "Success: All types should be FQPN"
echo "Success: All types should be FQPN"

0 comments on commit 3006216

Please sign in to comment.