diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2003-08-05 08:31:29 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2003-08-05 08:31:29 +0000 |
commit | 0cf5154416a0eea5954731af354063d20292b41e (patch) | |
tree | 38975fb85c4d9f90a58c5a27befd396cab98d37f /Porting/makemeta | |
parent | cab0dcf91472885c5e694c5a5a9da5a38760ac49 (diff) | |
download | perl-0cf5154416a0eea5954731af354063d20292b41e.tar.gz |
Add META.yml and Stas' makemeta (plus extensive reworking
of the Maintainers utility)
p4raw-id: //depot/perl@20491
Diffstat (limited to 'Porting/makemeta')
-rw-r--r-- | Porting/makemeta | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/Porting/makemeta b/Porting/makemeta new file mode 100644 index 0000000000..9889c8e81a --- /dev/null +++ b/Porting/makemeta @@ -0,0 +1,36 @@ +#!/usr/bin/perl -w + +use strict; +use warnings; +use lib "Porting"; + +my $file = "META.yml"; +die "$0: will not override $file, delete it first.\n" if -e $file; + +use Maintainers qw(%Modules get_module_files get_module_pat); + +my @CPAN = grep { $Modules{$_}{CPAN} } keys %Modules; +my @files = map { get_module_files($_) } @CPAN; +my @dirs = grep { -d $_ } map { get_module_pat($_) } @CPAN; + +my $files = join '', map { " - $_\n" } sort { lc $a cmp lc $b } @files; +my $dirs = join '', map { " - $_\n" } sort { lc $a cmp lc $b } @dirs; + +open my $fh, ">$file" or die "Can't open $file: $!"; + +print $fh <<"EOI"; +name: perl +version: $] +abstract: Practical Extraction and Reporting Language +author: perl5-porters\@perl.org +license: perl +distribution_type: core +private: + directory: +$dirs + file: +$files +EOI + +close $fh; + |