S10path.m 771 Bytes
Newer Older
Günter Windau's avatar
Günter Windau committed
1 2
% Set up matlab path for the biofysica toolbox
pathdirs = { ...
3
   biofysica_root
Günter Windau's avatar
Günter Windau committed
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
   };

for i = 1:size(pathdirs,1)
   d = pathdirs{i};
   if exist(d,'dir')
      p=genpath(d);
      addpath(p);

      exclude_d=[d '/init.d'];
      exclude_p=genpath(exclude_d);
      rmpath(exclude_p);

      exclude_d=[d '/.svn'];
      exclude_p=genpath(exclude_d);
      rmpath(exclude_p);

      exclude_d=[d '/.git'];
      exclude_p=genpath(exclude_d);
      rmpath(exclude_p);

24 25 26 27
      exclude_d=[d '/liblsl'];
      exclude_p=genpath(exclude_d);
      rmpath(exclude_p);

Günter Windau's avatar
Günter Windau committed
28 29 30 31
      % disp(['added directory ', d, ' to the MATLAB path']);
   else
      disp(['directory ', d, ' does not exist, not added to the MATLAB path']);
   end
Günter Windau's avatar
Günter Windau committed
32
   clear pathdirs d p exclude_d i exclude_p
Günter Windau's avatar
Günter Windau committed
33 34 35
end