diff options
| author | Oskari Timperi <oskari.timperi@iki.fi> | 2018-04-04 19:45:54 +0300 |
|---|---|---|
| committer | Oskari Timperi <oskari.timperi@iki.fi> | 2018-04-04 19:45:54 +0300 |
| commit | d2899bd3ddc878f778a77da85ad07ae32e71b05f (patch) | |
| tree | aac3c9ffcb42577a07d5b1a4b20ad0979a514f7a | |
| parent | 8ec494de47647016f5b60baf952a25b529a17077 (diff) | |
| download | nimpb-d2899bd3ddc878f778a77da85ad07ae32e71b05f.tar.gz nimpb-d2899bd3ddc878f778a77da85ad07ae32e71b05f.zip | |
Update generator README
| -rw-r--r-- | generator/README.md | 10 |
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. |
