aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--generator/README.md10
1 files changed, 9 insertions, 1 deletions
diff --git a/generator/README.md b/generator/README.md
index 37a15a8..be99e6f 100644
--- a/generator/README.md
+++ b/generator/README.md
@@ -4,4 +4,12 @@ A protoc plugin for generating Nim code out of .proto files.
# Usage
- protoc --plugin=protoc-gen-nim=./protoc_gen_nim --nim_out=protos -I. my.proto
+If you don't have the directory, where the generator plugin resides, in PATH, you can use
+
+ protoc --plugin=protoc-gen-nim=/path/to/protoc_gen_nim --nim_out=protos -I. my.proto
+
+If the plugin is in PATH (and you're on a unix-ish system) then it's a bit easier
+
+ protoc -I. --nim_out=protos my.proto
+
+The latter style is possible, because there exists a `protoc-gen-nim` wrapper script that calls the real executable. Protoc automatically finds this wrapper based on the `--nim_out` argument.