diff --git a/base/nfs/cat.go b/base/nfs/cat.go index b7e5be91..616df8e4 100644 --- a/base/nfs/cat.go +++ b/base/nfs/cat.go @@ -136,7 +136,7 @@ func init() { Index.MergeCommands(ice.Commands{ CAT: {Name: "cat path auto", Help: "文件", Actions: ice.MergeActions(ice.Actions{ ice.CTX_INIT: {Hand: func(m *ice.Message, arg ...string) { aaa.White(m, ice.SRC_MAIN_JS, ice.SRC_MAIN_GO, ice.SRC_MAIN_SHY) }}, - }, ctx.ConfAction(SOURCE, kit.DictList( + }, mdb.AutoConfig(SOURCE, kit.DictList( HTML, CSS, JS, GO, SH, SHY, CSV, JSON, PY, MD, TXT, XML, YML, ZML, IML, "license", "makefile", "configure", "conf", diff --git a/base/web/serve.go b/base/web/serve.go index cb832f8e..3525a107 100644 --- a/base/web/serve.go +++ b/base/web/serve.go @@ -206,7 +206,7 @@ func init() { PP(ice.REQUIRE): {Name: "/require/shylinux.com/x/volcanos/proto.js", Help: "代码库", Hand: func(m *ice.Message, arg ...string) { p := path.Join(ice.ISH_PLUGED, path.Join(arg...)) if !nfs.ExistsFile(m, p) { - m.Cmd(cli.SYSTEM, "git", "clone", "https://"+path.Join(arg[:3]...), path.Join(ice.ISH_PLUGED, path.Join(arg[:3]))) + m.Cmd(cli.SYSTEM, "git", "clone", "https://"+path.Join(arg[:3]...), path.Join(ice.ISH_PLUGED, path.Join(arg[:3]...))) } m.RenderDownload(p) }}, diff --git a/core/chat/location.go b/core/chat/location.go index 08d2e40a..b69e08de 100644 --- a/core/chat/location.go +++ b/core/chat/location.go @@ -1,8 +1,8 @@ package chat import ( - "sync" "net/http" + "sync" ice "shylinux.com/x/icebergs" "shylinux.com/x/icebergs/base/aaa" diff --git a/core/chat/oauth/oauth.go b/core/chat/oauth/oauth.go index 6df96243..4b976938 100644 --- a/core/chat/oauth/oauth.go +++ b/core/chat/oauth/oauth.go @@ -1,8 +1,8 @@ package oauth import ( - "path" "net/http" + "path" "strings" "time" diff --git a/core/code/css.go b/core/code/css.go index 3be4bb49..93c24dd5 100644 --- a/core/code/css.go +++ b/core/code/css.go @@ -1,9 +1,9 @@ package code import ( - "strings" "path" - + "strings" + ice "shylinux.com/x/icebergs" "shylinux.com/x/icebergs/base/ctx" "shylinux.com/x/icebergs/base/mdb" @@ -57,7 +57,7 @@ func _css_show(m *ice.Message, arg ...string) { } func _css_exec(m *ice.Message, arg ...string) { if arg[2] == "usr/volcanos/" && strings.HasPrefix(arg[1], "plugin/local/") { - key := "web."+strings.ReplaceAll(strings.TrimSuffix(strings.TrimPrefix(arg[1], "plugin/local/"), ".css"), ice.PS, ice.PT) + key := "web." + strings.ReplaceAll(strings.TrimSuffix(strings.TrimPrefix(arg[1], "plugin/local/"), ".css"), ice.PS, ice.PT) ctx.ProcessCommand(m, kit.Select("can.plugin", key), kit.Simple()) return } @@ -72,4 +72,4 @@ func init() { mdb.ENGINE: {Hand: func(m *ice.Message, arg ...string) { _css_exec(m, arg...) }}, }, PlugAction(), LangAction())}, }) -} \ No newline at end of file +} diff --git a/core/mall/goods.go b/core/mall/goods.go index 1068c798..1dddd07e 100644 --- a/core/mall/goods.go +++ b/core/mall/goods.go @@ -19,7 +19,9 @@ func init() { mdb.MODIFY: {Name: "modify zone type name text price count image=4@img audio video"}, mdb.CREATE: {Name: "modify zone type name text price count image=4@img audio video"}, web.UPLOAD: {Hand: func(m *ice.Message, arg ...string) { web.Upload(m) }}, - "copy": {Hand: func(m *ice.Message, arg ...string) { m.Cmd("", mdb.CREATE, m.OptionSimple("zone,type,name,text,price,count,image")) }}, + "copy": {Hand: func(m *ice.Message, arg ...string) { + m.Cmd("", mdb.CREATE, m.OptionSimple("zone,type,name,text,price,count,image")) + }}, }, mdb.HashAction(mdb.FIELD, "time,hash,zone,type,name,text,price,count,image,audio,video")), Hand: func(m *ice.Message, arg ...string) { if mdb.HashSelect(m, arg...); len(arg) == 0 || arg[0] == "" { m.Action(mdb.CREATE, mdb.EXPORT, mdb.IMPORT) diff --git a/core/team/task.go b/core/team/task.go index 80476c30..f9c8d420 100644 --- a/core/team/task.go +++ b/core/team/task.go @@ -74,9 +74,9 @@ func init() { mdb.ZoneInsert(m, arg[:2], BEGIN_TIME, m.Time(), STATUS, PREPARE, LEVEL, 3, SCORE, 3, arg[2:]) }}, mdb.MODIFY: {Hand: func(m *ice.Message, arg ...string) { _task_modify(m, arg[0], arg[1], arg[2:]...) }}, - CANCEL: {Name: "cancal", Hand: func(m *ice.Message, arg ...string) { _task_modify(m, STATUS, CANCEL) }}, - BEGIN: {Name: "begin", Hand: func(m *ice.Message, arg ...string) { _task_modify(m, STATUS, PROCESS) }}, - END: {Name: "end", Hand: func(m *ice.Message, arg ...string) { _task_modify(m, STATUS, FINISH) }}, + CANCEL: {Name: "cancal", Hand: func(m *ice.Message, arg ...string) { _task_modify(m, STATUS, CANCEL) }}, + BEGIN: {Name: "begin", Hand: func(m *ice.Message, arg ...string) { _task_modify(m, STATUS, PROCESS) }}, + END: {Name: "end", Hand: func(m *ice.Message, arg ...string) { _task_modify(m, STATUS, FINISH) }}, }, mdb.ZoneAction(mdb.FIELD, "begin_time,close_time,id,status,level,score,type,name,text")), Hand: func(m *ice.Message, arg ...string) { if mdb.ZoneSelect(m, arg...); len(arg) > 0 && arg[0] != "" { status := map[string]int{} diff --git a/core/wiki/table.go b/core/wiki/table.go index e0d01453..0a33696d 100644 --- a/core/wiki/table.go +++ b/core/wiki/table.go @@ -58,6 +58,7 @@ func transArgKey(arg []string) []string { } return arg } + const TABLE = "table" func init() { diff --git a/misc/chrome/cache.go b/misc/chrome/cache.go index 6e83c6e7..c72cb965 100644 --- a/misc/chrome/cache.go +++ b/misc/chrome/cache.go @@ -1,8 +1,8 @@ package chrome import ( - "path" "net/http" + "path" "shylinux.com/x/ice" "shylinux.com/x/icebergs/base/mdb" diff --git a/misc/mp/login.go b/misc/mp/login.go index 009e79a6..6a59372f 100644 --- a/misc/mp/login.go +++ b/misc/mp/login.go @@ -1,8 +1,8 @@ package mp import ( - "net/http" "encoding/base64" + "net/http" "time" ice "shylinux.com/x/icebergs" diff --git a/misc/wx/access.go b/misc/wx/access.go index ff315f43..bcc4d15d 100644 --- a/misc/wx/access.go +++ b/misc/wx/access.go @@ -1,8 +1,8 @@ package wx import ( - "net/http" "crypto/sha1" + "net/http" "strings" "time"