From a1f47427093daa060ab510e099de3947430bdb8d Mon Sep 17 00:00:00 2001 From: Thomas O'Dowd Date: Tue, 20 Dec 2016 17:03:37 +0900 Subject: Issue #1416: Merge erl_files_first separately and avoid sorting. The order of the files listed in "erl_files_first" option is important and should not be sorted. By handling the merge similarly to mib_files_first, the sort order is preserved. --- src/rebar_opts.erl | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src') diff --git a/src/rebar_opts.erl b/src/rebar_opts.erl index 444b760..589dbb8 100644 --- a/src/rebar_opts.erl +++ b/src/rebar_opts.erl @@ -118,6 +118,10 @@ merge_opt({plugins, _}, NewValue, _OldValue) -> NewValue; merge_opt(profiles, NewValue, OldValue) -> dict:to_list(merge_opts(dict:from_list(NewValue), dict:from_list(OldValue))); +merge_opt(erl_first_files, Value, Value) -> + Value; +merge_opt(erl_first_files, NewValue, OldValue) -> + OldValue ++ NewValue; merge_opt(mib_first_files, Value, Value) -> Value; merge_opt(mib_first_files, NewValue, OldValue) -> -- cgit v1.1