Created
March 27, 2011 08:32
-
-
Save sshaw/889041 to your computer and use it in GitHub Desktop.
Makefile.PL postamble() - Create README.pod for Perl packages uploaded to GitHub
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create README.pod for a repo's GitHub page. Unlike CPAN, GitHub won't | |
# display the module's POD, it looks for a README.* | |
use Config; | |
sub MY::postamble | |
{ | |
my $self = shift; | |
return if -r 'README' or ! -r $self->{VERSION_FROM}; | |
return<<END_MAKE; | |
README.pod: $self->{VERSION_FROM} | |
\@$Config{bin}/perldoc -uT $self->{VERSION_FROM} > README.pod | |
END_MAKE | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment