diff options
author | Tristan Sloughter <t@crashfast.com> | 2015-04-22 21:51:11 -0500 |
---|---|---|
committer | Tristan Sloughter <t@crashfast.com> | 2015-04-22 21:54:14 -0500 |
commit | e5988f69e0fc577f9c759f0907bd8b6840851035 (patch) | |
tree | e9dd6e803dde1d5c1560a56adb8674e66a51149d | |
parent | 16e9b3ffa2ddd81e26238530fd1e25a54a42b7dc (diff) |
R15 support, replace unsetenv with putenv empty string
-rwxr-xr-x | bootstrap | 2 | ||||
-rw-r--r-- | src/rebar3.erl | 2 | ||||
-rw-r--r-- | test/rebar_profiles_SUITE.erl | 2 |
3 files changed, 4 insertions, 2 deletions
@@ -25,7 +25,7 @@ main(_Args) -> os:putenv("REBAR_PROFILE", "bootstrap"), {ok, State} = rebar3:run(["compile"]), reset_env(), - os:unsetenv("REBAR_PROFILE"), + os:putenv("REBAR_PROFILE", ""), %% Build erlydtl files (a hook on compile in the default profile) and escript file DepsPaths = rebar_state:code_paths(State, all_deps), code:add_pathsa(DepsPaths), diff --git a/src/rebar3.erl b/src/rebar3.erl index fbbda51..b0cc949 100644 --- a/src/rebar3.erl +++ b/src/rebar3.erl @@ -115,6 +115,8 @@ run_aux(State, RawArgs) -> State2 = case os:getenv("REBAR_PROFILE") of false -> State; + "" -> + State; Profile -> rebar_state:apply_profiles(State, [list_to_atom(Profile)]) end, diff --git a/test/rebar_profiles_SUITE.erl b/test/rebar_profiles_SUITE.erl index 59c65e9..2d03432 100644 --- a/test/rebar_profiles_SUITE.erl +++ b/test/rebar_profiles_SUITE.erl @@ -121,7 +121,7 @@ all_deps_code_paths(Config) -> ["compile"], {ok, [{app, Name} ,{dep, "a", "1.0.0"} ,{dep, "b", "2.0.0"}]}), - os:unsetenv("REBAR_PROFILE"), + os:putenv("REBAR_PROFILE", ""), Paths = rebar_state:code_paths(State, all_deps), Path = lists:reverse(["_build", "all_deps_test", "lib", "b", "ebin"]), |