diff --git a/middleware/config/middle.gen.go b/plugins/config/middle.gen.go similarity index 66% rename from middleware/config/middle.gen.go rename to plugins/config/middle.gen.go index 10bc962..cb9323d 100644 --- a/middleware/config/middle.gen.go +++ b/plugins/config/middle.gen.go @@ -4,9 +4,10 @@ package config import ( - "gitee.com/timedb/wheatCache/middleware" - logMiddle "gitee.com/timedb/wheatCache/middleware/log-middle" - mapKey "gitee.com/timedb/wheatCache/middleware/map-key" + "gitee.com/timedb/wheatCache/plugins" + + logMiddle "gitee.com/timedb/wheatCache/plugins/log-middle" + mapKey "gitee.com/timedb/wheatCache/plugins/map-key" ) func GetMiddlewareMap() map[string]middleware.MiddleToolsInterface { diff --git a/middleware/config/middle.template b/plugins/config/middle.template similarity index 77% rename from middleware/config/middle.template rename to plugins/config/middle.template index 5bcbc70..1f6d411 100644 --- a/middleware/config/middle.template +++ b/plugins/config/middle.template @@ -4,9 +4,9 @@ package config import ( - "gitee.com/timedb/wheatCache/middleware" + "gitee.com/timedb/wheatCache/plugins" {%for dir in dirs %} - {{dir[0]}} "gitee.com/timedb/wheatCache/middleware/{{dir[1]}}" + {{dir[0]}} "gitee.com/timedb/wheatCache/plugins/{{dir[1]}}" {%- endfor%} ) diff --git a/middleware/define.go b/plugins/define.go similarity index 100% rename from middleware/define.go rename to plugins/define.go diff --git a/middleware/log-middle/middleware.go b/plugins/log-middle/middleware.go similarity index 100% rename from middleware/log-middle/middleware.go rename to plugins/log-middle/middleware.go diff --git a/middleware/map-key/middleware.go b/plugins/map-key/middleware.go similarity index 100% rename from middleware/map-key/middleware.go rename to plugins/map-key/middleware.go diff --git a/shell/gen_middleware.py b/shell/gen_middleware.py index df56692..64ef162 100644 --- a/shell/gen_middleware.py +++ b/shell/gen_middleware.py @@ -3,11 +3,11 @@ from jinja2 import Template sysPath = os.getcwd() -tempPath = f"{sysPath}/middleware/config" +tempPath = f"{sysPath}/plugins/config" structurePath = f"{sysPath}/pkg/structure" protobufPath = f"{sysPath}/protobuf" storagePath = f"{sysPath}/storage" -middlePath = f"{sysPath}/middleware" +middlePath = f"{sysPath}/plugins" def go_fmt(path: str): os.system(f"go fmt {path}")