Changeset 1921

Show
Ignore:
Timestamp:
08/22/06 14:36:11
Author:
miyagawa
Message:

added README

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • misc/pmsetup

    r1919 r1921  
    1818} 
    1919 
     20while (! $config->{email}) { 
     21    $config->{email} = prompt("Your email: ", ''); 
     22    $save++; 
     23} 
     24 
    2025my $modname = shift @ARGV or die "Usage: $0 module\n"; 
    2126my @pkg = split /::/, $modname; 
     
    2732mk_changes($modname); 
    2833mk_module_template($libdir, $modname, @pkg); 
     34mk_readme($modname); 
    2935mk_manifest(); 
    3036prepare_make(); 
     
    133139=head1 AUTHOR 
    134140 
    135 $config->{author} 
     141$config->{author} E<lt>$config->{email}E<gt> 
    136142 
    137143=head1 LICENSE 
     
    165171} 
    166172 
     173sub mk_readme { 
     174    my $mod  = shift; 
     175    my $file = FileHandle->new(">README") or die $!; 
     176    $file->print(<<EOF); 
     177This is Perl module $mod. 
     178 
     179INSTALLATION 
     180 
     181$mod installation is straightforward. If your CPAN shell is set up, 
     182you should just be able to do 
     183 
     184    % cpan $mod 
     185 
     186Download it, unpack it, then build it as per the usual: 
     187 
     188    % perl Makefile.PL 
     189    % make && make test 
     190 
     191Then install it: 
     192 
     193    % make install 
     194 
     195DOCUMENTATION 
     196 
     197$mod documentation is available as in POD. So you can do: 
     198 
     199    % perldoc $mod 
     200 
     201to read the documentation online with your favorite pager. 
     202 
     203$config->{author} 
     204EOF 
     205} 
     206 
    167207sub prepare_make { 
    168208    !system "perl Makefile.PL" or die $?;