From d01f135a0442a6805d610ad0653a57c5e523903a Mon Sep 17 00:00:00 2001 From: Peter Date: Fri, 24 Nov 2023 02:48:21 +0000 Subject: [PATCH] Add clearer Go-binding instructions --- src/Overview-for-Developers.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/Overview-for-Developers.md b/src/Overview-for-Developers.md index 8419638..b97b7c0 100644 --- a/src/Overview-for-Developers.md +++ b/src/Overview-for-Developers.md @@ -33,8 +33,11 @@ Communication (calling functions) between Flutter to golang occurs via [this bri 5. [Add the endpoint to the binding package](https://github.com/breez/breez/blob/master/bindings/api.go) #### Define the caller in Breez Mobile (flutter): -1. Compile the protobuf files in Flutter: `protoc --dart_out=grpc:lib/services/breezlib/data/ -I` -2. [Add the function in breez_bridge.dart](https://github.com/breez/breezmobile/blob/master/lib/services/breezlib/breez_bridge.dart) +1. Use protoc_plugin v20.0.1: `dart pub global activate protoc_plugin v20.0.1` +2. [Create a symbol link:](https://github.com/breez/breezmobile/blob/master/lib/services/breezlib/protobuf/README.md) `ln -s lib/services/breezlib/protobuf/messages.proto` +3. [Compile the protobuf files in Flutter:](https://github.com/breez/breezmobile/blob/master/lib/services/breezlib/breez_bridge.dart#L22) `protoc --dart_out=grpc:lib/services/breezlib/data/ -Ilib/services/breezlib/protobuf/ lib/services/breezlib/protobuf/messages.proto` +4. [Add the function in breez_bridge.dart](https://github.com/breez/breezmobile/blob/master/lib/services/breezlib/breez_bridge.dart) +5. [Add the function in NativeMethods.swift](https://github.com/breez/breezmobile/blob/master/ios/Plugins/Breez/BreezLib/NativeMethods.swift#L20) ### Your Development Environment We recommend you [setup a simnet environment](Running-Breez-in-simnet.md) before testing your code on mainnet.