From 478d578a6c4384c684b2706f143d43af0d8e201c Mon Sep 17 00:00:00 2001 From: ghubstan <36207203+ghubstan@users.noreply.github.com> Date: Sat, 19 Mar 2022 13:51:49 -0300 Subject: [PATCH] Make Python examples in one step: run-setup.py --- proto-downloader/download-bisq-protos.sh | 4 ++-- python-examples/run-setup.sh | 8 +++++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/proto-downloader/download-bisq-protos.sh b/proto-downloader/download-bisq-protos.sh index 7acedce..064a2dd 100755 --- a/proto-downloader/download-bisq-protos.sh +++ b/proto-downloader/download-bisq-protos.sh @@ -1,7 +1,7 @@ #!/bin/bash -echo "Downloading Bisq protobuf files from github to $PROTO_PATH directory." -echo "You may want to skip this step and copy your own local .proto files instead." +echo "Downloading Bisq protobuf files from github to $PROTO_PATH directory..." +echo "You can skip this step and copy your own local .proto files instead." # Download the Bisq master branch's protobuf definition files. curl -o ./pb.proto https://raw.githubusercontent.com/bisq-network/bisq/master/proto/src/main/proto/pb.proto diff --git a/python-examples/run-setup.sh b/python-examples/run-setup.sh index 0b8e9ba..20c5c0d 100755 --- a/python-examples/run-setup.sh +++ b/python-examples/run-setup.sh @@ -3,11 +3,17 @@ # This script must be run from this directory. # Install python3-venv if necessary. +# For systems using the apt package manager, uncomment the line below, or install the equivalent package for your system. # sudo apt install python3-venv -# Install Python setuptools if necessary. +# Install pip, then Python setuptools if necessary. # pip install setuptools +# Download the Bisq protobuf definition files from the Bisq repository. +cd ../proto-downloader +./download-bisq-protos.sh +cd ../python-examples + # Generate gRPC Python protobuf classes. You can download them from the # Bisq repo with the proto-downloader/download-bisq-protos.sh script. echo "Generating gRPC Python service stubs..."