mirror of
https://github.com/docker/compose.git
synced 2026-08-04 14:47:40 +00:00
Merge pull request #10559 from ndeloof/COMPOSE_ANSI
introduce COMPOSE_ANSI to define --ansi default value
This commit is contained in:
commit
dc01b98aa6
1 changed files with 4 additions and 0 deletions
|
|
@ -306,6 +306,10 @@ func RootCommand(streams command.Cli, backend api.Service) *cobra.Command { //no
|
|||
logrus.SetLevel(logrus.TraceLevel)
|
||||
}
|
||||
|
||||
if v, ok := os.LookupEnv("COMPOSE_ANSI"); ok && !cmd.Flags().Changed("ansi") {
|
||||
ansi = v
|
||||
}
|
||||
|
||||
formatter.SetANSIMode(streams, ansi)
|
||||
|
||||
if noColor, ok := os.LookupEnv("NO_COLOR"); ok && noColor != "" {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue