aboutsummaryrefslogtreecommitdiffstats
path: root/src/rlx_prv_archive.erl
diff options
context:
space:
mode:
authorTristan Sloughter <[email protected]>2015-04-01 14:13:35 -0500
committerTristan Sloughter <[email protected]>2015-04-01 14:13:35 -0500
commit66ca6c7601519862f7cad15ecab545b7c5643e61 (patch)
treeb72848b6eb61430f4d1a4f4df0bc4c4bb32a2b1d /src/rlx_prv_archive.erl
parentde6b6aa7d48a7f1a238cd9667344d3054b184470 (diff)
parent8d6a41901c1d59fadb81e6b9ed578784478852de (diff)
downloadrelx-66ca6c7601519862f7cad15ecab545b7c5643e61.tar.gz
relx-66ca6c7601519862f7cad15ecab545b7c5643e61.tar.bz2
relx-66ca6c7601519862f7cad15ecab545b7c5643e61.zip
Merge pull request #321 from davebest/link_overlay
support symbolic link overlays in dev_mode
Diffstat (limited to 'src/rlx_prv_archive.erl')
-rw-r--r--src/rlx_prv_archive.erl6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/rlx_prv_archive.erl b/src/rlx_prv_archive.erl
index 7ed8f4d..3ed34f8 100644
--- a/src/rlx_prv_archive.erl
+++ b/src/rlx_prv_archive.erl
@@ -133,7 +133,7 @@ update_tar(State, TempDir, OutputDir, Name, Vsn, ErtsVersion) ->
_ ->
[{"lib", filename:join(TempDir, "lib")},
{"erts-"++ErtsVersion, filename:join(OutputDir, "erts-"++ErtsVersion)}]
- end]++OverlayFiles, [compressed]),
+ end]++OverlayFiles, [dereference,compressed]),
ec_cmd_log:info(rlx_state:log(State),
"tarball ~s successfully created!~n", [TarFile]),
ec_file:remove(TempDir, [recursive]),
@@ -149,6 +149,8 @@ overlay_files(OverlayVars, Overlay, OutputDir) ->
{ec_cnv:to_list(File), ec_cnv:to_list(filename:join(OutputDir, File))}
end || O <- Overlay, filter(O)].
+to({link, _, To}) ->
+ To;
to({copy, _, To}) ->
To;
to({mkdir, To}) ->
@@ -158,6 +160,8 @@ to({template, _, To}) ->
filter({_, _, "bin/"++_}) ->
false;
+filter({link, _, _}) ->
+ true;
filter({copy, _, _}) ->
true;
filter({mkdir, _}) ->