diff options
-rw-r--r-- | Makefile | 15 | ||||
-rw-r--r-- | lib/sbin/ParamLatex.pl | 31 | ||||
-rw-r--r-- | lib/sbin/ThornGuide.pl | 3 |
3 files changed, 39 insertions, 10 deletions
@@ -16,7 +16,7 @@ # # # @enddesc -# @version $Id: Makefile,v 1.107 2001-04-09 10:19:12 allen Exp $ +# @version $Id: Makefile,v 1.108 2001-04-11 10:39:17 allen Exp $ # @@*/ ################################################################################## @@ -345,6 +345,7 @@ endif @echo " thorninfo - give information about all available " @echo " thorns." @echo " UsersGuide - creates users manual UsersGuide.ps." + @echo " ThornGuide - creates the thorn manual ThornGuide.ps" @echo " <anything else> - prompts to create such a configuration." @echo $(DIVIDER) @@ -796,6 +797,18 @@ UsersGuide: (cd doc/UsersGuide; latex UsersGuide.tex > $NULL_DEVICE; latex UsersGuide.tex > $NULL_DEVICE; dvips ./UsersGuide.dvi -o $(CCTK_HOME)/UsersGuide.ps >& $NULL_DEVICE) ; cd $(CCTK_HOME); @echo $(DIVIDER) +# Make the ThornGuide, new addition + +.PHONY: ThornGuide.ps +ThornGuide.ps: ThornGuide + +.PHONY: ThornGuide +ThornGuide: + @echo $(DIVIDER) + @echo Creating thorn documentation ThornGuide.ps + ($(PERL) -s lib/sbin/ParamLatex.pl -processall -grouping=bythorn -outdir=doc/ThornGuide/ -section; $(PERL) -s lib/sbin/ThornGuide.pl -directory=arrangements/ -outdir=doc/ThornGuide/; cd doc/ThornGuide; cp ../UsersGuide/bincactus2.eps bincactus.eps; latex ThornGuide.tex > $NULL_DEVICE; latex ThornGuide.tex > $NULL_DEVICE; dvips ./ThornGuide.dvi -o $(CCTK_HOME)/ThornGuide.ps >& $NULL_DEVICE) ; cd $(CCTK_HOME); + @echo $(DIVIDER) + .PHONY: MaintGuide.ps MaintGuide.ps: MaintGuide diff --git a/lib/sbin/ParamLatex.pl b/lib/sbin/ParamLatex.pl index 0ef26f7f..aedb8225 100644 --- a/lib/sbin/ParamLatex.pl +++ b/lib/sbin/ParamLatex.pl @@ -73,12 +73,12 @@ if (! $outdir) { } else { if ($outdir =~ /^\//) { if (! -d "$outdir") { - mkdir($outdir, 0666); + mkdir($outdir, 0755); print STDERR "\nCreating directory: $outdir" if ($verbose); } } else { if (! -d "$start_directory/$outdir") { - mkdir("$start_directory/$outdir", 0666); + mkdir("$start_directory/$outdir", 0755); print STDERR "\nCreating directory: $start_directory/$outdir" if ($verbose); } } @@ -105,14 +105,18 @@ foreach $arrangement (sort @arrangements) { { if (($processall) || (($thorn eq $th) || ($arr eq $arrangement))) { - &StartDocument($thorn) if ((! $dump) && ($grouping eq "bythorn")); - $$thorn{$thorn} = "${directory}/${arrangement}/${thorn}"; - %parameter_database = &create_parameter_database(%$thorn); - &ReadLatexDatabase(%parameter_database); - &FormatTable; + if (-e "$directory$arrangement/${thorn}/param.ccl") { + &StartDocument($thorn) if ((! $dump) && ($grouping eq "bythorn")); - &EndDocument if ((! $dump) && ($grouping eq "bythorn")); + $$thorn{$thorn} = "${directory}${arrangement}/${thorn}"; + %parameter_database = &create_parameter_database(%$thorn); + $killme = &ReadLatexDatabase(%parameter_database); + &FormatTable; + + undef %$killme; + &EndDocument if ((! $dump) && ($grouping eq "bythorn")); + } } } &EndDocument if ((! $dump) && ($grouping eq "byarrangement")); @@ -160,6 +164,7 @@ sub ReadLatexDatabase foreach $field (sort keys %parameter_database) { + &Clean; ################# # ADD TO SCOPES # @@ -205,6 +210,7 @@ sub ReadLatexDatabase } } } + return $name; } ## END :ReadLatexDatabase: ######################################################################### @@ -338,6 +344,9 @@ sub LatexTableElement { $name =~ s/\_/\\\_/g; # print STDERR "$name\n"; $description =~ s/\_/\\\_/g; + + # new addition 4/2001 + $description =~ s/\^/\\\^/g; print "$table{\"thorn\"}"; print "\\begin\{tabular*\}\{$width\}\{|c|c|c|\@\{\\extracolsep\{\\fill\}\}r|\} \\hline \n"; @@ -363,6 +372,11 @@ sub LatexTableElement { $tempvar2 = $$table{"range $i range"}; $tempvar2 =~ s/\_/\\\_/g; + + # new addition 4/2001 + $tempvar2 =~ s/\^/\\\^/g; + $tempvar2 =~ s/\$/\\\$/g; + print "$tempvar2 & $tempvar & \\\\ \\hline \n"; } print "\\end\{tabular*\} \n\n"; @@ -460,3 +474,4 @@ sub Dump { ######################################################################### sub Clean { } ## END :Clean: + diff --git a/lib/sbin/ThornGuide.pl b/lib/sbin/ThornGuide.pl index 93c935e5..7d46173d 100644 --- a/lib/sbin/ThornGuide.pl +++ b/lib/sbin/ThornGuide.pl @@ -168,6 +168,7 @@ if ($level eq "all_arr") { &Output_Bottom; print STDERR "\nFinished\n" if ($verbose); +print "\n"; ####################### ## END OF MAIN STUFF ## ####################### @@ -433,7 +434,7 @@ print OUT <<EOC; \\rule{\\linewidth}{1mm} \\vspace*{\\stretch{2}} \\begin{center} -\\includegraphics[angle=0,width=5cm]{../UsersGuide/bincactus.eps} +\\includegraphics[angle=0,width=5cm]{bincactus.eps} \\end{center} \\vspace*{\\stretch{2}} \\begin{center} |