ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/cfmaps/cfarch2html
(Generate patch)

Comparing cfmaps/cfarch2html (file contents):
Revision 1.4 by root, Fri Nov 18 23:20:26 2005 UTC vs.
Revision 1.6 by root, Sun Nov 20 01:05:34 2005 UTC

1#!/opt/bin/perl 1#!/opt/bin/perl
2
3# cfarch2html - convert crossfire archetypes to html
4# Copyright (C) 2005 Marc Lehmann <gvpe@schmorp.de>
5#
6# CFARCH2HTML is free software; you can redistribute it and/or modify
7# it under the terms of the GNU General Public License as published by
8# the Free Software Foundation; either version 2 of the License, or
9# (at your option) any later version.
10#
11# This program is distributed in the hope that it will be useful,
12# but WITHOUT ANY WARRANTY; without even the implied warranty of
13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14# GNU General Public License for more details.
15#
16# You should have received a copy of the GNU General Public License
17# along with gvpe; if not, write to the Free Software
18# Foundation, Inc. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
20our $VERSION = '1.01';
2 21
3use Storable; 22use Storable;
4 23
5my $LIBDIR = $ENV{CROSSFIRE_LIBDIR} 24my $LIBDIR = $ENV{CROSSFIRE_LIBDIR}
6 or die "\$CROSSFIRE_LIBDIR must be set\n"; 25 or die "\$CROSSFIRE_LIBDIR must be set\n";
7
8our $VERSION = '1.0';
9 26
10my $arch; 27my $arch;
11 28
12sub escape_html($) { 29sub escape_html($) {
13 local $_ = shift; 30 local $_ = shift;
72 print "<tr valign='top'><th align='left'><a name='", (lc $name), "'>$name</a></th><td>"; 89 print "<tr valign='top'><th align='left'><a name='", (lc $name), "'>$name</a></th><td>";
73 print_arch $arch->{$name}; 90 print_arch $arch->{$name};
74 print "</td></tr>"; 91 print "</td></tr>";
75} 92}
76 93
77print "</table><hr/><p style='font-size: 8pt'>created by <b>cfarch2html</b> version $VERSION</p>", 94print "</table><hr/><p style='font-size: 8pt'>created by <a href='http://software.schmorp.de/#crossfire'>cfarch2html</a> version $VERSION</p>",
78 "</body></html>"; 95 "</body></html>";
79 96
80close $fh; 97close $fh;
81 98
82system "gzip", "-7f", "archetypes.html"; 99system "gzip", "-7f", "archetypes.html";

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines