summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTristan Sloughter <t@crashfast.com>2015-08-21 19:48:26 -0500
committerTristan Sloughter <t@crashfast.com>2015-08-21 19:48:26 -0500
commite336d7aaa124bb63c92f4470429d06f5de8e089a (patch)
tree07c8c8901c49a382558cf541e77d2302294409d7 /src
parentcf5390f01876ff8d9e70cff521740ab0dd805929 (diff)
remove unneeded packages ets table load/unload in plugins
Diffstat (limited to 'src')
-rw-r--r--src/rebar_plugins.erl22
1 files changed, 8 insertions, 14 deletions
diff --git a/src/rebar_plugins.erl b/src/rebar_plugins.erl
index 742dc82..6c2daef 100644
--- a/src/rebar_plugins.erl
+++ b/src/rebar_plugins.erl
@@ -16,27 +16,21 @@
-spec project_apps_install(rebar_state:t()) -> rebar_state:t().
project_apps_install(State) ->
- rebar_packages:packages(State),
-
Profiles = rebar_state:current_profiles(State),
ProjectApps = rebar_state:project_apps(State),
- State1 = lists:foldl(fun(Profile, StateAcc) ->
+ lists:foldl(fun(Profile, StateAcc) ->
Plugins = rebar_state:get(State, {plugins, Profile}, []),
StateAcc1 = handle_plugins(Profile, Plugins, StateAcc),
lists:foldl(fun(App, StateAcc2) ->
- AppDir = rebar_app_info:dir(App),
- C = rebar_config:consult(AppDir),
- S = rebar_state:new(rebar_state:new(), C, AppDir),
- Plugins2 = rebar_state:get(S, {plugins, Profile}, []),
- handle_plugins(Profile, Plugins2, StateAcc2)
- end, StateAcc1, ProjectApps)
- end, State, Profiles),
-
- rebar_packages:close_packages(),
-
- State1.
+ AppDir = rebar_app_info:dir(App),
+ C = rebar_config:consult(AppDir),
+ S = rebar_state:new(rebar_state:new(), C, AppDir),
+ Plugins2 = rebar_state:get(S, {plugins, Profile}, []),
+ handle_plugins(Profile, Plugins2, StateAcc2)
+ end, StateAcc1, ProjectApps)
+ end, State, Profiles).
-spec install(rebar_state:t()) -> rebar_state:t().
install(State) ->