From: Anthony Geay Date: Thu, 30 Jan 2020 09:22:29 +0000 (+0100) Subject: Revert "Revert "bos #18467 Minor correction to setenv.py"" X-Git-Tag: EMC2P_V_1_2_0^0 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=e2659baa98ce30772f17d5f9764fea3a069c65fa;p=modules%2Fkernel.git Revert "Revert "bos #18467 Minor correction to setenv.py"" This reverts commit 439d6e243818948a685809d0707a02aef93e4930. --- diff --git a/bin/setenv.py b/bin/setenv.py index 7ad4a8fb8..bb93ea8e1 100755 --- a/bin/setenv.py +++ b/bin/setenv.py @@ -241,8 +241,9 @@ def set_env(args, modules_list, modules_root_dir, silent=False, keepEnvironment= # ----------------------------------------------------------------------------- def main(silent=False, exeName=None): - args, modules_list, modules_root_dir = get_config(silent=silent, exeName=exeName) - set_env(args, modules_list, modules_root_dir, silent=silent) + keep_env = not os.getenv('SALOME_PLEASE_SETUP_ENVIRONMENT_AS_BEFORE') + args, modules_list, modules_root_dir = get_config(silent=silent, exeName=exeName, keepEnvironment=keep_env) + set_env(args, modules_list, modules_root_dir, silent=silent, keepEnvironment=keep_env) return args # -----------------------------------------------------------------------------