mirror of
https://github.com/correl/rebar.git
synced 2024-11-23 11:09:55 +00:00
rebar_eunit_tests: avoid repetition
This commit is contained in:
parent
e3fe1c6903
commit
4f41e742d3
1 changed files with 3 additions and 2 deletions
|
@ -208,10 +208,11 @@ remove_tmp_dir(_) ->
|
|||
%% ====================================================================
|
||||
|
||||
prepare_rebar_script() ->
|
||||
{ok, _} = file:copy(?REBAR_SCRIPT, ?TMP_DIR ++ "rebar"),
|
||||
Rebar = ?TMP_DIR ++ "rebar",
|
||||
{ok, _} = file:copy(?REBAR_SCRIPT, Rebar),
|
||||
case os:type() of
|
||||
{unix, _} ->
|
||||
[] = os:cmd("chmod u+x " ++ ?TMP_DIR ++ "rebar");
|
||||
[] = os:cmd("chmod u+x " ++ Rebar);
|
||||
{win32, _} ->
|
||||
{ok, _} = file:copy(?REBAR_SCRIPT ++ ".bat",
|
||||
?TMP_DIR ++ "rebar.bat")
|
||||
|
|
Loading…
Reference in a new issue