1
0
forked from x/icebergs
This commit is contained in:
IT 老营长 @云轩领航-创始人 2022-12-03 14:07:02 +08:00
parent 583b820e65
commit ccca1f74b0
3 changed files with 6 additions and 4 deletions

View File

@ -26,7 +26,8 @@ func init() {
return
}
msg := m.Cmd("", m.Option(mdb.HASH))
m.Cmd(USER, mdb.CREATE, USERNAME, msg.Option(EMAIL))
ls := kit.Split(msg.Option(EMAIL), ice.AT)
m.Cmd(USER, mdb.CREATE, USERNAME, msg.Option(EMAIL), USERNICK, ls[0], USERZONE, ls[1])
m.ProcessOpen(kit.MergeURL2(m.Option(ice.MSG_USERWEB), ice.PS, ice.MSG_SESSID, SessCreate(m, msg.Option(EMAIL))))
mdb.HashModify(m, m.OptionSimple(mdb.HASH), mdb.STATUS, ACCEPT)
}},

View File

@ -136,11 +136,11 @@ 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) }},
}, mdb.AutoConfig(SOURCE, kit.DictList(
}, ice.Actions{ice.CTX_INIT: mdb.AutoConfig(SOURCE, kit.DictList(
HTML, CSS, JS, GO, SH, SHY, CSV, JSON,
PY, MD, TXT, XML, YML, ZML, IML,
"license", "makefile", "configure", "conf",
))), Hand: func(m *ice.Message, arg ...string) {
))}), Hand: func(m *ice.Message, arg ...string) {
if len(arg) == 0 || strings.HasSuffix(arg[0], ice.PS) {
m.Cmdy(DIR, arg)
return

View File

@ -6,6 +6,7 @@ import (
"strings"
ice "shylinux.com/x/icebergs"
"shylinux.com/x/icebergs/base/aaa"
"shylinux.com/x/icebergs/base/cli"
"shylinux.com/x/icebergs/base/ctx"
"shylinux.com/x/icebergs/base/gdb"
@ -42,7 +43,7 @@ func _dream_show(m *ice.Message, name string) {
}
defer m.ProcessOpen(MergePod(m, m.Option(mdb.NAME, name)))
p := path.Join(ice.USR_LOCAL_WORK, name)
if pid := m.Cmdx(nfs.CAT, path.Join(p, ice.Info.PidPath)); pid != "" && nfs.ExistsFile(m, "/proc/"+pid) {
if pid := m.Cmdx(nfs.CAT, path.Join(p, ice.Info.PidPath), kit.Dict(ice.MSG_USERROLE, aaa.TECH)); pid != "" && nfs.ExistsFile(m, "/proc/"+pid) {
m.Info("already exists %v", pid)
return
} else if m.Cmd(SPACE, name).Length() > 0 {