diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2001-08-03 20:35:52 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2001-08-03 20:35:52 +0000 |
commit | 36c71dae935ba4b18896ffcfc069a64130731dfd (patch) | |
tree | e6f800c681a3df06ff8b080fb8ca9463485ace27 /MDK/Common.pm.pl | |
parent | 1696c19c569ce62fbe585a52ce3cf55a9bedb919 (diff) | |
download | perl-MDK-Common-36c71dae935ba4b18896ffcfc069a64130731dfd.tar perl-MDK-Common-36c71dae935ba4b18896ffcfc069a64130731dfd.tar.gz perl-MDK-Common-36c71dae935ba4b18896ffcfc069a64130731dfd.tar.bz2 perl-MDK-Common-36c71dae935ba4b18896ffcfc069a64130731dfd.tar.xz perl-MDK-Common-36c71dae935ba4b18896ffcfc069a64130731dfd.zip |
generate the doc in Common.pm from Common/*.pm
Diffstat (limited to 'MDK/Common.pm.pl')
-rw-r--r-- | MDK/Common.pm.pl | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/MDK/Common.pm.pl b/MDK/Common.pm.pl new file mode 100644 index 0000000..328ace6 --- /dev/null +++ b/MDK/Common.pm.pl @@ -0,0 +1,76 @@ + + +print <<'EOF'; +=head1 NAME + +MDK::Common - miscellaneous functions + +=head1 SYNOPSIS + + use MDK::Common; + # exports all functions, equivalent to + + use MDK::Common::DataStructure qw(:all); + use MDK::Common::File qw(:all); + use MDK::Common::Func qw(:all); + use MDK::Common::Math qw(:all); + use MDK::Common::String qw(:all); + use MDK::Common::System qw(:all); + use MDK::Common::Various qw(:all); + +=head1 DESCRIPTION + +C<MDK::Common> is a collection of packages containing various simple functions: +L<MDK::Common::DataStructure>, +L<MDK::Common::File>, +L<MDK::Common::Func>, +L<MDK::Common::Globals>, +L<MDK::Common::Math>, +L<MDK::Common::String>, +L<MDK::Common::System>, +L<MDK::Common::Various>. + +EOF + +foreach my $f (<MDK/Common/*.pm>) { + (my $pkg = $f) =~ s|/|::|g; + open F, $f or die "can't open file $f"; + while (<F>) { + if (/^=head1 (EXPORTS|OTHER)/ .. /^=back/) { + s/^=head1 EXPORTS/=head1 EXPORTS from $pkg/; + s/^=head1 OTHER/=head1 OTHER in $pkg/; + s/^=back/=back\n/; + print; + } + } +} + + +print <<'EOF'; +=head1 COPYRIGHT + +Copyright (c) 2001 MandrakeSoft <pixel@mandrakesoft.com>. All rights reserved. +This program is free software; you can redistribute it and/or +modify it under the same terms as Perl itself. + +=cut + +package MDK::Common; + +use MDK::Common::DataStructure qw(:all); +use MDK::Common::File qw(:all); +use MDK::Common::Func qw(:all); +use MDK::Common::Math qw(:all); +use MDK::Common::String qw(:all); +use MDK::Common::System qw(:all); +use MDK::Common::Various qw(:all); + +use vars qw(@ISA @EXPORT $VERSION); #); +@ISA = qw(Exporter); +# perl_checker: RE-EXPORT-ALL +@EXPORT = map { @$_ } map { values %{'MDK::Common::' . $_ . 'EXPORT_TAGS'} } grep { /::$/ } keys %MDK::Common::; + +$VERSION = "1.0"; + +1; +EOF |