7 |
#DIRECTORIES (ABSOLUTE PATHS) |
#DIRECTORIES (ABSOLUTE PATHS) |
8 |
$targetdir = "/u/httpd/html/devel/sealion/"; # Web site location |
$targetdir = "/u/httpd/html/devel/sealion/"; # Web site location |
9 |
$homedir = "/u/httpd/html/devel/buildweb/"; # This code dir |
$homedir = "/u/httpd/html/devel/buildweb/"; # This code dir |
10 |
$latexroot = $homedir."latex/"; # LaTeX pages |
$latexroot = $homedir."latex/"; # LaTeX pages |
11 |
$vdbroot = $homedir."vdb/"; # VDB pages |
$vdbroot = $homedir."vdb/"; # VDB pages |
12 |
$templatedir = $homedir."templates/"; # Conversion templates |
$templatedir = $homedir."templates/"; # Conversion templates |
13 |
$pfilesdir = $homedir."program_files/"; # Program/config files |
$pfilesdir = $homedir."program_files/"; # Program/config files |
14 |
|
|
15 |
# PROCESS COMMAND LINE ARGUMENTS |
# PROCESS COMMAND LINE ARGUMENTS |
16 |
foreach $_ (@ARGV) { |
foreach $_ (@ARGV) { |
17 |
if (/--targetdir=(.*)/) {$targetdir=endslash($1); |
if (/--targetdir=(.*)/) {$targetdir=endslash($1); |
18 |
print "Setting targetdir = $targetdir\n";}; |
print "Setting targetdir = $targetdir\n";}; |
19 |
if (/--homedir=(.*)/) {$homedir=endslash($1); |
if (/--homedir=(.*)/) { |
20 |
print "Setting homedir = $homedir\n";}; |
$homedir=endslash($1); |
21 |
|
#eh3 subdirectories of homedir |
22 |
|
$latexroot = $homedir."latex/"; # LaTeX pages |
23 |
|
$vdbroot = $homedir."vdb/"; # VDB pages |
24 |
|
$templatedir = $homedir."templates/"; # Conversion templates |
25 |
|
$pfilesdir = $homedir."program_files/"; # Program/config files |
26 |
|
print "Setting homedir = $homedir\n"; |
27 |
|
}; |
28 |
if (/--latexroot=(.*)/) {$latexroot=endslash($1); |
if (/--latexroot=(.*)/) {$latexroot=endslash($1); |
29 |
print "Setting latexroot = $latexroot\n";}; |
print "Setting latexroot = $latexroot\n";}; |
30 |
if (/--vdbroot=(.*)/) {$vdbroot=endslash($1); |
if (/--vdbroot=(.*)/) {$vdbroot=endslash($1); |
35 |
print "Setting pfilesdir = $pfilesdir\n";}; |
print "Setting pfilesdir = $pfilesdir\n";}; |
36 |
} |
} |
37 |
|
|
38 |
|
|
39 |
#DIRECTORIS WITHIN WEB SITE |
#DIRECTORIS WITHIN WEB SITE |
40 |
$webbase = "../"; |
$webbase = "../"; |
41 |
$latek2htmldir = "online_documents/"; |
$latek2htmldir = "online_documents/"; |
110 |
$notfound = 1; |
$notfound = 1; |
111 |
$j=0; |
$j=0; |
112 |
|
|
113 |
while (($j < $#htmlfiles) && ($notfound)) { |
while (($j <= $#htmlfiles) && ($notfound)) { |
114 |
open(THISHTML,$htmlfiles[$j]) || die("can't open $htmlfiles[$j]"); |
open(THISHTML,$htmlfiles[$j]) || die("can't open $htmlfiles[$j]"); |
115 |
|
|
116 |
while (<THISHTML>) { |
while (<THISHTML>) { |
160 |
### added by AJA: create a flag to indicate whether file has been associated |
### added by AJA: create a flag to indicate whether file has been associated |
161 |
# with a template (1 = no and 0 = yes) |
# with a template (1 = no and 0 = yes) |
162 |
$thisfile=0; |
$thisfile=0; |
163 |
while ($thisfile < $#htmlfiles) { |
while ($thisfile <= $#htmlfiles) { |
164 |
$htmlfileassociated[$thisfile]=1; |
$htmlfileassociated[$thisfile]=1; |
165 |
$thisfile++; |
$thisfile++; |
166 |
} # loop through file |
} # loop through file |
195 |
|
|
196 |
$pattern = $template2patternlist[$thispattern+1]; |
$pattern = $template2patternlist[$thispattern+1]; |
197 |
$thisfile=0; |
$thisfile=0; |
198 |
while ($thisfile < $#htmlfiles) { |
while ($thisfile <= $#htmlfiles) { |
199 |
open(THISHTML,$htmlfiles[$thisfile]) || die("can't open $htmlfiles[$thisfile]"); |
open(THISHTML,$htmlfiles[$thisfile]) || die("can't open $htmlfiles[$thisfile]"); |
200 |
while (<THISHTML>) { |
while (<THISHTML>) { |
201 |
if (/$pattern/ && $htmlfileassociated[$thisfile]){ |
if (/$pattern/ && $htmlfileassociated[$thisfile]){ |