chore(appup): minor fixes to update_appup.escript
- Fixes clause error on `create_stub/1`. - Small optimization: do not download the same file multiple times with `wget`.
This commit is contained in:
parent
2e26b8dfed
commit
c950566294
|
@ -154,7 +154,7 @@ download_prev_release(Tag, #{binary_rel_url := {ok, URL0}, clone_url := Repo}) -
|
||||||
Dir = filename:basename(Repo, ".git") ++ [$-|Tag],
|
Dir = filename:basename(Repo, ".git") ++ [$-|Tag],
|
||||||
Filename = filename:join(BaseDir, Dir),
|
Filename = filename:join(BaseDir, Dir),
|
||||||
Script = "mkdir -p ${OUTFILE} &&
|
Script = "mkdir -p ${OUTFILE} &&
|
||||||
wget -O ${OUTFILE}.zip ${URL} &&
|
wget -c -O ${OUTFILE}.zip ${URL} &&
|
||||||
unzip -n -d ${OUTFILE} ${OUTFILE}.zip",
|
unzip -n -d ${OUTFILE} ${OUTFILE}.zip",
|
||||||
Env = [{"TAG", Tag}, {"OUTFILE", Filename}, {"URL", URL}],
|
Env = [{"TAG", Tag}, {"OUTFILE", Filename}, {"URL", URL}],
|
||||||
bash(Script, Env),
|
bash(Script, Env),
|
||||||
|
@ -303,7 +303,7 @@ create_stub(App) ->
|
||||||
AppupFile = filename:basename(AppSrc) ++ ".appup.src",
|
AppupFile = filename:basename(AppSrc) ++ ".appup.src",
|
||||||
Default = {<<".*">>, []},
|
Default = {<<".*">>, []},
|
||||||
render_appfile(AppupFile, [Default], [Default]),
|
render_appfile(AppupFile, [Default], [Default]),
|
||||||
AppupFile;
|
{ok, AppupFile};
|
||||||
undefined ->
|
undefined ->
|
||||||
false
|
false
|
||||||
end.
|
end.
|
||||||
|
|
Loading…
Reference in New Issue