[LON-CAPA-cvs] cvs: loncom /interface printout.pl

sakharuk lon-capa-cvs@mail.lon-capa.org
Thu, 14 Aug 2003 14:46:53 -0000


sakharuk		Thu Aug 14 10:46:53 2003 EDT

  Modified files:              
    /loncom/interface	printout.pl 
  Log:
  Index section isprintable for the separate resource. 
  
  
Index: loncom/interface/printout.pl
diff -u loncom/interface/printout.pl:1.32 loncom/interface/printout.pl:1.33
--- loncom/interface/printout.pl:1.32	Wed Aug 13 11:29:39 2003
+++ loncom/interface/printout.pl	Thu Aug 14 10:46:52 2003
@@ -49,7 +49,13 @@
       my $path_file = $1.'/';
       chdir $path_file;
       system("latex $name_file 1>/dev/null 2>/dev/null");
-      if ($selectionmade>10) {system("latex $name_file 1>/dev/null 2>/dev/null");} #to create tableof contents
+      if ($selectionmade>=10) {system("latex $name_file 1>/dev/null 2>/dev/null");} #to create table of contents
+      my $idxname=$name_file;
+      $idxname=~s/\.tex$/\.idx/;
+      if ($selectionmade>=100) {
+	  system("makeindex $idxname");
+	  system("latex $name_file 1>/dev/null 2>/dev/null");
+      } #to create index
       #Do we have a latex error in the log file?
       my $logfilename = $texfile;
       $logfilename =~ s/\.tex$/\.log/;