mirror of
https://github.com/tldr-pages/tldr.git
synced 2025-04-22 01:22:09 +02:00
protoc: add Chinese translation (#9313)
This commit is contained in:
parent
38f9331440
commit
ef8d207a06
1 changed files with 16 additions and 0 deletions
16
pages.zh/common/protoc.md
Normal file
16
pages.zh/common/protoc.md
Normal file
|
@ -0,0 +1,16 @@
|
|||
# protoc
|
||||
|
||||
> 解析 Google Protobuf `.proto` 文件并生成指定语言的输出。
|
||||
> 更多信息:<https://developers.google.com/protocol-buffers>.
|
||||
|
||||
- 从 `.proto` 文件生成 Python 代码:
|
||||
|
||||
`protoc --python_out={{路径/到/输出目录}} {{输入文件.proto}}`
|
||||
|
||||
- 从一个导入其他 `.proto` 文件的 `.proto` 文件生成 Java 代码:
|
||||
|
||||
`protoc --java_out={{路径/到/输出目录}} --proto_path={{路径/到/导入搜索路径}} {{输入文件.proto}}`
|
||||
|
||||
- 生成多种语言的代码:
|
||||
|
||||
`protoc --csharp_out={{路径/到/c#_输出目录}} --js_out={{路径/到/js_输出目录}} {{输入文件.proto}}`
|
Loading…
Add table
Reference in a new issue