diff options
| -rw-r--r-- | Makefile | 3 | ||||
| -rw-r--r-- | fml/doc/ja/htdocs/menubar.html | 6 | ||||
| -rwxr-xr-x | fml/utils/bin/pm2txt.pl | 61 |
3 files changed, 64 insertions, 6 deletions
@@ -1,5 +1,5 @@ # -# $FML: Makefile,v 1.14 2001/04/28 09:26:36 fukachan Exp $ +# $FML: Makefile,v 1.15 2001/04/28 10:14:53 fukachan Exp $ # CONV = doc/bin/text2html.pl @@ -36,7 +36,6 @@ _new_doc: -fml/utils/bin/pm2txt.pl cpan/lib Documentation/en/modules _html: - @ (cd fml/lib/;make html) @ (cd fml/libexec/;make html) @ (cd fml/etc/;make html) @ (cd cpan/dist/;make html) diff --git a/fml/doc/ja/htdocs/menubar.html b/fml/doc/ja/htdocs/menubar.html index d9691300..34c3718b 100644 --- a/fml/doc/ja/htdocs/menubar.html +++ b/fml/doc/ja/htdocs/menubar.html @@ -89,7 +89,8 @@ fml-devel (fml 5.0) project menu fml.org ´É³í <UL> <LI> - <A HREF="../../../lib/index.ja.html" TARGET="right"> + <A HREF="../../../../Documentation/en/modules/fml-lib-index.html" + TARGET="right"> lib/ </A> <LI> @@ -98,7 +99,8 @@ fml-devel (fml 5.0) project menu </A> </UL> <LI> - <A HREF="../../../../cpan/dist/index.html" TARGET="right"> + <A HREF="../../../../Documentation/en/modules/cpan-lib-index.html" + TARGET="right"> CPAN ¤«¤é¤ÎÍ¢Æþ </A> </UL> diff --git a/fml/utils/bin/pm2txt.pl b/fml/utils/bin/pm2txt.pl index 02f01e94..7a2a7822 100755 --- a/fml/utils/bin/pm2txt.pl +++ b/fml/utils/bin/pm2txt.pl @@ -5,12 +5,12 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML$ +# $FML: pm2txt.pl,v 1.1 2001/04/27 04:42:13 fukachan Exp $ # use strict; use Carp; -use vars qw($debug); +use vars qw($debug %PMList %TxtList); use FileHandle; use File::stat; @@ -27,6 +27,7 @@ sub convert _mkdir(@_); _convert(@_); + _make_index(@_); } @@ -73,6 +74,10 @@ sub _convert $dst =~ s@//@/@g; $dst =~ s/.pm/.txt/; + # saved for + $PMList{ $src } = $src; + $TxtList{ $src } = $dst; + $go = 0; $sstat = stat($src) || croak("cannot stat $src"); @@ -97,4 +102,56 @@ sub _convert } +sub _make_index +{ + my ($src_dir, $dst_dir) = @_; + my ($up_dir); + my (%list, %pmlink, %txtlink); + + $up_dir = $dst_dir; + $up_dir =~ s/\w+/../g; + + for (keys %PMList) { + my $x = $_; + $x =~ s/$src_dir//; + $x =~ s@^/@@; + $list{ $_ } = $x; + $pmlink{ $x } = "$up_dir/$src_dir/$x"; + } + + my $dir = $src_dir; + $dir =~ s@^/@@; + $dir =~ s@/$@@; + $dir =~ s@/@-@g; + my $index = "$dst_dir/${dir}-index.html"; + my $wh = new FileHandle "> $index"; + + print "generate $index\n"; + + my $level = 0; + print $wh "<TABLE>\n"; + for (sort keys %list) { + my $name = $_; + my $txt = $TxtList{ $_ }; + my $x = $list{ $_ }; + + $name =~ s@$src_dir@@; + $name =~ s@^/@@; + $name =~ s@.pm$@@; + $name =~ s@/@::@g; + + $txt =~ s@$dst_dir@@; + $txt =~ s@^/@@; + + print $wh "<TR>\n"; + print $wh "<TD>$name\n"; + print $wh "<TD><A HREF=\"", $pmlink{ $x }, "\">[source]</A>\n"; + print $wh "<TD><A HREF=\"", $txt, "\">[manual]</A>\n"; + print $wh "\n"; + } + print $wh "</TABLE>\n"; + + $wh->close; +} + 1; |
