From 78a0e25fe5c90db66cfbb50f4150133a15240166 Mon Sep 17 00:00:00 2001 From: Luke Murphy Date: Sun, 9 Aug 2020 02:52:29 +0200 Subject: [PATCH] Fix example, add TLDR and fixup copy --- README.md | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 4820df4..8e21087 100644 --- a/README.md +++ b/README.md @@ -12,15 +12,19 @@ $ pip install hrpc ## Example +> **TLDR; See the [example](./example/) directory** + Define an RPC service in a `schema.proto`. ```protobuf -message Echo { +syntax = "proto2"; + +message EchoMsg { required string value = 1; } service Example { - rpc Echo (Echo) returns (Echo) {} + rpc Echo (EchoMsg) returns (EchoMsg) {} } ``` @@ -33,7 +37,7 @@ $ hrpc schema.proto This creates `schema_gprc.py` (services) and `schema_pb2.py` (stubs) files. -You can write a simple server and client like so. +You can then write a async-ready server and client like so. ```python # server.py @@ -43,7 +47,7 @@ You can write a simple server and client like so. # client.py ``` -Then run them in separate terminals and see the output. +And run them in separate terminals to see the output. ``` $ python server.py # terminal 1