跳至内容

compile-proto.py 脚本

此脚本将 .proto 文件编译为 Schola 的 Python/C++ 源文件。

用法

终端窗口
usage: compile_proto [-h] [--plugin-folder PLUGIN_FOLDER] [--disable-warnings DISABLE_WARNINGS [DISABLE_WARNINGS ...]] [--add-type-stubs]

可选参数

--plugin-folder

项目文件夹的路径,如果从 Schola 插件目录运行,则可以留空

  • 默认: '.'
  • 类型: 路径
  • 必需:

--disable-warnings

在编译期间要禁用的警告代码列表

  • 默认: ['4125', '4800']
  • 类型: str (允许多个值)
  • 必需:

--add-type-stubs

为编译后的 protobuf 文件生成类型存根

  • 默认: False
  • 必需:
© . This site is unofficial and not affiliated with AMD.