inaka / elvis_core

The core of an Erlang linter
Other
61 stars 56 forks source link

Allow errorless consumption by `rebar3_lint` #332

Closed paulo-ferraz-oliveira closed 10 months ago

paulo-ferraz-oliveira commented 10 months ago

This will be required once we want to add more context to errors in the plugin. I'll prepare a pull request for that and only propose it for acceptance once this is merged, tagged and Hex-published, at least.

paulo-ferraz-oliveira commented 10 months ago

For context, the change comes from

-spec do_parallel_rock(elvis_config:config()) ->
                          ok |
                          {fail, [{throw, term()} | elvis_result:file() | elvis_result:rule()]}.

being used as

    Results = lists:map(fun do_parallel_rock/1, NewConfig),
    lists:foldl(fun combine_results/2, ok, Results).

in rock/1, the updated function.

paulo-ferraz-oliveira commented 10 months ago

Going to release 3.2.1 on GitHub and Hex.