Add ClearLine() to UI implementations
This commit is contained in:
parent
71fb214d95
commit
6ba7807f7b
@ -42,6 +42,10 @@ func (u *runnerUI) Interactive() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
func (u *runnerUI) ClearLine() {
|
||||
// NO-OP - noninteractive
|
||||
}
|
||||
|
||||
// Output outputs a message directly to the terminal. The remaining
|
||||
// arguments should be interpolations for the format string. After the
|
||||
// interpolations you may add Options.
|
||||
|
||||
@ -37,6 +37,12 @@ func (u *multiUI) Input(input *terminal.Input) (string, error) {
|
||||
return term.Input(input)
|
||||
}
|
||||
|
||||
func (u *multiUI) ClearLine() {
|
||||
for _, u := range u.UIs {
|
||||
u.ClearLine()
|
||||
}
|
||||
}
|
||||
|
||||
func (u *multiUI) Interactive() bool {
|
||||
for _, u := range u.UIs {
|
||||
if u.Interactive() {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user