Changeset 24995


Ignore:
Timestamp:
06/10/20 10:04:28 (5 years ago)
Author:
Eric.Larour
Message:

CHG: if you include an 'End' step, it will stop listing further
steps, nice if you have a very large runme file.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/scripts/ol.m

    r24856 r24995  
    44
    55        range=getfieldvalue(options,'<',Inf);
     6        file=getfieldvalue(options,'file','runme.m');
    67
    78        %Open runme.m file and read line by line
    8         fid=fopen('runme.m','r');
     9        fid=fopen(file,'r');
    910
    1011        tline = fgets(fid);
     
    1516                        lastchar = strfind(tline,')');
    1617                        lastchar = lastchar(end)-1;
     18                        string=tline(17:lastchar-1);
     19                        if strcmpi(string,'End'),
     20                                return;
     21                        end
    1722                        disp(sprintf('%2i: %s',count,tline(16:lastchar)));
    1823                        if count>range,
Note: See TracChangeset for help on using the changeset viewer.