@@ -37,8 +37,15 @@ function show(io::IO, job::DFJob)
3737 fns = string .(fieldns)
3838 insert! (fns, 2 , " local_dir" )
3939 insert! (fs, 2 , main_job_dir (job))
40- push! (fieldns, :available_versions )
41- push! (fns, join (string .(versions (job)), " , " ))
40+ push! (fns, " available versions" )
41+ push! (fs, join (string .(versions (job)), " , " ))
42+ if haskey (job. metadata, :timestamp )
43+ push! (fns, " last submission" )
44+ push! (fs, string (round (job. metadata[:timestamp ], Dates. Second)))
45+ end
46+ push! (fns, " running" )
47+ is_running = isrunning (job)
48+ push! (fs, string (is_running))
4249 lfns = maximum (length .(fns)) + maximum (length .(fs)) + 4
4350 line = " +"
4451 for i in 1 : div (lfns, 2 )+ 1
@@ -69,19 +76,17 @@ function show(io::IO, job::DFJob)
6976 dfprintln (io, crayon " cyan" , " |" , reset)
7077 end
7178 is = calculations (job)
79+ last = last_running_calculation (job)
7280 if ! isempty (is)
7381 dfprintln (io, crayon " cyan" , line, reset)
7482 dfprintln (io, reset, " (" , crayon " green" , " scheduled" , reset, " , " , crayon " red" ,
7583 " not scheduled" , reset, " )" )
84+ dfprintln (io)
7685 ln = maximum (length .(string .(name .(is))))
7786 for (si, i) in enumerate (is)
7887 n = name (i)
79- l = length (n)
80- for j in 1 : ln- l
81- n *= " "
82- end
8388 cr = i. run ? crayon " green" : crayon " red"
84- dfprint (io, cr, " \t\t $n \n " )
89+ dfprint (io, cr, i == last ? (is_running ? " \t $n <- running \n " : " \t $n <- ran last \n " ) : " \t $n \n " )
8590 end
8691 end
8792 return dfprint (io, reset)
0 commit comments