From e1018a69a6d7caa246f3b7b9edd786ddb07c94a9 Mon Sep 17 00:00:00 2001 From: David Mitchell Date: Sat, 18 Jul 2009 21:36:14 +0100 Subject: [PATCH] add basic usage info to Porting/corelist.pl --- Porting/corelist.pl | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/Porting/corelist.pl b/Porting/corelist.pl index b301c83..bb0cf92 100644 --- a/Porting/corelist.pl +++ b/Porting/corelist.pl @@ -1,6 +1,13 @@ #!perl # Generates info for Module::CoreList from this perl tree -# run this from the root of a clean perl tree +# run this from the root of a perl tree, using the perl built in that tree. +# +# Data is on STDOUT. +# +# With an optional arg specifying the root of a CPAN mirror, outputs the +# %upstream and %bug_tracker hashes too. + +use 5.010001; # needs Parse::CPAN::Meta use strict; use warnings; @@ -10,11 +17,18 @@ use lib "Porting"; use Maintainers qw(%Modules files_to_modules); use File::Spec; + my %lines; my %module_to_file; my %modlist; + +die "usage: $0 [ cpan-mirror/ ]\n" unless @ARGV <= 1; my $cpan = shift; +if (! -f 'MANIFEST') { + die "Must be run from the root of a clean perl tree\n" +} + if ($cpan) { my $modlistfile = File::Spec->catfile($cpan, 'modules', '02packages.details.txt'); -- 2.7.4