mirror of
https://github.com/meshtastic/Meshtastic-Apple.git
synced 2026-04-20 22:13:56 +00:00
Fix proto generation script
This commit is contained in:
parent
76847d9db3
commit
73bf7d1283
1 changed files with 11 additions and 0 deletions
|
|
@ -12,8 +12,17 @@ if [ ! -x "`which protoc`" ]; then
|
|||
exit
|
||||
fi
|
||||
|
||||
if [ ! -x "`which gsed`" ]; then
|
||||
echo "Please install gnu-sed by running: brew install gnu-sed"
|
||||
exit
|
||||
fi
|
||||
|
||||
pdir=$(realpath "../protobufs/meshtastic")
|
||||
sdir=$(realpath "./Meshtastic/Protobufs")
|
||||
|
||||
gsed -i 's/import "meshtastic\//import "/g' ../protobufs/meshtastic/*
|
||||
gsed -i 's/package meshtastic;//g' ../protobufs/meshtastic/*
|
||||
|
||||
echo "pdir:$pdir sdir:$sdir"
|
||||
pfiles="admin.proto apponly.proto cannedmessages.proto channel.proto config.proto device_metadata.proto deviceonly.proto localonly.proto mesh.proto module_config.proto mqtt.proto portnums.proto remote_hardware.proto rtttl.proto storeforward.proto telemetry.proto xmodem.proto"
|
||||
for pf in $pfiles
|
||||
|
|
@ -24,3 +33,5 @@ do
|
|||
done
|
||||
echo "Done generating the swift files from the proto files."
|
||||
echo "Build, test, and commit changes."
|
||||
|
||||
cd ../protobufs/meshtastic && git reset --hard
|
||||
Loading…
Add table
Add a link
Reference in a new issue