浏览代码

Better code path handling during upgrades

While building a upgrade package rebar will add new paths to the
internal erlang path, these paths and their order have effects on how
the package is built. This patch should fix some corner cases where a
user can receive a "undefined application" error.
pull/3/head
joewilliams 13 年前
父节点
当前提交
fb8732085e
共有 1 个文件被更改,包括 3 次插入4 次删除
  1. +3
    -4
      src/rebar_upgrade.erl

+ 3
- 4
src/rebar_upgrade.erl 查看文件

@ -111,13 +111,12 @@ setup(OldVerPath, NewVerPath, NewName, NewVer, NameVer) ->
{ok, _} = file:copy(Src, Dst),
ok = code:add_pathsa(
lists:append([
filelib:wildcard(filename:join([NewVerPath,
"lib", "*", "ebin"])),
filelib:wildcard(filename:join([OldVerPath,
"releases", "*"])),
filelib:wildcard(filename:join([OldVerPath,
"lib", "*", "ebin"])),
filelib:wildcard(filename:join([NewVerPath,
"lib", "*", "ebin"])),
filelib:wildcard(filename:join([NewVerPath, "*"]))
"lib", "*", "ebin"]))
])).
run_systools(NewVer, Name) ->

正在加载...
取消
保存