mirror of
https://github.com/restic/restic.git
synced 2026-08-03 20:52:16 +00:00
replace globalOptions.stdout with termstatus.OutputWriter
This commit is contained in:
@@ -6,12 +6,6 @@ import (
|
||||
"sync"
|
||||
)
|
||||
|
||||
// WrapStdout returns line-buffering replacements for os.Stdout.
|
||||
// On Close, the remaining bytes are written, followed by a line break.
|
||||
func WrapStdout(term *Terminal) (stdout io.WriteCloser) {
|
||||
return newLineWriter(term.Print)
|
||||
}
|
||||
|
||||
type lineWriter struct {
|
||||
m sync.Mutex
|
||||
buf bytes.Buffer
|
||||
|
||||
Reference in New Issue
Block a user