commit
a556840f9b
|
@ -5,7 +5,7 @@ package structure
|
|||
|
||||
const (
|
||||
DEFAULT_KEY = iota
|
||||
{% for key in keys -%}
|
||||
{% for key in keys %}
|
||||
{{key}}
|
||||
{%- endfor %}
|
||||
)
|
||||
|
|
|
@ -10,10 +10,6 @@ import (
|
|||
"gitee.com/timedb/wheatCache/pkg/proto"
|
||||
"gitee.com/timedb/wheatCache/pkg/structure"
|
||||
|
||||
{% for name in mod_name %}
|
||||
"gitee.com/timedb/wheatCache/pkg/structure/{{name}}"
|
||||
{% endfor %}
|
||||
|
||||
"time"
|
||||
)
|
||||
|
||||
|
|
|
@ -40,6 +40,7 @@ def mk_structure(cfg_camel):
|
|||
file.write('syntax = "proto3";\nimport "base.proto";\noption go_package = "pkg/proto";\n')
|
||||
for v in value:
|
||||
file.write('\nmessage ' + v + 'Request ' + '{\n BaseKey key = 1;\n}\n')
|
||||
file.write('\nmessage ' + v + 'Response ' + '{\n int64 update_size = 1;\n}\n')
|
||||
file.close()
|
||||
|
||||
else: # 如果这个文件存在
|
||||
|
|
Loading…
Reference in New Issue