aboutsummaryrefslogtreecommitdiffstats
path: root/src/dma/vendor/github.com/mattn/go-colorable/colorable_appengine.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/dma/vendor/github.com/mattn/go-colorable/colorable_appengine.go')
-rw-r--r--src/dma/vendor/github.com/mattn/go-colorable/colorable_appengine.go29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/dma/vendor/github.com/mattn/go-colorable/colorable_appengine.go b/src/dma/vendor/github.com/mattn/go-colorable/colorable_appengine.go
new file mode 100644
index 00000000..1f28d773
--- /dev/null
+++ b/src/dma/vendor/github.com/mattn/go-colorable/colorable_appengine.go
@@ -0,0 +1,29 @@
+// +build appengine
+
+package colorable
+
+import (
+ "io"
+ "os"
+
+ _ "github.com/mattn/go-isatty"
+)
+
+// NewColorable return new instance of Writer which handle escape sequence.
+func NewColorable(file *os.File) io.Writer {
+ if file == nil {
+ panic("nil passed instead of *os.File to NewColorable()")
+ }
+
+ return file
+}
+
+// NewColorableStdout return new instance of Writer which handle escape sequence for stdout.
+func NewColorableStdout() io.Writer {
+ return os.Stdout
+}
+
+// NewColorableStderr return new instance of Writer which handle escape sequence for stderr.
+func NewColorableStderr() io.Writer {
+ return os.Stderr
+}