Debian Codegraph @

README

raw
1 NAME
2 Module::Install::AuthorRequires - declare author-only dependencies
3
4 SYNOPSIS
5 author_requires 'Some::Module';
6 author_requires 'Another::Module' => '0.42';
7
8 DESCRIPTION
9 Modules often have optional requirements, for example dependencies that
10 are useful for (optional) tests, but not required for the module to work
11 properly.
12
13 Usually you want all developers of a project to have these optional
14 modules installed. However, simply telling everyone or printing
15 diagnostic messages if optional dependencies are missing often isn't
16 enough to make sure all authors have all optional modules installed.
17
18 "Module::Install" already has a way of detecting an author environment,
19 so an easy way to achieve the above would be something like:
20
21 if ($Module::Install::AUTHOR) {
22 requires 'Some::Module';
23 requires 'Another::Module' => '0.42';
24 }
25
26 Unfortunately, that'll also make the optional dependencies show up in
27 the distributions "META.yml" file, which is obviously wrong, as they
28 aren't actually hard requirements.
29
30 Working that around requires a considerable amount of non-trivial
31 Makefile.PL hackery, or simply using this module's "author_requires"
32 command.
33
34 COMMANDS
35 author_requires
36 author_requires $module;
37 author_requires $module => $version;
38
39 This declares a hard dependency, that's only enforced in author
40 environments and is not put in the generate "META.yml" file of the
41 distribution.
42
43 AUTHOR
44 Florian Ragwitz <[email protected]>
45
46 COPYRIGHT AND LICENSE
47 Copyright (c) 2009 Florian Ragwitz
48
49 This is free software; you can redistribute it and/or modify it under
50 the same terms as the Perl 5 programming language system itself.
51