Ver Fonte

Fix \n not being rendered with backquotes

Signed-off-by: Guillaume Tardif <[email protected]>
Guillaume Tardif há 4 anos atrás
pai
commit
584ceab72a
2 ficheiros alterados com 3 adições e 3 exclusões
  1. 2 2
      cli/cmd/compose/compose.go
  2. 1 1
      cli/cmd/compose/pull.go

+ 2 - 2
cli/cmd/compose/compose.go

@@ -111,7 +111,7 @@ func Command(contextType string) *cobra.Command {
 		PersistentPreRunE: func(cmd *cobra.Command, args []string) error {
 			if noAnsi {
 				if ansi != "auto" {
-					return errors.New(aec.Apply(`cannot specify DEPRECATED "--no-ansi" and "--ansi". Please use only "--ansi".`, aec.RedF))
+					return errors.New(`cannot specify DEPRECATED "--no-ansi" and "--ansi". Please use only "--ansi"`)
 				}
 				ansi = "never"
 				fmt.Fprint(os.Stderr, aec.Apply("option '--no-ansi' is DEPRECATED ! Please use '--ansi' instead.\n", aec.RedF))
@@ -119,7 +119,7 @@ func Command(contextType string) *cobra.Command {
 			formatter.SetANSIMode(ansi)
 			if opts.WorkDir != "" {
 				if opts.ProjectDir != "" {
-					return errors.New(aec.Apply(`cannot specify DEPRECATED "--workdir" and "--project-directory". Please use only "--project-directory" instead.`, aec.RedF))
+					return errors.New(`cannot specify DEPRECATED "--workdir" and "--project-directory". Please use only "--project-directory" instead`)
 				}
 				opts.ProjectDir = opts.WorkDir
 				fmt.Fprint(os.Stderr, aec.Apply("option '--workdir' is DEPRECATED at root level! Please use '--project-directory' instead.\n", aec.RedF))

+ 1 - 1
cli/cmd/compose/pull.go

@@ -47,7 +47,7 @@ func pullCommand(p *projectOptions) *cobra.Command {
 		Short: "Pull service images",
 		RunE: func(cmd *cobra.Command, args []string) error {
 			if opts.noParallel {
-				fmt.Fprint(os.Stderr, aec.Apply(`option "--no-parallel" is DEPRECATED and will be ignored.\n`, aec.RedF))
+				fmt.Fprint(os.Stderr, aec.Apply("option '--no-parallel' is DEPRECATED and will be ignored.\n", aec.RedF))
 			}
 			return runPull(cmd.Context(), opts, args)
 		},