Merge pull request #137 from bosqueviejo/master

let vm.args and sys.config as optional
This commit is contained in:
Dave Smith 2013-09-20 07:05:06 -07:00
commit 4dfdd726ad

View file

@ -184,13 +184,23 @@ boot_files(TargetDir, Ver, Name) ->
filename:join([TargetDir, "releases", Ver, "start_clean.boot"]), filename:join([TargetDir, "releases", Ver, "start_clean.boot"]),
filename:join([".", ?TMP, "releases", Ver, "start_clean.boot"])), filename:join([".", ?TMP, "releases", Ver, "start_clean.boot"])),
{ok, _} = file:copy( SysConfig = filename:join([TargetDir, "releases", Ver, "sys.config"]),
filename:join([TargetDir, "releases", Ver, "sys.config"]), case filelib:is_regular(SysConfig) of
filename:join([".", ?TMP, "releases", Ver, "sys.config"])), true ->
{ok, _} = file:copy(
SysConfig,
filename:join([".", ?TMP, "releases", Ver, "sys.config"]));
false -> ok
end,
{ok, _} = file:copy( VmArgs = filename:join([TargetDir, "releases", Ver, "vm.args"]),
filename:join([TargetDir, "releases", Ver, "vm.args"]), case filelib:is_regular(VmArgs) of
filename:join([".", ?TMP, "releases", Ver, "vm.args"])). true ->
{ok, _} = file:copy(
VmArgs,
filename:join([".", ?TMP, "releases", Ver, "vm.args"]));
false -> {ok, 0}
end.
make_tar(NameVer, NewVer, NewName) -> make_tar(NameVer, NewVer, NewName) ->
Filename = NameVer ++ ".tar.gz", Filename = NameVer ++ ".tar.gz",