readme: update with example of logging to file

This commit is contained in:
Simon Eskildsen
2017-02-06 19:16:20 -05:00
parent 11fbf0fa42
commit 141e6dc6a6
3 changed files with 21 additions and 4 deletions
+1 -1
View File
@@ -13,7 +13,7 @@ func IsTerminal(f io.Writer) bool {
var termios Termios
switch v := f.(type) {
case *os.File:
_, err := unix.IoctlGetTermios(int(f.Fd()), unix.TCGETA)
_, err := unix.IoctlGetTermios(int(v.Fd()), unix.TCGETA)
return err == nil
default:
return false