#!/usr/local/bin/perl
#   20 Nov 98 - palm@itu.ch

require "ctime.pl";

$filename="99-05-BM-doc-list.txt";
$meet = "BM";

open( OUT, ">00_doc_list.html" ) || die "Can't open file: html out\n";
open( ONTIME, "ontime_doc.txt" ) || die "Can't open file: ontime_doc.txt\n";

printf OUT "<HTML>\n";
printf OUT "<HEAD><TITLE>SG15/Q4 May 99 Doc List</title></head>\n";
printf OUT "<BODY bgcolor=white>\n";
printf OUT "<IMG SRC=itu.jpg ALIGN=RIGHT>\n";
printf OUT "<H1>SG15/Q4 May 99 (Boston) Document List</H1><P><HR><P>\n";
#printf OUT "This is an experimental page.<p>\n";

printf OUT "<a href=\"../00_SG15Q4_home_page.html\">Return to Q4/15 Home page</a><P>\n";

printf OUT "Contribution <a href=\"http://ties.itu.ch/ties-cgi/palm/docreq.shtml\">Document Number Assignment</a> & \n";
printf OUT "<a href=\"http://ties.itu.ch/ties-cgi/palm/file-upload.shtml\">File Upload</a> pages.<P>\n";

printf OUT "If a doc link does not work, the file may not be uploaded yet or\n";
printf OUT "the filename itself might be nonstandard, please check the <a href=\".\">raw list</a>.<BR>\n";

printf OUT "Questions and comments about this page should be sent to: ";
printf OUT "<a href=\"mailto: palm\@itu.ch\">Steve Palm (palm\@itu.ch)</a> <P> \n";


printf OUT "<P><HR width = 50%%><P>\n";

printf OUT "Misc. meeting and local information is ";
printf OUT "<a href=\"00_local_info.html\">here</a> <P> \n";
#printf OUT "Meeting Announcement: ";
#printf OUT "<a href=\"http://www.itu.ch/itudoc/itu-t/com15/coll.html\">Collective Letters</a> <P> \n";

printf OUT "This page was generated at %s JST<P>\n", &ctime(time);
printf OUT "<P>\n";



printf OUT "Quick Jump to Agenda areas:<br>\n";
printf OUT "<Table>\n";

printf OUT "<tr><TD><A href=#shdsl>G.<font color=darkred>shdsl</font></a>\n";
printf OUT "    <TD><A href=#vdsl>G.<font color=magenta>vdsl</font></a>  \n";
printf OUT "    <TD><A href=#ref.bis>G.ref.bis</a>\n";
printf OUT "    <TD><A href=#test.bis>G.<font color=purple>test</font>.bis</a>\n";
printf OUT "    <TD><A href=#ploam.bis>G.<font color=green>ploam</font>.bis</a> </tr> \n";

printf OUT "<tr><TD><A href=#hs.bis>G.<font color=grey>hs</font>.bis</a> \n";
printf OUT "    <TD><A href=#lite.bis>G.<font color=red>lite</font>.bis</a>\n";
printf OUT "    <TD><A href=#dmt.bis>G.<font color=orange>dmt</font>.bis</a>\n";
printf OUT "    <TD><A href=#gen.bis>G.<font color=orange>gen</font>.bis (G.lite.bis/G.dmt.bis)</a> </tr>\n";

printf OUT "<TR><TD><A href=#admin>Admin</a>\n";
printf OUT "    <TD><A href=#ipr>IPR</a>\n";
printf OUT "    <TD><A href=#ref>G.ref/G.995.1</a>\n";
printf OUT "    <TD><A href=#test>G.<font color=purple>test</font>/G.996.1</a>\n";
printf OUT "    <TD><A href=#ploam>G.<font color=green>ploam</font>/G.997.1</a> </tr> \n";

printf OUT "<tr><TD><A href=#hs>G.<font color=grey>hs</font>/G.994.1</a> \n";
printf OUT "    <TD><A href=#lite>G.<font color=red>lite</font>/G.992.2</a>\n";
printf OUT "    <TD><A href=#dmt>G.<font color=orange>dmt</font>/G.992.1</a>\n";
printf OUT "    <TD><A href=#gen>G.<font color=orange>gen</font> (G.lite/G.dmt)</a>\n";
printf OUT "    <TD><A href=#hdsl>G.hdsl/G.991.1</a></tr>\n";

printf OUT "</table>\n";
printf OUT "<P>\n";


printf OUT "<Table border=1>\n";
printf OUT "<TR><TH>Num.<TH>Source<TH>Area<TH>Title<TH>Filename</TR>\n";

printf OUT "<TR><TD>-<TD>Rapporteur Question 4/15<TD>Admin<TD>May 99 Document List<TD>\n";
printf OUT "<A href=\"99-05-BM-doc-list.doc\">99-05-BM-doc-list.doc</a></TR>\n ";

printf OUT "<TR><TD>-<TD>Steve Palm<TD>Admin<TD>May 99 Informal Document List<TD>\n";
printf OUT "<A href=\"99-05-BM-doc-list.txt\">99-05-BM-doc-list.txt</a></TR>\n ";

printf OUT "<TR><TD>-<TD>Rapporteur Question 4/15<TD>Admin<TD>May 99 Roster List<TD>\n";
printf OUT "<A href=\"Roster-May99.doc\">Roster-May99.doc</a></TR>\n ";

printf OUT "<TR><TD>C15-131<TD>TSB<TD>G.dmt<TD>G.992.1 White Contribution from TSB<TD>\n";
printf OUT "<A href=\"131_ww7.zip\">131_ww7.zip</a> ";
printf OUT "<A href=\"c15-131e.doc\">c15-131e.doc</a> ";
printf OUT "</TR>\n ";

printf OUT "<TR><TD>C15-136<TD>TSB<TD>G.lite<TD>G.992.2 White Contribution from TSB<TD>\n";
printf OUT "<A href=\"136_ww7.zip\">136_ww7.zip</a> ";
printf OUT "<A href=\"c15-136e.doc\">c15-136e.doc</a> ";
printf OUT "</TR>\n ";

printf OUT "<TR><TD>C15-134<TD>TSB<TD>G.hs<TD>G.994.1 White Contribution from TSB<TD>\n";
printf OUT "<A href=\"134_ww7.zip\">134_ww7.zip</a> ";
printf OUT "<A href=\"c15-134e.doc\">c15-134e.doc</a> ";
printf OUT "</TR>\n ";

printf OUT "<TR><TD>C15-132<TD>TSB<TD>G.ref<TD>G.995.1 White Contribution from TSB<TD>\n";
printf OUT "<A href=\"132_ww7.zip\">132_ww7.zip</a> ";
printf OUT "<A href=\"c15-132e.doc\">c15-132e.doc</a> ";
printf OUT "</TR>\n ";

printf OUT "<TR><TD>C15-133<TD>TSB<TD>G.test<TD>G.996.1 White Contribution from TSB<TD>\n";
printf OUT "<A href=\"133_ww7.zip\">133_ww7.zip</a> ";
printf OUT "<A href=\"c15-133e.doc\">c15-133e.doc</a> ";
printf OUT "</TR>\n ";

printf OUT "<TR><TD>C15-135<TD>TSB<TD>G.ploam<TD>G.997.1 White Contribution from TSB<TD>\n";
printf OUT "<A href=\"135_ww7.zip\">135_ww7.zip</a> ";
printf OUT "<A href=\"c15-135e.doc\">c15-135e.doc</a> ";
printf OUT "</TR>\n ";


#Read the list of ontime file uploads
while (<ONTIME>) {
  $ontime[$_] = 1;
}
close( ONTIME );




open( TC_FILE, $filename ) || die "Can't open file: $filename\n";

#Read the doc list
while (<TC_FILE>) {

  # Truncate the 8th bits
  tr/\200-\377/\000-\177/;

  # substitute color for some keywords
  s#G.hs#<font color=grey>G.hs</font>#gi;   
  s#G.994.1#<font color=grey>G.994.1</font>#gi;   
  s#G.lite#<font color=red>G.lite</font>#gi;   
  s#G.992.2#<font color=red>G.992.2</font>#gi;   
  s#G.gen#<font color=orange>G.gen</font>#gi;   
  s#G.dmt#<font color=orange>G.dmt</font>#gi;   
  s#G.992.1#<font color=orange>G.992.1</font>#gi;   
  s#G.test#<font color=purple>G.test</font>#gi;   
  s#G.996.1#<font color=purple>G.996.1</font>#gi;   
  s#G.ploam#<font color=green>G.ploam</font>#gi;   
  s#G.997.1#<font color=green>G.997.1</font>#gi;   
  s#G.vdsl#<font color=magenta>G.vdsl</font>#gi;   
  s#G.shdsl#<font color=darkred>G.shdsl</font>#gi;   
  s#Withdrawn#<B><i>Withdrawn</i></B>#gi;   

  chop;
  ($num, $source, $title, $fname, $ituname) = split('\#');

  printf "X%sXXXX%sX \n", $num, $source;

  printf OUT "<TR>\n";
#  printf OUT "<TD>%03u\n", $num;
  printf OUT "<TD>%s\n", $num;
  printf OUT "<TD>%s\n", $source;
  
  #parse for the subject area in the Title
  ($area, $title2) = split(':',$title);
  printf OUT "<TD>%s\n", $area;
  printf OUT "<TD>%s", $title2;

  printf OUT "<TD>";
  printf OUT "<font color=orange>*</font> " if  $ontime[$num]; # Gold star
  printf OUT "Withdrawn" if ($title =~ /withdrawn/i) ;

  #check if various doc formats and revisions exist
  &exist_sub;

  printf OUT "</TR>\n\n";

} # while

printf OUT "</Table>\n";
close( TC_FILE );



#Now make the Agenda...

open( TC_FILE, $filename ) || die "Can't open file 2nd time\n";

while (<TC_FILE>) {

  # Truncate the 8th bits
  tr/\200-\377/\000-\177/;

  chop;
  ($num, $source, $title, $fname, $ituname) = split('\#');

  #printf "X%sXXXX%sX \n", $num, $source;
  #parse for the subject area in the Title
  ($area, $title2) = split(':',$title);
  printf "Area: %s\n", $area;
  
  if ( $area eq 'Admin'  && !($title =~ /withdrawn/i) )  { $admin_string .= sprintf( "%s, ", $num );  }   
  if ( $area eq 'IPR'    && !($title =~ /withdrawn/i) )  { $ipr_string   .= sprintf( "%s, ", $num );  }   
  if ( $area eq 'G.shdsl'&& !($title =~ /withdrawn/i) )  { $shdsl_string .= sprintf( "%s, ", $num );  } 
  if ( $area eq 'G.vdsl' && !($title =~ /withdrawn/i) )  { $vdsl_string  .= sprintf( "%s, ", $num );  }

  if ( $area eq 'G.gen.bis'  && !($title =~ /withdrawn/i) )  { $gen_bis_string   .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.lite.bis' && !($title =~ /withdrawn/i) )  { $lite_bis_string  .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.ploam.bis'&& !($title =~ /withdrawn/i) )  { $ploam_bis_string .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.test.bis' && !($title =~ /withdrawn/i) )  { $test_bis_string  .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.dmt.bis'  && !($title =~ /withdrawn/i) )  { $dmt_bis_string   .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.hs.bis'   && !($title =~ /withdrawn/i) )  { $hs_bis_string    .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.ref.bis'  && !($title =~ /withdrawn/i) )  { $ref_bis_string   .= sprintf( "%s, ", $num );  }

  if ( $area eq 'G.gen'  && !($title =~ /withdrawn/i) )  { $gen_string   .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.lite' && !($title =~ /withdrawn/i) )  { $lite_string  .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.ploam'&& !($title =~ /withdrawn/i) )  { $ploam_string .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.test' && !($title =~ /withdrawn/i) )  { $test_string  .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.hdsl' && !($title =~ /withdrawn/i) )  { $hdsl_string  .= sprintf( "%s, ", $num );  } 
  if ( $area eq 'G.dmt'  && !($title =~ /withdrawn/i) )  { $dmt_string   .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.hs'   && !($title =~ /withdrawn/i) )  { $hs_string    .= sprintf( "%s, ", $num );  }
  if ( $area eq 'G.ref'  && !($title =~ /withdrawn/i) )  { $ref_string   .= sprintf( "%s, ", $num );  }

  if ( $area eq 'Other'  && !($title =~ /withdrawn/i) )  { $other_string .= sprintf( "%s, ", $num );  }

} # while


printf OUT "<HR width=50%%><P>\n";

printf OUT "<H2>Brief Agenda:</h2>\n";

printf OUT "<Table border=1>\n";
printf OUT "<TR><TH>Area<TH>Rec<TH><TH>Contribution Numbers</TR>\n";

printf OUT "<TR><TD>Admin<TD>.<TD><A href=#admin>details</a><TD>%s</tr>\n", $admin_string;
printf OUT "<TR><TD>IPR<TD>.<TD><A href=#ipr>details</a><TD>%s</tr>\n", $ipr_string;

printf OUT "<TR><TD><font color=red>G.lite.bis</font><TD>-<TD><A href=#lite.bis>details</a><TD>%s</tr>\n", $lite_bis_string;
printf OUT "<TR><TD><font color=green>G.ploam.bis</font><TD>-<TD><A href=#ploam.bis>details</a><TD>%s</tr>\n",  $ploam_bis_string;
printf OUT "<TR><TD><font color=purple>G.test.bis</font><TD>-<TD><A href=#test.bis>details</a><TD>%s</tr>\n",  $test_bis_string;
printf OUT "<TR><TD><font color=orange>G.dmt.bis</font><TD>-<TD><A href=#dmt.bis>details</a><TD>%s</tr>\n", $dmt_bis_string;
printf OUT "<TR><TD><font color=grey>G.hs.bis</font><TD>-<TD><A href=#hs.bis>details</a><TD>%s</tr>\n",  $hs_bis_string;
printf OUT "<TR><TD>G.ref.bis<TD>-<TD><A href=#ref.bis>details</a><TD>%s</tr>\n", $ref_bis_string;
printf OUT "<TR><TD><font color=orange>G.gen.bis</font> (<font color=orange>G.dmt.bis</font> & <font color=red>G.lite.bis</font>)<TD>.<TD><A href=#gen.bis>details</a><TD>%s</tr>\n", $gen_bis_string;

printf OUT "<TR><TD><font color=red>G.lite</font><TD>G.992.2<TD><A href=#lite>details</a><TD>%s</tr>\n", $lite_string;
printf OUT "<TR><TD><font color=green>G.ploam</font><TD>G.997.1<TD><A href=#ploam>details</a><TD>%s</tr>\n",  $ploam_string;
printf OUT "<TR><TD><font color=purple>G.test</font><TD>G.996.1<TD><A href=#test>details</a><TD>%s</tr>\n",  $test_string;
printf OUT "<TR><TD>G.hdsl<TD>G.991.1<TD><A href=#hdsl>details</a><TD>%s</tr>\n", $hdsl_string;
printf OUT "<TR><TD><font color=orange>G.dmt</font><TD>G.992.1<TD><A href=#dmt>details</a><TD>%s</tr>\n", $dmt_string;
printf OUT "<TR><TD><font color=grey>G.hs</font><TD>G.994.1<TD><A href=#hs>details</a><TD>%s</tr>\n",  $hs_string;
printf OUT "<TR><TD>G.ref<TD>G.995.1<TD><A href=#ref>details</a><TD>%s</tr>\n", $ref_string;
printf OUT "<TR><TD><font color=orange>G.gen</font> (<font color=orange>G.dmt</font> & <font color=red>G.lite</font>)<TD>.<TD><A href=#gen>details</a><TD>%s</tr>\n", $gen_string;

printf OUT "<TR><TD><font color=darkred>G.shdsl</font><TD>.<TD><A href=#shdsl>details</a><TD>%s</tr>\n", $shdsl_string;
printf OUT "<TR><TD><font color=magenta>G.vdsl</font><TD>.<TD><A href=#vdsl>details</a><TD>%s</tr>\n", $vdsl_string;
#printf OUT "<TR><TD>Other<TD><A href=#other>details</a><TD>%s</tr>\n", $other_string;
printf OUT "</Table>\n<P>\n";

close( TC_FILE );


# Do each area
#  this really should be read once and sorted in memory... but for now
#  we read the file once for each area

######Area: Admin
printf OUT "<H2><A name=gen>Admin</h2>\n";
$area_name = "Admin";
&area_sub;

######Area: Liaison Statements
#printf OUT "<H2><A name=gen>Liaison Statements</h2>\n";
#$area_name = "LS";
#&area_sub_ls;

######Area: IPR
printf OUT "<H2><A name=ip>IPR</h2>\n";
$area_name = "IPR";
&area_sub;

######Area: G.lite.bis
printf OUT "<H2><A name=lite.bis><font color=red>G.lite.bis</font></h2>\n";
$area_name = "G.lite.bis";
&area_sub;

######Area: G.ploam.bis
printf OUT "<H2><A name=ploam.bis><font color=green>G.ploam.bis</font></h2>\n";
$area_name = "G.ploam.bis";
&area_sub;

######Area: G.test.bis
printf OUT "<H2><A name=test.bis><font color=purple>G.test.bis</font></h2>\n";
$area_name = "G.test.bis";
&area_sub;

######Area: G.dmt.bis
printf OUT "<H2><A name=dmt.bis><A name=dmt.bis><font color=orange>G.dmt.bis</font></h2>\n";
$area_name = "G.dmt.bis";
&area_sub;

######Area: G.hs.bis
printf OUT "<H2><A name=hs.bis><font color=grey>G.hs.bis</font></h2>\n";
$area_name = "G.hs.bis";
&area_sub;

######Area: G.ref.bis
printf OUT "<H2><A name=ref.bis>G.ref.bis</h2>\n";
$area_name = "G.ref.bis";
&area_sub;

######Area: general.bis
printf OUT "<H2><A name=gen.bis><font color=orange>G.gen.bis</font> (G.lite.bis & G.dmt.bis)</h2>\n";
$area_name = "G.gen.bis";
&area_sub;

######Area: G.shdsl
printf OUT "<H2><A name=shdsl><font color=darkred>G.shdsl</font></h2>\n";
$area_name = "G.shdsl";
&area_sub;

######Area: G.vdsl
printf OUT "<H2><A name=vdsl><font color=magenta>G.vdsl</font></h2>\n";
$area_name = "G.vdsl";
&area_sub;

######Area: G.lite
printf OUT "<H2><A name=lite><font color=red>G.lite</font> (G.992.2)</h2>\n";
$area_name = "G.lite";
&area_sub;

######Area: G.ploam
printf OUT "<H2><A name=ploam><font color=green>G.ploam</font> (G.997.1)</h2>\n";
$area_name = "G.ploam";
&area_sub;

######Area: G.test
printf OUT "<H2><A name=test><font color=purple>G.test</font> (G.996.1)</h2>\n";
$area_name = "G.test";
&area_sub;

######Area: G.hdsl
printf OUT "<H2><A name=hdsl>G.hdsl (G.991.1)</h2>\n";
$area_name = "G.hdsl";
&area_sub;

######Area: G.dmt
printf OUT "<H2><A name=dmt><A name=dmt><font color=orange>G.dmt</font> (G.992.1)</h2>\n";
$area_name = "G.dmt";
&area_sub;

######Area: G.hs
printf OUT "<H2><A name=hs><font color=grey>G.hs</font> (G.994.1)</h2>\n";
$area_name = "G.hs";
&area_sub;

######Area: G.ref
printf OUT "<H2><A name=ref>G.ref (G.995.1)</h2>\n";
$area_name = "G.ref";
&area_sub;

######Area: general
printf OUT "<H2><A name=gen><font color=orange>G.gen</font> (G.lite & G.dmt)</h2>\n";
$area_name = "G.gen";
&area_sub;

######Area: G.other
#printf OUT "<H2><A name=other>Other</h2>\n";
#$area_name = "Other";
#&area_sub;


# Trailer

printf OUT "<HR width=50%><P>\n";

printf OUT "<P>\n";
printf OUT "This page is automatically generated by a <A href=http://www.perl.com>PERL</A> \n";
printf OUT "<A href=\"doc_list_html.pl\">script</a>.<BR> ";
printf OUT "Filenames should be of the form: BM-xxx.rtf, BM-xxxR1.rtf, BM-xxx.pdf, BM-xxx.zip, BM-xxxR1.zip \n";
printf OUT "with strict regards for case.\n";
printf OUT "<BR>RTF and DOC files over a few hundred k bytes should be ZIPped\n";

printf OUT "</body></html>\n";

exit;



sub area_sub {
  open( TC_FILE, $filename ) || die "Can't open file: $filename 2nd time\n";

  printf OUT "<Table border=1>\n";
  printf OUT "<TR><TH>Num.<TH>Source<TH>Area<TH>Title<TH>Filename</TR>\n";

  while (<TC_FILE>) {

    # Truncate the 8th bits
    tr/\200-\377/\000-\177/;

    chop;
    ($num, $source, $title, $fname, $ituname) = split('\#');

    printf "X%sXXXX%sX \n", $num, $source;
    #parse for the subject area in the Title
    ($area, $title2) = split(':',$title);

    if ( $area eq $area_name && !($title =~ /withdrawn/i)  )     { 

       printf OUT "<TR>\n";
#       printf OUT "<TD>%03u\n", $num;
       printf OUT "<TD>%s\n", $num;
       printf OUT "<TD>%s\n", $source;
       printf OUT "<TD>%s\n", $area;
       printf OUT "<TD>%s", $title2;

       printf OUT "<TD>";
       printf OUT "<font color=orange>*</font> " if  $ontime[$num]; # Gold star
       printf OUT "Withdrawn" if ($title =~ /withdrawn/i) ;

       #check if various doc formats and revisions exist
       &exist_sub;

       printf OUT "</TR>\n\n";

    }  # if

  } # while

  printf OUT "</table><P>\n";

  close( TC_FILE );

}




sub exist_sub {


  printf OUT "<A href=\"%s-%s.zip\">%s-%s.zip</a> ",     $meet, $num, $meet, $num if -e sprintf "%s-%s.zip", $meet, $num;
  printf OUT "<A href=\"%s-%s.rtf\">%s-%s.rtf</a> ",     $meet, $num, $meet, $num if -e sprintf "%s-%s.rtf", $meet, $num;
  printf OUT "<A href=\"%s-%s.pdf\">%s-%s.pdf</a> ",     $meet, $num, $meet, $num if -e sprintf "%s-%s.pdf", $meet, $num;
  printf OUT "<A href=\"%s-%s.doc\">%s-%s.doc</a> ",     $meet, $num, $meet, $num if -e sprintf "%s-%s.doc", $meet, $num;

  printf OUT "<A href=\"%s-%sR1.zip\">%s-%sR1.zip</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR1.zip", $meet, $num;
  printf OUT "<A href=\"%s-%sR1.rtf\">%s-%sR1.rtf</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR1.rtf", $meet, $num;
  printf OUT "<A href=\"%s-%sR1.pdf\">%s-%sR1.pdf</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR1.pdf", $meet, $num;
  printf OUT "<A href=\"%s-%sR1.doc\">%s-%sR1.doc</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR1.doc", $meet, $num;

  printf OUT "<A href=\"%s-%sR2.zip\">%s-%sR2.zip</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR2.zip", $meet, $num;
  printf OUT "<A href=\"%s-%sR2.rtf\">%s-%sR2.rtf</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR2.rtf", $meet, $num;
  printf OUT "<A href=\"%s-%sR2.pdf\">%s-%sR2.pdf</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR2.pdf", $meet, $num;
  printf OUT "<A href=\"%s-%sR2.doc\">%s-%sR2.doc</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR2.doc", $meet, $num;

  printf OUT "<A href=\"%s-%sR3.zip\">%s-%sR3.zip</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR3.zip", $meet, $num;
  printf OUT "<A href=\"%s-%sR3.rtf\">%s-%sR3.rtf</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR3.rtf", $meet, $num;
  printf OUT "<A href=\"%s-%sR3.pdf\">%s-%sR3.pdf</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR3.pdf", $meet, $num;
  printf OUT "<A href=\"%s-%sR3.doc\">%s-%sR3.doc</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR3.doc", $meet, $num;

  printf OUT "<br><A href=\"%s-%s-nc.pdf\">%s-%s-(no change bars).pdf</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%s-nc.pdf", $meet, $num;
  printf OUT "<br><A href=\"%s-%s-nc.zip\">%s-%s-(no change bars).zip</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%s-nc.zip", $meet, $num;
  printf OUT "<br><A href=\"%s-%s-nc.doc\">%s-%s-(no change bars).doc</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%s-nc.doc", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR1-nc.pdf\">%s-%sR1-(no change bars).pdf</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR1-nc.pdf", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR1-nc.zip\">%s-%sR1-(no change bars).zip</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR1-nc.zip", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR2-nc.pdf\">%s-%sR2-(no change bars).pdf</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR2-nc.pdf", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR2-nc.zip\">%s-%sR2-(no change bars).zip</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR2-nc.zip", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR3-nc.pdf\">%s-%sR3-(no change bars).pdf</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR3-nc.pdf", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR3-nc.zip\">%s-%sR3-(no change bars).zip</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR3-nc.zip", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR4-nc.pdf\">%s-%sR4-(no change bars).pdf</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR4-nc.pdf", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR4-nc.zip\">%s-%sR4-(no change bars).zip</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR4-nc.zip", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR5-nc.pdf\">%s-%sR5-(no change bars).pdf</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR5-nc.pdf", $meet, $num;
  printf OUT "<br><A href=\"%s-%sR5-nc.zip\">%s-%sR5-(no change bars).zip</a> <Br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR5-nc.zip", $meet, $num;
  printf OUT "<A href=\"%s-%s-addendum.rtf\">%s-%s-addendum.rtf</a> <br>", $meet, $num, $meet, $num if -e sprintf "%s-%s-addendum.rtf", $meet, $num;
  printf OUT "<A href=\"%s-%sR1-Master.zip\">%s-%sR1-Master-Doc-Word.zip</a> <br>", $meet, $num, $meet, $num if -e sprintf "%s-%sR1-Master.zip", $meet, $num;
  printf OUT "<A href=\"%s-%s-Agenda.doc\">%s-%s-Agenda.doc</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%s-Agenda.doc", $meet, $num;
  printf OUT "<A href=\"%s-%sR1-Agenda.doc\">%s-%sR1-Agenda.doc</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR1-Agenda.doc", $meet, $num;
  printf OUT "<A href=\"%s-%sR2-Agenda.doc\">%s-%sR2-Agenda.doc</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%sR2-Agenda.doc", $meet, $num;
  printf OUT "<A href=\"%s-%s-Sg15tds98.doc\">%s-%s-Sg15tds98.doc</a> ", $meet, $num, $meet, $num if -e sprintf "%s-%s-Sg15tds98.doc", $meet, $num;

}

