1
0
forked from x/icebergs
This commit is contained in:
IT 老营长 @云轩领航-创始人 2023-03-24 20:47:50 +08:00
parent 9eb655b0a1
commit ae77de1a80
2 changed files with 2 additions and 1 deletions

View File

@ -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...) {

View File

@ -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() })