]> git.uzoombox.com Git - uzsdk-v0.3.1.git/commitdiff
feat(all): re-arrange file tree.
authorbruce <bruce@nanzoom.com>
Mon, 12 Jun 2023 02:48:15 +0000 (10:48 +0800)
committerbruce <bruce@nanzoom.com>
Mon, 4 Nov 2024 03:21:35 +0000 (03:21 +0000)
go.mod
uzsdk/application.go [moved from service/types/application.go with 94% similarity]
uzsdk/configuration.go [moved from service/types/configuration.go with 98% similarity]
uzsdk/logger/logger.go [moved from components/logger/logger.go with 100% similarity]
uzsdk/service.go [moved from uzsdk.go with 87% similarity]
uzsdk/translations/en_US.go [moved from service/translations/en_US.go with 100% similarity]
uzsdk/translations/translation.go [moved from service/translations/translation.go with 100% similarity]
uzsdk/translations/zh_CN.go [moved from service/translations/zh_CN.go with 100% similarity]

diff --git a/go.mod b/go.mod
index ec92f598654eb222187cf4e1d6d3ed1008456820..f2added55b20e5c26ddade682f9d46175e95dd3c 100644 (file)
--- a/go.mod
+++ b/go.mod
@@ -1,6 +1,6 @@
 module git.uzoombox.com/git/uzsdk
 
-go 1.18
+go 1.20
 
 require (
        github.com/gin-gonic/gin v1.9.1
similarity index 94%
rename from service/types/application.go
rename to uzsdk/application.go
index f282258dc6b2ad2780a532927ce10ef89f24e13b..5c3dd03e6555de4e6e1057c4fe1da5a6ce5dac8b 100644 (file)
@@ -1,6 +1,6 @@
 // Copyright 2023 nanzoom.com. All Rights Reserved.
 
-package types
+package uzsdk
 
 // Application defines structure of application's information.
 type Application struct {
similarity index 98%
rename from service/types/configuration.go
rename to uzsdk/configuration.go
index a7f39f966e3259553a9bbbaf9c6466cff239b34b..fff96464f9e012e99ef558e9c9f724edd5cae2c7 100644 (file)
@@ -1,6 +1,6 @@
 // Copyright 2010-2022 nanzoom.com. All Rights Reserved.
 
-package types
+package uzsdk
 
 // Configuration defines application's configuration.
 type Configuration struct {
similarity index 87%
rename from uzsdk.go
rename to uzsdk/service.go
index fe6e0eda860465172902336a13026bbee0c649dc..503ce1ef93c9ee7087be306aeba0e318d81a27b3 100644 (file)
--- a/uzsdk.go
@@ -3,9 +3,8 @@
 package uzsdk
 
 import (
-       "git.uzoombox.com/git/uzsdk/components/logger"
-       "git.uzoombox.com/git/uzsdk/service/translations"
-       "git.uzoombox.com/git/uzsdk/service/types"
+       "git.uzoombox.com/git/uzsdk/uzsdk/logger"
+       "git.uzoombox.com/git/uzsdk/uzsdk/translations"
        "github.com/gin-gonic/gin"
        "github.com/jmoiron/sqlx"
 )
@@ -131,9 +130,9 @@ func Respcode(code string, options ...interface{}) Respnode {
 
 // Instance is the framework's instance, used for server & plugin both.
 type Instance struct {
-       Conf        *types.Configuration // configuration of this application.
-       Db          *sqlx.DB             // the first database connection created by main routine.
-       Logger      *logger.Logger       // logger created by main routine.
-       Router      *gin.Engine          // default webservice engine created by main routine.
-       Maintenance bool                 // when maintenance mode is true, only serve api /config.
+       Conf        *Configuration // configuration of this application.
+       Db          *sqlx.DB       // the first database connection created by main routine.
+       Logger      *logger.Logger // logger created by main routine.
+       Router      *gin.Engine    // default webservice engine created by main routine.
+       Maintenance bool           // when maintenance mode is true, only serve api /config.
 }