-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Enhancement] Gen KCL schema from protobuf message #302
Comments
实现的一个小demo:https://github.com/XiaoK29/proto2schema |
I think there is no problem with implementing the logic. It would be great if we could integrate the existing kcl go code/interfaces and templates. 👍 |
好的 |
解析是通过pkg/tools/gen/genkcl.go中的GenKclOptions struct来配置的,有个ParseFromTag的字段,proto没有tag这个概念,这个使用proto中的json_name的tag吗? |
You can ignore this option. |
* ✨ feat: proto to kcl_schema Signed-off-by: xiaok29 <1526783667@qq.com> * fix:add bool float type Signed-off-by: xiaok29 <1526783667@qq.com> * fix:line breaks on different platforms Signed-off-by: xiaok29 <1526783667@qq.com> * fix:line breaks on different platforms Signed-off-by: xiaok29 <1526783667@qq.com> * perf:use writeString splicing Signed-off-by: xiaok29 <1526783667@qq.com> * Update pkg/tools/gen/genkcl_proto.go Co-authored-by: Peefy <xpf6677@163.com> Signed-off-by: xiaok29 <1526783667@qq.com> * feat:read enum type Signed-off-by: xiaok29 <1526783667@qq.com> --------- Signed-off-by: xiaok29 <1526783667@qq.com> Co-authored-by: Peefy <xpf6677@163.com>
* ✨ feat: proto to kcl_schema Signed-off-by: xiaok29 <1526783667@qq.com> * fix:add bool float type Signed-off-by: xiaok29 <1526783667@qq.com> * fix:line breaks on different platforms Signed-off-by: xiaok29 <1526783667@qq.com> * fix:line breaks on different platforms Signed-off-by: xiaok29 <1526783667@qq.com> * perf:use writeString splicing Signed-off-by: xiaok29 <1526783667@qq.com> * Update pkg/tools/gen/genkcl_proto.go Co-authored-by: Peefy <xpf6677@163.com> Signed-off-by: xiaok29 <1526783667@qq.com> * feat:read enum type Signed-off-by: xiaok29 <1526783667@qq.com> --------- Signed-off-by: xiaok29 <1526783667@qq.com> Co-authored-by: Peefy <xpf6677@163.com>
Enhancement
We want to add protobuf message import for the kcl import tool like jsonschema, openapi and terraform provider schema.
Reference
Features
The text was updated successfully, but these errors were encountered: