]>
Commit | Line | Data |
---|---|---|
410dc2c9 DM |
1 | #!/usr/bin/perl |
2 | ||
3 | use strict; | |
4 | use warnings; | |
5 | use Getopt::Long; | |
6 | use File::Path; | |
7 | use File::Basename; | |
8 | use IO::File; | |
9 | use Cwd; | |
10 | ||
11 | use JSON; | |
12 | ||
13 | my $verbose; | |
14 | my $keep_artifacts; | |
15 | ||
16 | my $release = '@RELEASE@'; | |
17 | ||
18 | my $clicmd = shift or | |
19 | die "no command specified\n"; | |
20 | ||
21 | my $data_str = ""; | |
22 | while (<main::DATA>) { $data_str .= $_; } | |
23 | ||
24 | my $fileinfo = decode_json($data_str); | |
25 | ||
26 | my $tmpprefix = '.asciidoc-pmg-tmp'.$$.'_'; | |
27 | ||
28 | my $adoc_source_dir = "/usr/share/pmg-doc-generator"; | |
29 | ||
30 | # inside pmg-docs source dir? | |
31 | if (-f "asciidoc-pmg.in" && -f "pmg-admin-guide.adoc") { | |
32 | $adoc_source_dir = getcwd(); | |
33 | } | |
34 | ||
35 | my $prepared_files = {}; | |
36 | ||
37 | my $man_target = 'man'; | |
38 | my $env_stack = []; | |
39 | my $env_skip = 0; | |
40 | ||
41 | my $online_help_links = { | |
42 | 'pmg_service_daemons' => { | |
43 | link => '/pmg-docs/index.html#_service_daemons', | |
44 | title => 'Service Daemons', | |
45 | }, | |
46 | 'pmg_documentation_index' => { | |
47 | link => '/pmg-docs/index.html', | |
85e3a2e5 | 48 | title => 'Proxmox Mail Gateway Documentation Index', |
410dc2c9 DM |
49 | }, |
50 | 'pmg_admin_guide' => { | |
51 | link => '/pmg-docs/pmg-admin-guide.html', | |
85e3a2e5 | 52 | title => 'Proxmox Mail Gateway Administration Guide', |
410dc2c9 DM |
53 | }, |
54 | }; | |
55 | ||
56 | sub debug { | |
57 | my $msg = shift; | |
58 | ||
59 | return if !$verbose; | |
60 | ||
61 | print STDERR "asciidoc-pmg: $msg\n"; | |
62 | } | |
63 | ||
64 | sub push_environment { | |
65 | my ($env, $skip) = @_; | |
66 | ||
67 | $skip = 1 if $env_skip; | |
68 | $skip = 0 if !defined($skip); | |
69 | ||
70 | push @$env_stack, [$env, $skip]; | |
71 | ||
72 | $env_skip = $skip; | |
73 | } | |
74 | ||
75 | sub pop_environment { | |
76 | my ($env) = @_; | |
77 | ||
78 | my $last_stack_entry = pop @$env_stack; | |
79 | die "unable to pop env '$env'" if !defined($last_stack_entry); | |
80 | ||
81 | my ($last_env, $skip) = @$last_stack_entry; | |
82 | die "environment missmatch (${last_env} != $env)\n" if $last_env ne $env; | |
83 | ||
84 | if (!scalar(@$env_stack)) { | |
85 | $env_skip = 0; | |
86 | } else { | |
87 | my (undef, $skip) = @{$env_stack->[-1]}; | |
88 | $env_skip = $skip; | |
89 | } | |
90 | } | |
91 | ||
92 | my $files_for_cleanup = []; | |
93 | ||
94 | sub cleanup { | |
95 | ||
96 | return if $keep_artifacts; | |
97 | ||
98 | foreach my $file (@$files_for_cleanup) { | |
99 | unlink $file; | |
100 | } | |
101 | } | |
102 | ||
103 | sub replace_wiki_xref { | |
104 | my ($blockid, $text) = @_; | |
105 | ||
106 | my $link = $fileinfo->{blockid_target}->{wiki}->{$blockid}; | |
107 | my $reftext = $fileinfo->{reftext}->{wiki}->{$blockid}; | |
108 | ||
109 | die "unable to resolve wiki link (xref:$blockid)\n" | |
110 | if !defined($link); | |
111 | ||
112 | $text = $reftext if !length($text); | |
113 | ||
114 | die "xref: no text for wiki link '$blockid'\n" if !$text; | |
115 | ||
116 | return "$link\[$text\]"; | |
117 | } | |
118 | ||
119 | sub replace_default_xref { | |
120 | my ($blockid, $text) = @_; | |
121 | ||
122 | my $link = $fileinfo->{blockid_target}->{default}->{$blockid}; | |
123 | my $reftext = $fileinfo->{reftext}->{default}->{$blockid}; | |
124 | ||
125 | die "unable to resolve chapter link (xref:$blockid)\n" | |
126 | if !defined($link); | |
127 | ||
128 | $text = $reftext if !length($text); | |
129 | ||
130 | die "xref: no text for chapter link '$blockid'\n" if !$text; | |
131 | ||
132 | return "$link\[$text\]"; | |
133 | } | |
134 | ||
135 | sub replace_man_xref { | |
136 | my ($blockid, $text) = @_; | |
137 | ||
138 | my $link = $fileinfo->{blockid_target}->{manvolnum}->{$blockid}; | |
139 | my $reftext = $fileinfo->{reftext}->{manvolnum}->{$blockid}; | |
140 | ||
141 | die "unable to resolve man page link (xref:$blockid)\n" | |
142 | if !defined($link); | |
143 | ||
144 | $text = $reftext if !length($text); | |
145 | ||
146 | die "xref: no text for man page link '$blockid'\n" if !$text; | |
147 | ||
148 | my $section = $fileinfo->{mansection}->{manvolnum}->{$link}; | |
149 | die "link target is not a manual page" if !defined($section); | |
150 | ||
151 | ||
152 | if ($man_target eq 'html') { | |
153 | my $target = $link; | |
154 | $target =~ s/\.adoc//; | |
155 | $target .= ".$section"; | |
156 | return "link:${target}.html#${blockid}\[$text\]"; | |
157 | } elsif ($man_target eq 'man') { | |
158 | my $command = $link; | |
159 | $command =~ s/\.adoc//; | |
160 | return "\*${text}\* (man \*${command}\*($section))"; | |
161 | } else { | |
162 | die "internal error" | |
163 | } | |
164 | } | |
165 | ||
166 | sub replace_xref { | |
167 | my ($env, $blockid, $text) = @_; | |
168 | ||
169 | if ($env eq 'wiki') { | |
170 | return replace_wiki_xref($blockid, $text); | |
171 | } elsif ($env eq 'manvolnum') { | |
172 | if (($man_target eq 'man') || ($man_target eq 'html')) { | |
173 | return replace_man_xref($blockid, $text); | |
174 | } elsif ($man_target eq 'wiki') { | |
175 | return replace_wiki_xref($blockid, $text); | |
176 | } else { | |
177 | die "internal error" | |
178 | } | |
179 | } elsif ($env eq 'default') { | |
180 | return replace_default_xref($blockid, $text); | |
181 | } else { | |
182 | die "internal error"; | |
183 | } | |
184 | } | |
185 | ||
186 | sub prepare_adoc_file { | |
187 | my ($target_env, $filename, $attributes) = @_; | |
188 | ||
189 | return $prepared_files->{$filename} if defined($prepared_files->{$filename}); | |
190 | ||
191 | debug("prepare $filename"); | |
192 | ||
193 | my $dirname = dirname($filename); | |
194 | my $basename = basename($filename); | |
195 | ||
196 | my $outfilename = "$dirname/${tmpprefix}$basename"; | |
197 | ||
198 | $prepared_files->{$filename} = $outfilename; | |
199 | ||
200 | my $fh = IO::File->new("$filename", "r") or | |
201 | die "unable to open file '$filename' - $!\n"; | |
202 | ||
203 | my $outfh = IO::File->new("$outfilename", "w") or | |
204 | die "unable to open temporary file '$outfilename'\n"; | |
205 | ||
206 | push @$files_for_cleanup, $outfilename; | |
207 | ||
208 | while (defined (my $line = <$fh>)) { | |
209 | chomp $line; | |
210 | if ($line =~ m/^if(n?)def::(\S+)\[(.*)\]\s*$/) { | |
211 | my ($not, $env, $text) = ($1, $2, $3); | |
212 | die "unsuported ifdef usage - implement me" if $text; | |
213 | ||
214 | my $skip = !exists($attributes->{$env}) ? 1 : 0; | |
215 | $skip = ($skip ? 0 : 1 ) if $not; | |
216 | ||
217 | push_environment($env, $skip); | |
218 | next; | |
219 | } elsif ($line =~ m/^endif::(\S+)\[(.*)\]\s*$/) { | |
220 | my ($env, $text) = ($1, $2); | |
221 | die "unsuported ifdef usage - implement me" if $text; | |
222 | pop_environment($env); | |
223 | next; | |
224 | } | |
225 | ||
226 | next if $env_skip; | |
227 | ||
228 | if ($line =~ m/^include::(\S+)(\[.*\]\s*)$/) { | |
229 | my ($fn, $rest) = ($1, $2); | |
230 | debug("include $fn"); | |
231 | my $new_fn = prepare_adoc_file($target_env, $fn, $attributes); | |
232 | ||
233 | print $outfh "include::${new_fn}$rest\n"; | |
234 | next; | |
235 | } | |
236 | ||
237 | if ($line =~ m/xref:\S+?\[[^\]]*$/) { | |
238 | die "possible xref spanning multiple lines in '$filename':\n(line $.): $line\n"; | |
239 | } | |
240 | if ($line =~ m/<<((?!\>\>).)*$/) { | |
241 | die "possible xref spanning multiple lines in '$filename':\n(line $.): $line\n"; | |
242 | } | |
243 | # fix xrefs | |
244 | $line =~ s/xref:([^\s\[\]]+)\[([^\]]*)\]/replace_xref(${target_env},$1,$2)/ge; | |
245 | ||
246 | $line =~ s/<<([^\s,\[\]]+)(?:,(.*?))?>>/replace_xref(${target_env},$1,$2)/ge; | |
247 | ||
248 | print $outfh $line . "\n"; | |
249 | } | |
250 | ||
251 | return $outfilename; | |
252 | } | |
253 | ||
254 | sub compile_asciidoc { | |
255 | my ($env) = @_; | |
256 | ||
257 | my $outfile; | |
258 | ||
259 | GetOptions ("outfile=s" => \$outfile, | |
260 | "keep-artifacts" => \$keep_artifacts, | |
261 | "verbose" => \$verbose) or | |
262 | die("Error in command line arguments\n"); | |
263 | ||
264 | my $infile = shift(@ARGV) or | |
265 | die "no input file specified\n"; | |
266 | ||
267 | scalar(@ARGV) == 0 or | |
268 | die "too many arguments...\n"; | |
269 | ||
270 | my $outfilemap = $fileinfo->{outfile}->{$env}->{$infile} || | |
271 | die "no output file mapping for '$infile' ($env)"; | |
272 | ||
273 | if ($man_target eq 'html') { | |
274 | $outfilemap .= '.html'; | |
275 | } elsif ($man_target eq 'wiki') { | |
276 | $outfilemap .= '-plain.html'; | |
277 | } | |
278 | ||
279 | if (defined($outfile)) { | |
280 | die "wrong output file name '$outfile != $outfilemap' ($env)" | |
281 | if $outfile ne $outfilemap; | |
282 | } else { | |
283 | $outfile = $outfilemap; | |
284 | } | |
285 | ||
286 | defined($fileinfo->{titles}->{$env}) || | |
287 | die "unknown environment '$env'"; | |
288 | ||
289 | my $title = $fileinfo->{titles}->{$env}->{$infile} or | |
290 | die "unable to get title for '$infile'$env\n"; | |
291 | ||
292 | debug("compile $title"); | |
293 | ||
294 | my $leveloffset = 0; | |
295 | ||
296 | my $doctype = $fileinfo->{doctype}->{$env}->{$infile}; | |
297 | ||
298 | die "unable to get document type for '$infile'\n" | |
299 | if !defined($doctype); | |
300 | ||
301 | $leveloffset = - $doctype; | |
302 | ||
303 | my $date = `date`; | |
304 | chomp $date; | |
305 | ||
306 | my $attributes = { | |
307 | $env => undef, | |
308 | leveloffset => $leveloffset, | |
309 | revnumber => $release, | |
310 | revdate => $date, | |
311 | }; | |
312 | ||
313 | my $mansection = $fileinfo->{mansection}->{$env}->{$infile}; | |
314 | ||
315 | if ($env eq 'wiki') { | |
316 | } elsif ($env eq 'manvolnum') { | |
317 | die "undefined man section" if !defined($mansection); | |
318 | $attributes->{manvolnum} = $mansection; | |
319 | } elsif ($env eq 'default') { | |
320 | die "$infile: wrong doctype\n" if $doctype != 0; | |
321 | $attributes->{toc} = undef; | |
509eaa92 | 322 | $attributes->{toc2} = undef; |
410dc2c9 DM |
323 | } |
324 | ||
325 | if (!defined($outfile)) { | |
326 | $outfile = $infile; | |
327 | $outfile =~ s/\.adoc$//; | |
328 | if ($env eq 'manvolnum') { | |
329 | if (($man_target eq 'html') || ($man_target eq 'wiki')) { | |
330 | $outfile .= ".$mansection.html"; | |
331 | } else { | |
332 | $outfile .= ".$mansection"; | |
333 | } | |
334 | } else { | |
335 | $outfile .= ".html"; | |
336 | } | |
337 | } | |
338 | ||
339 | if (($env eq 'manvolnum') && ($man_target eq 'man')) { | |
340 | ||
341 | # asciidoc /etc/asciidoc/docbook-xsl/manpage.xsl skip REFERENCES | |
342 | # section like footnotes, so we cannot use a2x. | |
343 | # We use xmlto instead. | |
344 | ||
345 | my $cmd = ['asciidoc', '-dmanpage', '-bdocbook', | |
346 | '-f', "$adoc_source_dir/asciidoc/asciidoc-pmg.conf", | |
347 | '-a', 'docinfo1']; | |
348 | ||
349 | foreach my $key (keys %$attributes) { | |
350 | my $value = $attributes->{$key}; | |
351 | if (defined($value)) { | |
352 | push @$cmd, '-a', "$key=$value"; | |
353 | } else { | |
354 | push @$cmd, '-a', $key; | |
355 | } | |
356 | } | |
357 | ||
358 | push @$cmd, '--verbose' if $verbose; | |
359 | ||
360 | my $tmpxmlfile = "${outfile}.xml.tmp"; | |
361 | ||
362 | push @$cmd, '--out-file', $tmpxmlfile; | |
363 | ||
364 | push @$files_for_cleanup, $tmpxmlfile; | |
365 | ||
366 | my $new_infile = prepare_adoc_file($env, $infile, $attributes); | |
367 | ||
368 | push @$cmd, $new_infile; | |
369 | ||
370 | debug("run " . join(' ', @$cmd)); | |
371 | ||
372 | system(@$cmd) == 0 or | |
373 | die "aciidoc error"; | |
374 | ||
375 | $cmd = ['xmlto', 'man', $tmpxmlfile]; | |
376 | ||
377 | push @$cmd, '-v' if $verbose; | |
378 | ||
379 | debug("run " . join(' ', @$cmd)); | |
380 | ||
381 | system(@$cmd) == 0 or | |
382 | die "xmlto error"; | |
383 | ||
384 | } else { | |
385 | ||
386 | $attributes->{icons} = undef; | |
387 | $attributes->{'data-uri'} = undef; | |
388 | ||
389 | my $cmd = ['asciidoc', | |
390 | '-f', "$adoc_source_dir/asciidoc/asciidoc-pmg.conf", | |
391 | ]; | |
392 | ||
393 | if (($env eq 'wiki') || | |
394 | (($env eq 'manvolnum') && ($man_target eq 'wiki'))) { | |
395 | ||
396 | push @$cmd, '-b', "$adoc_source_dir/asciidoc/mediawiki"; | |
397 | } else { | |
398 | push @$cmd, '-b', "$adoc_source_dir/asciidoc/pmg-html"; | |
399 | } | |
400 | ||
401 | foreach my $key (keys %$attributes) { | |
402 | my $value = $attributes->{$key}; | |
403 | if (defined($value)) { | |
404 | push @$cmd, '-a', "$key=$value"; | |
405 | } else { | |
406 | push @$cmd, '-a', $key; | |
407 | } | |
408 | } | |
409 | ||
410 | push @$cmd, '--verbose' if $verbose; | |
411 | ||
412 | push @$cmd, '--out-file', $outfile; | |
413 | ||
414 | my $new_infile = prepare_adoc_file($env, $infile, $attributes); | |
415 | ||
416 | push @$cmd, $new_infile; | |
417 | ||
418 | debug("run " . join(' ', @$cmd)); | |
419 | ||
420 | system(@$cmd) == 0 or | |
421 | die "aciidoc error"; | |
422 | } | |
423 | } | |
424 | ||
425 | sub get_links { | |
426 | ||
427 | my $data = {}; | |
428 | ||
429 | foreach my $blockid (sort keys %{$fileinfo->{blockid_target}->{default}}) { | |
430 | my $link = $fileinfo->{blockid_target}->{default}->{$blockid}; | |
431 | my $reftitle = $fileinfo->{reftitle}->{default}->{$blockid}; | |
432 | my $reftext = $fileinfo->{reftext}->{default}->{$blockid}; | |
433 | die "internal error" if $link !~ m/^link:/; | |
434 | $link =~ s/^link://; | |
435 | ||
436 | my $file = $fileinfo->{blockid}->{default}->{$blockid}; | |
437 | die "internal error - no filename" if ! defined($file); | |
438 | my $title = $fileinfo->{titles}->{default}->{$file} || | |
439 | die "internal error - no title"; | |
440 | ||
441 | $data->{$blockid}->{title} = $title; | |
442 | $data->{$blockid}->{link} = $link; | |
443 | my $subtitle = $reftitle || $reftext; | |
444 | $data->{$blockid}->{subtitle} = $subtitle | |
445 | if $subtitle && ($title ne $subtitle); | |
446 | } | |
447 | ||
448 | return $data; | |
449 | } | |
450 | ||
451 | sub scan_extjs_file { | |
452 | my ($filename, $res_data) = @_; | |
453 | ||
454 | my $fh = IO::File->new($filename, "r") || | |
455 | die "unable to open '$filename' - $!\n"; | |
456 | ||
457 | debug("scan-extjs $filename"); | |
458 | ||
459 | while(defined(my $line = <$fh>)) { | |
460 | if ($line =~ m/\s+onlineHelp:\s*[\'\"](.*?)[\'\"]/) { | |
461 | my $blockid = $1; | |
462 | my $link = $fileinfo->{blockid_target}->{default}->{$blockid}; | |
463 | die "undefined blockid '$blockid' ($filename, line $.)\n" | |
464 | if !(defined($link) || defined($online_help_links->{$blockid})); | |
465 | ||
466 | $res_data->{$blockid} = 1; | |
467 | } | |
468 | } | |
469 | } | |
470 | ||
471 | if ($clicmd eq 'compile-wiki') { | |
472 | ||
473 | eval { compile_asciidoc('wiki'); }; | |
474 | my $err = $@; | |
475 | ||
476 | cleanup(); | |
477 | ||
478 | die $err if $err; | |
479 | ||
480 | } elsif ($clicmd eq 'compile-chapter') { | |
481 | ||
482 | eval { compile_asciidoc('default'); }; | |
483 | my $err = $@; | |
484 | ||
485 | cleanup(); | |
486 | ||
487 | die $err if $err; | |
488 | ||
489 | } elsif ($clicmd eq 'compile-man-html') { | |
490 | ||
491 | $man_target = 'html'; | |
492 | ||
493 | eval { compile_asciidoc('manvolnum'); }; | |
494 | my $err = $@; | |
495 | ||
496 | cleanup(); | |
497 | ||
498 | die $err if $err; | |
499 | ||
500 | } elsif ($clicmd eq 'compile-man-wiki') { | |
501 | ||
502 | $man_target = 'wiki'; | |
503 | ||
504 | eval { compile_asciidoc('manvolnum'); }; | |
505 | my $err = $@; | |
506 | ||
507 | cleanup(); | |
508 | ||
509 | die $err if $err; | |
510 | ||
511 | } elsif ($clicmd eq 'compile-man') { | |
512 | ||
513 | eval { compile_asciidoc('manvolnum'); }; | |
514 | my $err = $@; | |
515 | ||
516 | cleanup(); | |
517 | ||
518 | die $err if $err; | |
519 | ||
520 | } elsif ($clicmd eq 'print-links') { | |
521 | ||
522 | my $outfile; | |
523 | ||
524 | GetOptions("outfile=s" => \$outfile, | |
525 | "verbose" => \$verbose) or | |
526 | die("Error in command line arguments\n"); | |
527 | ||
528 | scalar(@ARGV) == 0 or | |
529 | die "too many arguments...\n"; | |
530 | ||
531 | my $data = get_links(); | |
532 | ||
533 | my $res = to_json($data, { pretty => 1, canonical => 1 } ); | |
534 | ||
535 | if (defined($outfile)) { | |
536 | my $outfh = IO::File->new("$outfile", "w") or | |
537 | die "unable to open temporary file '$outfile'\n"; | |
538 | ||
539 | print $outfh $res; | |
540 | ||
541 | } else { | |
542 | ||
543 | print $res; | |
544 | } | |
545 | ||
546 | } elsif ($clicmd eq 'scan-extjs') { | |
547 | ||
548 | GetOptions("verbose" => \$verbose) or | |
549 | die("Error in command line arguments\n"); | |
550 | ||
551 | my $link_hash = {}; | |
552 | my $scanned_files = {}; | |
553 | while (my $filename = shift) { | |
554 | die "got strange file name '$filename'\n" | |
555 | if $filename !~ m/\.js$/; | |
556 | next if $scanned_files->{$filename}; | |
557 | ||
558 | scan_extjs_file($filename, $link_hash); | |
559 | $scanned_files->{$filename} = 1; | |
560 | } | |
561 | ||
562 | my $data = get_links(); | |
563 | ||
564 | my $res_data = {}; | |
565 | ||
566 | foreach my $blockid (keys %$link_hash) { | |
567 | $res_data->{$blockid} = $data->{$blockid} || $online_help_links->{$blockid} || | |
568 | die "internal error - no data for '$blockid'"; | |
569 | } | |
570 | ||
571 | my $data_str = to_json($res_data, { pretty => 1, canonical => 1 }); | |
572 | chomp $data_str; | |
573 | ||
0ed2611e | 574 | print "var proxmoxOnlineHelpInfo = ${data_str};\n"; |
410dc2c9 DM |
575 | |
576 | } elsif ($clicmd eq 'chapter-table') { | |
577 | ||
578 | print '[width="100%",options="header"]' . "\n"; | |
579 | print "|====\n"; | |
580 | print "|Title|Link\n"; | |
581 | ||
582 | my $filelist = $fileinfo->{outfile}->{default}; | |
583 | foreach my $sourcefile (sort keys %$filelist) { | |
584 | my $target = $filelist->{$sourcefile}; | |
585 | next if $target eq 'pmg-admin-guide.html'; | |
586 | my $title = $fileinfo->{titles}->{default}->{$sourcefile} || | |
587 | die "not title for '$sourcefile'"; | |
588 | print "|$title|link:$target\[\]\n"; | |
589 | } | |
590 | ||
591 | print "|====\n"; | |
592 | ||
593 | } elsif ($clicmd =~ m/^man([158])page-table$/) { | |
594 | ||
595 | my $section = $1; | |
596 | print '[width="100%",cols="5*d",options="header"]' . "\n"; | |
597 | print "|====\n"; | |
598 | print "|Name 3+|Title|Link\n"; | |
599 | ||
600 | my $filelist = $fileinfo->{outfile}->{manvolnum}; | |
601 | foreach my $manpage (sort keys %$filelist) { | |
602 | next if $section ne $fileinfo->{mansection}->{manvolnum}->{$manpage}; | |
603 | my $mantitle = $fileinfo->{titles}->{manvolnum}->{$manpage} || | |
604 | die "not manual title for '$manpage'"; | |
605 | my $title = $fileinfo->{titles}->{default}->{$manpage} || | |
606 | die "not title for '$manpage'"; | |
607 | ||
608 | # hack - remove command name prefix from titles | |
8e976f4c | 609 | $title =~ s/^[a-z_\-]+\s+-\s*//; |
410dc2c9 DM |
610 | |
611 | my $target = $filelist->{$manpage}; | |
612 | print "|$mantitle 3+|$title|link:$target.html\[$target\]\n"; | |
613 | } | |
614 | ||
615 | print "|====\n"; | |
616 | ||
617 | } else { | |
618 | ||
619 | die "unknown command '$clicmd'\n"; | |
620 | ||
621 | } | |
622 | ||
623 | ||
624 | exit 0; | |
625 | ||
626 | __END__ |