From ae77de1a804cb69a091b824661fc93575ca0fb44 Mon Sep 17 00:00:00 2001 From: shylinux Date: Fri, 24 Mar 2023 20:47:50 +0800 Subject: [PATCH] opt some --- base/ssh/script.go | 2 +- init.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/base/ssh/script.go b/base/ssh/script.go index f1f58ba4..c10a4cf7 100644 --- a/base/ssh/script.go +++ b/base/ssh/script.go @@ -105,7 +105,7 @@ func (f *Frame) parse(m *ice.Message, h, line string) string { func (f *Frame) scan(m *ice.Message, h, line string) *Frame { f.ps1 = kit.Simple(mdb.Confv(m, PROMPT, kit.Keym(PS1))) f.ps2 = kit.Simple(mdb.Confv(m, PROMPT, kit.Keym(PS2))) - // m.Options(MESSAGE, m, ice.LOG_DISABLE, ice.TRUE) + m.Options(MESSAGE, m, ice.LOG_DISABLE, ice.TRUE) m.I, m.O = f.stdin, f.stdout ps, bio := f.ps1, bufio.NewScanner(f.stdin) for f.prompt(m, ps...); f.stdin != nil && bio.Scan(); f.prompt(m, ps...) { diff --git a/init.go b/init.go index e04c811a..df5da6bb 100644 --- a/init.go +++ b/init.go @@ -101,6 +101,7 @@ func Run(arg ...string) string { conf.Wait() os.Exit(kit.Int(Pulse.Option(EXIT))) default: + logs.Disable(true) Pulse.Cmdy(INIT).Cmdy(arg) kit.If(Pulse.IsErrNotFound(), func() { Pulse.SetAppend().SetResult().Cmdy(SYSTEM, arg) }) kit.If(strings.TrimSpace(Pulse.Result()) == "" && Pulse.Length() > 0, func() { Pulse.TableEcho() })