Module::New::Recipe::Dist - create a new distribution


Module-New documentation Contained in the Module-New distribution.

Index


Code Index:

NAME

Top

Module::New::Recipe::Dist - create a new distribution

USAGE

Top

From the shell/command line:

module_new dist Module::Name

creates Module-Name directory for the distribution, and trunk, branches, tags directories there, and also several files and tests (including lib/Module/Name.pm) in the <Module-Name/trunk> directory.

OPTIONS

Top

in
  module_new dist Module::Name --in t

creates a distribution in t/ directory, instead of the current directory.

no_dirs
  module_new dist Module::Name --no_dirs

doesn't creates Module-Name/trunk, Module-Name/branches, Module-Name/tags directories for subversion, and creates various files including lib/Module/Name.pm just under the Module-Name directory.

xs
  module_new dist Module::Name --xs

creates extra XS stuff like Name.xs, Name.h and ppport.h (if you have installed Devel::PPPort). Also, the content of lib/Module/Name.pm changes to load XSLoader.

make
  module_new dist Module::Name --make=ModuleInstall

by default, Module::New creates ExtUtils::MakeMaker-based Makefile.PL, but with this option, you can make it to create Build.PL to use Module::Build (set this to ModuleBuild or MB for shortcut), or Makefile.PL powered by Module::Install (set this to ModuleInstall, or MI).

edit
  module_new dist Module::Name --edit

If set to true, you can edit lib/Module/Name.pm you created.

AUTHOR

Top

Kenichi Ishigaki, <ishigaki@cpan.org>

COPYRIGHT AND LICENSE

Top


Module-New documentation Contained in the Module-New distribution.

package Module::New::Recipe::Dist;

use strict;
use warnings;
use Module::New::Recipe;
use Module::New::Command::Basic;

available_options qw( make=s test|t=s@ edit|e no_dirs xs );

flow {
  set_distname;

  create_distdir;

  create_maketool;

  create_general_files;

  create_tests;

  create_files(qw( MainModule ));

  create_manifest;

  edit_mainfile( optional => 1 );
};

1;

__END__