Environment
Erlang/OTP 23 [erts-11.2.2.4] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1]
Elixir 1.12.2 (compiled with Erlang/OTP 23)
Problem
mix format behaves differently in version 1.12.2 with respect with 1.10.4.
In .formatter.exs the line length is set to 120 and with elixir 1.10.4 this file is formatted as follows:
defmodule A do
defp info(version, exclude) do
%Info{
title: "XXX",
version: "1.2.3",
description: """
#{
:app
|> Application.fetch_env!(:doc_resources_changelog_path)
|> read_or_empty_string()
|> clean_tagged_string(exclude)
}
#{
:app
|> Application.fetch_env!(:doc_schema_version_path)
|> read_or_empty_string()
|> clean_lines_containing(exclude)
}
"""
}
end
end
With elixir 1.12.2 it is instead formatted with the pipes on single lines despite they both exceed the maximum line length (129 and 127 chars)
defmodule A do
defp info(version, exclude) do
%Info{
title: "XXX",
version: "1.2.3",
description: """
#{:app |> Application.fetch_env!(:doc_resources_changelog_path) |> read_or_empty_string() |> clean_tagged_string(exclude)}
#{:app |> Application.fetch_env!(:doc_schema_version_path) |> read_or_empty_string() |> clean_lines_containing(exclude)}
"""
}
end
end
Environment
Problem
mix formatbehaves differently in version 1.12.2 with respect with 1.10.4.In
.formatter.exsthe line length is set to 120 and with elixir 1.10.4 this file is formatted as follows:With elixir 1.12.2 it is instead formatted with the pipes on single lines despite they both exceed the maximum line length (129 and 127 chars)