tee: allow writing strings.
This commit is contained in:
parent
30ffbbdbc5
commit
3bb1362c0e
|
@ -5,9 +5,15 @@ import (
|
|||
"os"
|
||||
)
|
||||
|
||||
type WriteStringCloser interface {
|
||||
Write([]byte) (int, error)
|
||||
WriteString(string) (int, error)
|
||||
Close() error
|
||||
}
|
||||
|
||||
// Tee emulates the Unix tee(1) command.
|
||||
type Tee struct {
|
||||
f *os.File
|
||||
f WriteStringCloser
|
||||
Verbose bool
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue