Commit dab01614 authored by Turnhout, M.C. van's avatar Turnhout, M.C. van
Browse files

fix parsing of linux ~

parent 3bdcc0ad
......@@ -28,7 +28,7 @@ if ~isempty(regexp(filepath, '\', 'once'))
elseif ~isempty(regexp(filepath, '/', 'once'))
% this is a proper OS
idx = regexp(filepath, '/');
if idx(1) == 1
if idx(1) == 1 || strcmp(filepath(1), '~')
% this is an absolute path
datapath = filepath(1:idx(end)-1);
filename = filepath(idx(end)+1:end);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment