mirror of
https://shylinux.com/x/icebergs
synced 2025-04-26 09:34:05 +08:00
opt some
This commit is contained in:
parent
9f3e99dcf7
commit
bff7fab4d6
@ -114,7 +114,6 @@ func (f *Frame) scan(m *ice.Message, h, line string) *Frame {
|
|||||||
f.ps2 = kit.Simple(m.Confv(PROMPT, kit.Keym(PS2)))
|
f.ps2 = kit.Simple(m.Confv(PROMPT, kit.Keym(PS2)))
|
||||||
m.I, m.O = f.stdin, f.stdout
|
m.I, m.O = f.stdin, f.stdout
|
||||||
m.Optionv(MESSAGE, m)
|
m.Optionv(MESSAGE, m)
|
||||||
m.Sleep("300ms")
|
|
||||||
ps, bio := f.ps1, bufio.NewScanner(f.stdin)
|
ps, bio := f.ps1, bufio.NewScanner(f.stdin)
|
||||||
for f.prompt(m, ps...); f.stdin != nil && bio.Scan(); f.prompt(m, ps...) {
|
for f.prompt(m, ps...); f.stdin != nil && bio.Scan(); f.prompt(m, ps...) {
|
||||||
if len(bio.Text()) == 0 && h == STDIO {
|
if len(bio.Text()) == 0 && h == STDIO {
|
||||||
|
@ -158,7 +158,7 @@ func init() {
|
|||||||
_serve_start(m)
|
_serve_start(m)
|
||||||
}},
|
}},
|
||||||
SERVE_START: {Hand: func(m *ice.Message, arg ...string) {
|
SERVE_START: {Hand: func(m *ice.Message, arg ...string) {
|
||||||
m.Sleep30ms().Cmd(ssh.PRINTF, kit.Dict(nfs.CONTENT, "\r"+ice.Render(m, ice.RENDER_QRCODE, m.Cmdx(SPACE, DOMAIN))+ice.NL))
|
m.Sleep30ms().Cmd(ssh.PRINTF, kit.Dict(nfs.CONTENT, "\r"+ice.Render(m, ice.RENDER_QRCODE, m.Cmdx(SPACE, DOMAIN))+ice.NL)).Cmd(ssh.PROMPT)
|
||||||
}},
|
}},
|
||||||
SERVE_REWRITE: {Hand: func(m *ice.Message, arg ...string) {
|
SERVE_REWRITE: {Hand: func(m *ice.Message, arg ...string) {
|
||||||
if arg[0] != http.MethodGet {
|
if arg[0] != http.MethodGet {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user