func (c *ColorLoggerFactory) Create(name string) logger.Logger {
	if c.maxLength < len(name) {
		c.maxLength = len(name)
	}
	return &ColorLogger{
		name:        name,
		factory:     c,
		colorPrefix: <-colorPrefix,
	}
}
Create implements logger.Factory.Create.
package logger
import (
	"fmt"
	"os"
	"strconv"
	"github.com/docker/libcompose/logger"
	"golang.org/x/crypto/ssh/terminal"
)
type ColorLoggerFactory struct {
	maxLength int
	tty       bool
}
type ColorLogger struct {
	name        string
	colorPrefix string
	factory     *ColorLoggerFactory
}
func NewColorLoggerFactory() *ColorLoggerFactory {
	return &ColorLoggerFactory{
		tty: terminal.IsTerminal(int(os.Stdout.Fd())),
	}
}