Skip to content

Commit f0f65f8

Browse files
author
José Valim
committed
Use IO.ANSI.format/1 for escaping mix shell messages
Signed-off-by: José Valim <[email protected]>
1 parent 23943b6 commit f0f65f8

File tree

1 file changed

+2
-2
lines changed
  • lib/mix/lib/mix/shell

1 file changed

+2
-2
lines changed

lib/mix/lib/mix/shell/io.ex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ defmodule Mix.Shell.IO do
4242
"""
4343
def error(message) do
4444
print_app
45-
IO.puts :stderr, red(IO.ANSI.format(message))
45+
IO.puts :stderr, IO.ANSI.format(red(message))
4646
end
4747

4848
@doc """
@@ -72,6 +72,6 @@ defmodule Mix.Shell.IO do
7272
defp got_yes?(_), do: false
7373

7474
defp red(message) do
75-
[IO.ANSI.red, IO.ANSI.bright, message, IO.ANSI.reset]
75+
[:red, :bright, message]
7676
end
7777
end

0 commit comments

Comments
 (0)