Skip to content

Commit 83359a9

Browse files
authored
Merge pull request #497 from meshtastic/revert-490-master
Revert "Move pb2 Files to Own Folder"
2 parents fdf5944 + 67636c4 commit 83359a9

44 files changed

Lines changed: 589 additions & 598 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

bin/regen-protobufs.sh

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,13 @@
77
./nanopb-0.4.7/generator-bin/protoc -I=protobufs --python_out ./ ./protobufs/meshtastic/*.proto
88

99
# workaround for import bug in protoc https://github.com/protocolbuffers/protobuf/issues/1491#issuecomment-690618628
10-
mv ./meshtastic/*_pb2.py ./meshtastic/PbDefinitions
1110

1211
if [[ $OSTYPE == 'darwin'* ]]; then
13-
sed -i '' -E 's/^(import.*_pb2)/from . \1/' meshtastic/PbDefinitions/*.py
12+
sed -i '' -E 's/^(import.*_pb2)/from . \1/' meshtastic/*.py
1413
# automate the current workaround (may be related to Meshtastic-protobufs issue #27 https://github.com/meshtastic/protobufs/issues/27)
15-
sed -i '' -E "s/^None = 0/globals()['None'] = 0/" meshtastic/PbDefinitions/mesh_pb2.py
16-
# change from meshtastic to meshtastic.PbDefinitions
17-
sed -i -E 's/^from meshtastic(.*_pb2.*)/from meshtastic.PbDefinitions\1/' meshtastic/PbDefinitions/*.py
14+
sed -i '' -E "s/^None = 0/globals()['None'] = 0/" meshtastic/mesh_pb2.py
1815
else
19-
sed -i -e 's/^import.*_pb2/from . \0/' meshtastic/PbDefinitions/*.py
16+
sed -i -e 's/^import.*_pb2/from . \0/' meshtastic/*.py
2017
# automate the current workaround (may be related to Meshtastic-protobufs issue #27 https://github.com/meshtastic/protobufs/issues/27)
21-
sed -i -e "s/^None = 0/globals()['None'] = 0/" meshtastic/PbDefinitions/mesh_pb2.py
22-
# change from meshtastic to meshtastic.PbDefinitions
23-
sed -i -E 's/^from meshtastic(.*_pb2.*)/from meshtastic.PbDefinitions\1/' meshtastic/PbDefinitions/*.py
24-
fi
18+
sed -i -e "s/^None = 0/globals()['None'] = 0/" meshtastic/mesh_pb2.py
19+
fi

meshtastic/PbDefinitions/__init__.py

Whitespace-only changes.

meshtastic/PbDefinitions/admin_pb2.py

Lines changed: 0 additions & 40 deletions
This file was deleted.

meshtastic/PbDefinitions/atak_pb2.py

Lines changed: 0 additions & 40 deletions
This file was deleted.

meshtastic/PbDefinitions/channel_pb2.py

Lines changed: 0 additions & 34 deletions
This file was deleted.

0 commit comments

Comments
 (0)