Read the lastRunNumber file, find runs which happened since it.
Then create a runList file containing these runs, and overwrite lastRunNumber.
 
Definition at line 21 of file GetNextRunList.py.
   23     Read the lastRunNumber file, find runs which happened since it. 
   24     Then create a runList file containing these runs, and overwrite lastRunNumber. 
   27         last_run = 
int(
open(os.path.join(DATADIR, 
"lastRunNumber"), 
'r+').
read())
 
   32     open(os.path.join(DATADIR, 
"runList"), 
"w").
write(
"\n".
join(map(str, new_runs)))
 
   35         print(strftime(
"%d/%m/%Y %H:%M:%S"), 
"Nothing to do")
 
   38     last_run = new_runs[-1]
 
   39     open(os.path.join(DATADIR, 
"lastRunNumber"), 
"w").
write(
str(last_run)+
"\n")
 
   40     print(strftime(
"%d/%m/%Y %H:%M:%S"), 
"Wrote new runList. Last run is", last_run, new_runs)