From 6d94a883dd503084b3eed7160d8d6140ce78ae4a Mon Sep 17 00:00:00 2001 From: Victor Bilyk Date: Sat, 30 Aug 2014 10:48:12 +0700 Subject: [PATCH] getting current_command with both newer and older rebar versions --- plugins/riak_pb_msgcodegen.erl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/plugins/riak_pb_msgcodegen.erl b/plugins/riak_pb_msgcodegen.erl index 414294df..b26d9cad 100644 --- a/plugins/riak_pb_msgcodegen.erl +++ b/plugins/riak_pb_msgcodegen.erl @@ -25,7 +25,9 @@ %% Public API %% =================================================================== preprocess(Config, _AppFile) -> - case rebar_config:get(Config, current_command, undefined) of + CurrentCommand = rebar_config:get(Config, current_command, + rebar_config:get_xconf(Config, current_command, undefined)), + case CurrentCommand of 'compile' -> case rebar_utils:find_files("src", ".*\\.csv") of [] ->