Browse Source

only run clean hooks once

pull/466/head
Tristan Sloughter 10 years ago
parent
commit
42339f62f3
1 changed files with 7 additions and 2 deletions
  1. +7
    -2
      src/rebar_prv_clean.erl

+ 7
- 2
src/rebar_prv_clean.erl View File

@ -67,8 +67,13 @@ format_error(Reason) ->
clean_apps(State, Providers, Apps) ->
lists:foreach(fun(AppInfo) ->
AppDir = rebar_app_info:dir(AppInfo),
C = rebar_config:consult(AppDir),
S = rebar_state:new(State, C, AppDir),
S = case rebar_app_info:state(AppInfo) of
undefined ->
C = rebar_config:consult(AppDir),
rebar_state:new(State, C, AppDir);
AppState ->
AppState
end,
?INFO("Cleaning out ~s...", [rebar_app_info:name(AppInfo)]),
%% Legacy hook support

Loading…
Cancel
Save