Switch to strcmp
This commit is contained in:
@@ -98,18 +98,18 @@ function varargout = EASYconsole(varargin)
|
||||
|
||||
% User sanity check and warning
|
||||
if ~isempty(getenv('PROJECT_USER'))
|
||||
if ~equal(getenv('PROJECT_USER'), userName)
|
||||
if ~strcmp(getenv('PROJECT_USER'), userName)
|
||||
disp("WARNING: PROJECT_USER does not match the current namespace");
|
||||
end
|
||||
end
|
||||
|
||||
% Allow module to override hardcoded default EASY directory
|
||||
if ~isempty(getenv('EASY_DIR'))
|
||||
EASY_DIR=fullfile(getenv('EASY_DIR'));
|
||||
if ~strcmp(easyDir, EASY_DIR) % sanity check
|
||||
ed=fullfile(getenv('EASY_DIR'));
|
||||
if ~strcmp(easyDir, ed) % sanity check
|
||||
disp("WARNING: EASY_DIR does not match this script's hardcoded EASY location");
|
||||
disp("This is probably OK but if strange beahvior arises, we'll need to fix it in code");
|
||||
easyDir=EASY_DIR;
|
||||
disp("This is probably OK but this pathway is not well-tested");
|
||||
easyDir=ed;
|
||||
end
|
||||
fprintf('Using EASY script directory: %s from environment variable EASY_DIR\n', easyDir);
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user