thread tests have a dependency on the thread lib
[tangerine.git] / scripts / jobclient.awk
blob7cf1c329db1b105e36a1edd03481a6d8c5cf15d1
1 BEGIN {
2 file=ENVIRON["HOME"] "/Mail/jobs"
3 IGNORECASE=1
5 while ((getline < file) > 0)
7 # Comment or empty line
8 if (match($0,/^#/) || $1=="")
9 continue;
11 for (t=0; t<ARGC; t++)
13 # Does this job match any of the ones we look for ?
14 if (match ($0,ARGV[t]))
16 # Job is not completed yet ?
17 if ($2!="DONE")
19 # Show description of job
20 if (NF > 3)
22 printf ("# ");
23 for (t=4; t<=NF; t++)
24 printf ("%s ", $t);
25 print ""
28 # Show what can be done with the job
29 if ($2=="FREE")
30 print "req "$1;
31 if ($2=="WORK" || $2=="FREE")
32 print "done "$1;
35 # Don't try to print the job twice
36 break;