Changeset 66

Show
Ignore:
Timestamp:
01/19/07 23:24:11 (2 years ago)
Author:
ingy
Message:
 r70@erxz:  ingy | 2007-01-19 23:23:56 -0800
 Build a doc tree from all docs under src/doc/Kwiki/Foo.pod
 
Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/bin/make-make.pl

    r45 r66  
    33use warnings; 
    44 
    5 my ($type, $star_level) = @ARGV; 
     5my ($output_file, $type, $star_level) = @ARGV; 
    66$star_level ||= 1; 
    77 
     8# ./Kwiki/src/doc/Kwiki/Formatter.pod 
     9 
     10my $pathlet = ($output_file eq 'modules.mk') ? 'lib' : 'src/doc'; 
     11my $file_type = ($output_file eq 'modules.mk') ? 'MODULES' : 'DOCS'; 
     12 
    813my @libs = map { 
    9     s!^.*/lib/!! or die $_; 
     14    s!^.*/$pathlet/!! or die $_; 
    1015    chomp; 
    1116    $_; 
     
    1924our $level5 = ''; 
    2025my $all = ''; 
    21 my $sections = lc($type) . ": \$(${type}_PATHS) \$(${type}_MODULES)\n\n"; 
     26my $sections = lc($type) . ": \$(${type}_PATHS) \$(${type}_$file_type)\n\n"; 
    2227 
    2328for my $lib (@libs) { 
     
    2530    my $level = @parts; 
    2631    my $path = $lib; 
    27     if ($path =~ s!/\w+.pm$!!) { 
     32    if ($path =~ s!/\w+.(pm|pod)$!!) { 
    2833        $paths{$path} = 1; 
    2934    } 
     
    5459 
    5560if ($all) { 
    56     $all = "${type}_MODULES = $all\n\n"; 
     61    $all = "${type}_$file_type = $all\n\n"; 
    5762} 
    5863 
    59 print "$paths$level1$level2$level3$level4$level5$all$sections"; 
     64open OUT, "> $output_file" or die "Can't open $output_file for output: $!"; 
     65print OUT "$paths$level1$level2$level3$level4$level5$all$sections"; 
     66close OUT; 
    6067 
    6168sub make_section { 
    6269    my ($level, $TYPE, $star_level) = @_; 
     70    my $dot_level = $level; 
     71    $dot_level++ if $output_file eq 'docs.mk'; 
    6372    my $type = lc($TYPE); 
    6473    my $stars = join '/', (('*') x $star_level); 
    65     my $dots = join '/', (('..') x $level); 
     74    my $dots = join '/', (('..') x $dot_level); 
    6675    if ($level == 1) { 
    6776        return <<"..."; 
    6877\$(${TYPE}_LEVEL_$level): 
    69         ln -fs $dots/src/$type/$stars/lib/\$\@ \$\@ 
     78        ln -fs $dots/src/$type/$stars/$pathlet/\$\@ \$\@ 
    7079 
    7180... 
     
    7786        \@( \\ 
    7887        cd $dummy; \\ 
    79         lib=$dots/src/$type/$stars/lib/\$\@; \\ 
     88        lib=$dots/src/$type/$stars/$pathlet/\$\@; \\ 
    8089        echo "ln -fs \$\$lib \$\@;"; \\ 
    8190        ln -fs \$\$lib $dots2/\$\@; \\ 
  • trunk/src/Makefile

    r45 r66  
    1 make
    2         $(MAKE) -C cpan modules.mk 
    3         $(MAKE) -C core modules.mk 
    4         $(MAKE) -C plugins modules.mk 
     1all
     2        $(MAKE) -C cpan $@ 
     3        $(MAKE) -C core $@ 
     4        $(MAKE) -C plugins $@ 
  • trunk/src/core/Kwiki/lib/Kwiki.pm

    r45 r66  
    2626    return $self; 
    2727} 
    28  
    29 __DATA__ 
    30  
    31 =head1 NAME 
    32  
    33 Kwiki - The Kwiki Wiki Building Framework 
    34  
    35 =head1 SYNOPSIS 
    36  
    37     > kwiki -new cgi-bin/my-kwiki 
    38  
    39     Kwiki software installed! Point your browser at this location. 
    40  
    41 =head1 NOTE 
    42  
    43 If you are impatient (don't worry, that's a good thing!) read 
    44 L<Kwiki::Command> to get the details on how to install and configure a 
    45 new Kwiki wiki in record time. 
    46  
    47 =head1 DESCRIPTION 
    48  
    49 A Wiki is a website that allows its users to add pages, and edit any 
    50 existing pages. It is one of the most popular forms of web 
    51 collaboration. If you are new to wiki, visit 
    52 http://c2.com/cgi/wiki?WelcomeVisitors which is possibly the oldest 
    53 wiki, and has lots of information about how wikis work. 
    54  
    55 Kwiki is a Perl wiki implementation based on the Spoon application 
    56 architecture and using the Spiffy object orientation model. The major 
    57 goals of Kwiki are that it be easy to install, maintain and extend. 
    58  
    59 All the features of a Kwiki wiki come from plugin modules. The base 
    60 installation comes with the bare minimum plugins to make a working 
    61 Kwiki. To make a really nice Kwiki installation you need to install 
    62 additional plugins. Which plugins you pick is entirely up to you. 
    63 Another goal of Kwiki is that every installation will be unique. 
    64 When there are hundreds of plugins available, this will hopefully 
    65 be the case. 
    66  
    67 =head1 CGI::Kwiki 
    68  
    69 Kwiki is the successor of the popular CGI::Kwiki software. It is a 
    70 complete refactoring of that code. The new code has a lovely plugin API 
    71 and is much cleaner and extendable on all fronts. 
    72  
    73 There is currently no automated way to upgrade a CGI::Kwiki installation 
    74 to Kwiki. It's actually quite easy to do by hand. Instructions on how to 
    75 do it are here: http://www.kwiki.org/?KwikiMigrationByHand 
    76  
    77 =head1 DOCUMENTATION 
    78  
    79 All of the future Kwiki module documentation is being written at 
    80 the http://doc.kwiki.org/ wiki. Check there for the latest doc, and 
    81 help improve it. Each successive release of Kwiki will include the 
    82 latest doc from that site. 
    83  
    84 =head1 CREDITS 
    85  
    86 I am currently employed by Socialtext, Inc. They make high quality 
    87 social software for enterprise deployment. Socialtext has a bold new 
    88 vision of building their products over Open Source software and 
    89 returning the generic source code to the community. This results in a 
    90 win/win effect for both entities. You get this shiny new wiki framework, 
    91 and Socialtext can take advantage of your plugins and bug fixes.  
    92  
    93 The Kwiki project would not be where it is now without their support. I 
    94 thank them. 
    95  
    96 Of particular note, Dave Rolsky and Chris Dent are two current 
    97 Socialtext employees that have made significant contributions to Kwiki. 
    98  
    99  --- 
    100  
    101 Iain Truskett was probably the most active Kwiki community hacker before 
    102 his untimely death in December 2003. The underlying foundation of Kwiki 
    103 has been named "Spoon" in his honor. Rest in peace Spoon. 
    104  
    105  --- 
    106  
    107 Ian (what's with all these Iai?ns??) Langworth has become a new Kwiki 
    108 warrior. He helped a lot with the maiden release. Expect a lot of 
    109 plugins to come from him! Thanks Ian. 
    110  
    111  --- 
    112  
    113 Finally, big props to all the folks on http://www.kwiki.org and 
    114 irc://irc.freenode.net/#kwiki. Thanks for all the support! 
    115  
    116 =head1 SEE ALSO 
    117  
    118 Kwiki::Command 
    119  
    120 =head1 AUTHOR 
    121  
    122 Ingy döt Net <ingy@cpan.org> 
    123  
    124 =head1 COPYRIGHT 
    125  
    126 Copyright (c) 2006. Ingy döt Net. All rights reserved. 
    127  
    128 Copyright (c) 2004. Brian Ingerson. All rights reserved. 
    129  
    130 This program is free software; you can redistribute it and/or modify it 
    131 under the same terms as Perl itself. 
    132  
    133 See http://www.perl.com/perl/misc/Artistic.html 
    134  
    135 =cut 
  • trunk/src/core/Kwiki/lib/Kwiki/Formatter.pm

    r45 r66  
    497497package Kwiki::Formatter; 
    498498__DATA__ 
    499  
    500 =head1 NAME  
    501  
    502 Kwiki::Formatter - Kwiki Formatter Base Class 
    503  
    504 =head1 SYNOPSIS 
    505  
    506 =head1 DESCRIPTION 
    507  
    508 =head1 AUTHOR 
    509  
    510 Ingy döt Net <ingy@cpan.org> 
    511  
    512 =head1 COPYRIGHT 
    513  
    514 Copyright (c) 2006. Ingy döt Net. All rights reserved. 
    515  
    516 Copyright (c) 2004. Brian Ingerson. All rights reserved. 
    517  
    518 This program is free software; you can redistribute it and/or modify it 
    519 under the same terms as Perl itself. 
    520  
    521 See http://www.perl.com/perl/misc/Artistic.html 
    522  
    523 =cut 
    524499__css/formatter.css__ 
    525500pre.formatter_pre { 
  • trunk/src/core/Kwiki/lib/Kwiki/Hub.pm

    r45 r66  
    77    'display'; 
    88} 
    9  
    10 __DATA__ 
    11  
    12 =head1 NAME 
    13  
    14 Kwiki::Hub - Kwiki Hub Base Class 
    15  
    16 =head1 SYNOPSIS 
    17  
    18 =head1 DESCRIPTION 
    19  
    20 =head1 AUTHOR 
    21  
    22 Ingy döt Net <ingy@cpan.org> 
    23  
    24 =head1 COPYRIGHT 
    25  
    26 Copyright (c) 2006. Ingy döt Net. All rights reserved. 
    27  
    28 Copyright (c) 2004. Brian Ingerson. All rights reserved. 
    29  
    30 This program is free software; you can redistribute it and/or modify it 
    31 under the same terms as Perl itself. 
    32  
    33 See http://www.perl.com/perl/misc/Artistic.html 
    34  
    35 =cut 
  • trunk/src/core/Makefile

    r45 r66  
    11TYPE=CORE 
     2 
     3all: modules.mk docs.mk 
     4 
    25include ../modules.mk 
     6include ../docs.mk 
  • trunk/src/cpan/Makefile

    r45 r66  
    11TYPE=CPAN 
     2 
     3all: modules.mk 
     4 
    25include ../modules.mk 
  • trunk/src/modules.mk

    r48 r66  
    77        grep -v '/t/' | \ 
    88        sort -fd | \ 
    9         perl ../../bin/make-make.pl $(TYPE) $(GLOB_LEVEL) > $@ 
     9        perl ../../bin/make-make.pl $@ $(TYPE) $(GLOB_LEVEL) 
  • trunk/src/plugins/Makefile

    r45 r66  
    11TYPE=PLUGINS 
    22GLOB_LEVEL=2 
     3 
     4all: modules.mk docs.mk 
     5 
    36include ../modules.mk 
     7include ../docs.mk 
  • trunk/src/plugins/ingy/Kwiki-Cache/lib/Kwiki/Cache.pm

    r45 r66  
    4646    return $value; 
    4747} 
    48  
    49 __DATA__ 
    50  
    51 =head1 NAME  
    52  
    53 Kwiki::Cache - Kwiki Cache Plugin 
    54  
    55 =head1 SYNOPSIS 
    56  
    57 =head1 DESCRIPTION 
    58  
    59 =head1 AUTHOR 
    60  
    61 Ingy döt Net <ingy@cpan.org> 
    62  
    63 =head1 COPYRIGHT 
    64  
    65 Copyright (c) 2006. Ingy döt Net. All rights reserved. 
    66  
    67 Copyright (c) 2004. Brian Ingerson. All rights reserved. 
    68  
    69 This program is free software; you can redistribute it and/or modify it 
    70 under the same terms as Perl itself. 
    71  
    72 See http://www.perl.com/perl/misc/Artistic.html 
    73  
    74 =cut