GIF89a; EcchiShell v1.0
//usr/share/perl5/pod/

Mass Deface package from CPAN, F is an older tool, originally intended for the development of XS modules, which comes packaged with the Perl distribution. A typical invocation of L for a pure Perl module is: h2xs -AX --skip-exporter --use-new-tests -n Foo::Bar The C<-A> omits the Autoloader code, C<-X> omits XS elements, C<--skip-exporter> omits the Exporter code, C<--use-new-tests> sets up a modern testing environment, and C<-n> specifies the name of the module. =item Use L and L A module's code has to be warning and strict-clean, since you can't guarantee the conditions that it'll be used under. Besides, you wouldn't want to distribute code that wasn't warning or strict-clean anyway, right? =item Use L The L module allows you to present your error messages from the caller's perspective; this gives you a way to signal a problem with the caller and not your module. For instance, if you say this: warn "No hostname given"; the user will see something like this: No hostname given at /usr/local/lib/perl5/site_perl/5.6.0/Net/Acme.pm line 123. which looks like your module is doing something wrong. Instead, you want to put the blame on the user, and say this: No hostname given at bad_code, line 10. You do this by using L and replacing your Cs with Cs. If you need to C, say C instead. However, keep C and C in place for your sanity checks - where it really is your module at fault. =item Use L - wisely! L gives you a standard way of exporting symbols and subroutines from your module into the caller's namespace. For instance, saying C would import the C subroutine. The package variable C<@EXPORT> will determine which symbols will get exported when the caller simply says C - you will hardly ever want to put anything in there. C<@EXPORT_OK>, on the other hand, specifies which symbols you're willing to export. If you do want to export a bunch of symbols, use the C<%EXPORT_TAGS> and define a standard export set - look at L for more details. =item Use L The work isn't over until the paperwork is done, and you're going to need to put in some time writing some documentation for your module. C or C will provide a stub for you to fill in; if you're not sure about the format, look at L for an introduction. Provide a good synopsis of how your module is used in code, a description, and then notes on the syntax and function of the individual subroutines or methods. Use Perl comments for developer notes and POD for end-user notes. =item Write tests You're encouraged to create self-tests for your module to ensure it's working as intended on the myriad platforms Perl supports; if you upload your module to CPAN, a host of testers will build your module and send you the results of the tests. Again, C and C provide a test framework which you can extend - you should do something more than just checking your module will compile. L and L are good places to start when writing a test suite. =item Write the README If you're uploading to CPAN, the automated gremlins will extract the README file and place that in your CPAN directory. It'll also appear in the main F and F directories if you make it onto the modules list. It's a good idea to put here what the module actually does in detail, and the user-visible changes since the last release. =back =head2 Step-by-step: Distributing your module =over 3 =item Get a CPAN user ID Every developer publishing modules on CPAN needs a CPAN ID. Visit C, select "Request PAUSE Account", and wait for your request to be approved by the PAUSE administrators. =item C Once again, C or C has done all the work for you. They produce the standard C you see when you download and install modules, and this produces a Makefile with a C target. Once you've ensured that your module passes its own tests - always a good thing to make sure - you can C, and the Makefile will hopefully produce you a nice tarball of your module, ready for upload. =item Upload the tarball The email you got when you received your CPAN ID will tell you how to log in to PAUSE, the Perl Authors Upload SErver. From the menus there, you can upload your module to CPAN. =item Announce to the modules list Once uploaded, it'll sit unnoticed in your author directory. If you want it connected to the rest of the CPAN, you'll need to go to "Register Namespace" on PAUSE. Once registered, your module will appear in the by-module and by-category listings on CPAN. =item Announce to clpa If you have a burning desire to tell the world about your release, post an announcement to the moderated C newsgroup. =item Fix bugs! Once you start accumulating users, they'll send you bug reports. If you're lucky, they'll even send you patches. Welcome to the joys of maintaining a software project... =back =head1 AUTHOR Simon Cozens, C Updated by Kirrily "Skud" Robert, C =head1 SEE ALSO L, L, L, L, L, L, L, L, L, L L, L, L http://www.cpan.org/ , Ken Williams's tutorial on building your own module at http://mathforum.org/~ken/perl_modules.html