New features:
- Turn rich compiler errors on by default
- Tweak experimental manifest plugin to return ELP-compatible information
Bug fixes:
- make escriptize reproducible by setting timestamps for files in zip to unix epoch
- Log path when plugin template file read fails
- Prevent infinite compiler DAG growth
- Port Relx compatibility fix for escript files in OTP-27
Internal maintenance:
- Made
rebar_utils:filtermap/2
to call directlylists:filtermap/2
- Cleaned up additional definitions in
bootstrap
- Replaced rebar_utils:find_source/3 by a call to filelib:find_source/3 and Marked rebar_utils:find_source/3 as deprecated
- Fixing various typos in comments, types, and function names
- Bump hex_core and certifi dependencies
- Remove legacy hostname checks
- Replaced group_by_namespace/1 by a call to maps:groups_from_list/2
- Removed legacy OTP_RELEASE macro statements
- Removed legacy fun_stacktrace usage
- Removed unsused platform_define options
- Standardizing templates indentation
Regarding rich compiler errors, the change is optional.
Given the module:
-module(fake_mod).
-export([diagnostic/1]).
diagnostic(A) ->
X = add(5 / 0),
{X,X}.
add(X) -> X.
add(X, Y) -> X + Y.
Calling rebar3 compile can now yield:
...
===> Compiling apps/rebar/src/fake_mod.erl failed
┌─ apps/rebar/src/fake_mod.erl:
│
5 │ diagnostic(A) ->
│ ╰── variable 'A' is unused
┌─ apps/rebar/src/fake_mod.erl:
│
6 │ X = add(5 / 0),
│ ╰── evaluation of operator '/'/2 will fail with a 'badarith' exception
┌─ apps/rebar/src/fake_mod.erl:
│
11 │ add(X, Y) -> X + Y.
│ ╰── function add/2 is unused
and in a terminal supporting color output:
By default, this format is turned on, but can be turned off optionally by configuring values with
{compiler_error_format, minimal}.
If this breaks your tooling, you may want to put it in your global rebar3 config file.