Merge pull request #62 from msgpack/rebar2-compat

Remove rebar3_eqc when using rebar 2.x
This commit is contained in:
UENISHI Kota 2016-03-08 10:32:31 +09:00
commit 0ffd66b1e6
2 changed files with 10 additions and 1 deletions

View File

@ -14,7 +14,7 @@
]}.
{plugins, [
{rebar3_eqc, ".*", {git, "https://github.com/kellymclaughlin/rebar3-eqc-plugin.git", {tag, "0.0.8"}}},
rebar3_eqc,
rebar3_hex
]}.

9
rebar.config.script Normal file
View File

@ -0,0 +1,9 @@
case application:get_key(rebar, vsn) of
{ok, "2."++_V} ->
%% Workarounds for rebar2 here
{plugins, Plugins} = lists:keyfind(plugins, 1, CONFIG),
NewPlugins = lists:delete(rebar3_eqc, Plugins),
lists:keyreplace(plugins, 1, CONFIG, {plugins, NewPlugins});
_ ->
CONFIG
end.