diff options
author | Fred Hebert <mononcqc@ferd.ca> | 2018-04-20 20:08:58 -0400 |
---|---|---|
committer | Fred Hebert <mononcqc@ferd.ca> | 2018-04-20 20:14:10 -0400 |
commit | 6ab00567f506de5b95ef6456a4048ed184f4d58e (patch) | |
tree | 5f01c1ec5ea84d4c18ff8529159d54723875d686 | |
parent | 9cfe33f97e83f060cb4394f0089c2998994af7f4 (diff) |
Display error when rebar.config.script fails
This will at least display the script that failed with the stacktrace
before failing as usual, but without altering the return value.
This should make the common failure path more user-friendly without
breaking any existing behaviour that may have relied on the script file
working. If there's any unexpected side-effect, it will be visual only
rather than blocking full builds if ?ABORT were used.
-rw-r--r-- | src/rebar_config.erl | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/rebar_config.erl b/src/rebar_config.erl index 7316d83..797dddc 100644 --- a/src/rebar_config.erl +++ b/src/rebar_config.erl @@ -290,6 +290,8 @@ consult_and_eval(File, Script) -> {ok, Term} -> {ok, [Term]}; Error -> + ?ERROR("Error evaluating configuration script at ~p:~n~p~n", + [Script, Error]), Error end. |