diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/rebar_digraph.erl | 5 | ||||
-rw-r--r-- | src/rebar_prv_install_deps.erl | 6 |
2 files changed, 5 insertions, 6 deletions
diff --git a/src/rebar_digraph.erl b/src/rebar_digraph.erl index 9e10d49..7f7909e 100644 --- a/src/rebar_digraph.erl +++ b/src/rebar_digraph.erl @@ -125,5 +125,6 @@ find_app_by_name(Name, Apps) -> end, Apps). all_apps_deps(App) -> - Applications = [atom_to_binary(X, utf8) || X <- rebar_app_info:applications(App)], - lists:usort(rebar_app_info:deps(App) ++ Applications). + Applications = lists:usort([atom_to_binary(X, utf8) || X <- rebar_app_info:applications(App)]), + Deps = lists:usort(lists:map(fun({Name, _}) -> Name; (Name) -> Name end, rebar_app_info:deps(App))), + lists:umerge(Deps, Applications). diff --git a/src/rebar_prv_install_deps.erl b/src/rebar_prv_install_deps.erl index 815d6c8..90bd70c 100644 --- a/src/rebar_prv_install_deps.erl +++ b/src/rebar_prv_install_deps.erl @@ -261,9 +261,7 @@ package_to_app(DepsDir, Packages, {Name, Vsn, Level}, IsLock, State) -> false -> throw(?PRV_ERROR({missing_package, Name, Vsn})) end; - {ok, P} -> - PkgDeps = [{PkgName, PkgVsn} - || {PkgName,PkgVsn} <- proplists:get_value(<<"deps">>, P, [])], + {ok, PkgDeps} -> {ok, AppInfo} = rebar_app_info:new(Name, Vsn), AppInfo1 = rebar_app_info:deps(AppInfo, PkgDeps), AppInfo2 = rebar_app_info:dir(AppInfo1, filename:join([DepsDir, Name])), @@ -578,7 +576,7 @@ fetch_app(AppInfo, AppDir, State) -> end. update_app_info(AppDir, AppInfo) -> - {true, Found} = rebar_app_discover:find_app(AppDir, all), + {ok, Found} = rebar_app_info:discover(AppDir), AppDetails = rebar_app_info:app_details(Found), Applications = proplists:get_value(applications, AppDetails, []), IncludedApplications = proplists:get_value(included_applications, AppDetails, []), |