1Perl::PrereqScanner::NoUtsQeuritCeoLnittrei(b3u)ted PerlPeDrolc:u:mPernetraetqiSocnanner::NotQuiteLite(3)
2
3
4

NAME

6       Perl::PrereqScanner::NotQuiteLite - a tool to scan your Perl code for
7       its prerequisites
8

SYNOPSIS

10         use Perl::PrereqScanner::NotQuiteLite;
11         my $scanner = Perl::PrereqScanner::NotQuiteLite->new(
12           parsers => [qw/:installed -UniversalVersion/],
13           suggests => 1,
14         );
15         my $context = $scanner->scan_file('path/to/file');
16         my $requirements = $context->requires;
17         my $recommends = $context->recommends;
18         my $suggestions  = $context->suggests; # requirements in evals
19         my $noes = $context->noes;
20

BACKWARD INCOMPATIBLILITY

22       As of 0.49_01, the internal of this module was completely rewritten.
23       I'm supposing there's no one who has written their own parsers for the
24       previous version, but if this assumption was wrong, let me know.
25

DESCRIPTION

27       Perl::PrereqScanner::NotQuiteLite is yet another prerequisites scanner.
28       It passes almost all the scanning tests for Perl::PrereqScanner and
29       Module::ExtractUse (ie. except for a few dubious ones), and runs
30       slightly faster than PPI-based Perl::PrereqScanner. However, it doesn't
31       run as fast as Perl::PrereqScanner::Lite (which uses an XS lexer).
32
33       Perl::PrereqScanner::NotQuiteLite also recognizes "eval".
34       Prerequisites in "eval" are not considered as requirements, but you can
35       collect them as suggestions.
36
37       Conditional requirements or requirements loaded in a block are treated
38       as recommends. Noed modules are stored separately (since 0.94).  You
39       may or may not need to merge them into requires.
40

METHODS

42   new
43       creates a scanner object. Options are:
44
45       parsers
46           By default, Perl::PrereqScanner::NotQuiteLite only recognizes
47           modules loaded directly by "use", "require", "no" statements, plus
48           modules loaded by a few common modules such as "base", "parent",
49           "if" (that are in the Perl core), and by two keywords exported by
50           Moose family ("extends" and "with").
51
52           If you need more, you can pass extra parser names to the scanner,
53           or ":installed", which loads and registers all the installed
54           parsers under "Perl::PrereqScanner::NotQuiteLite::Parser"
55           namespace.
56
57           You can also pass a project-specific parser (that lies outside the
58           "Perl::PrereqScanner::NotQuiteLite::Parser" namespace) by
59           prepending "+" to the name.
60
61             use Perl::PrereqScanner::NotQuiteLite;
62             my $scanner = Perl::PrereqScanner::NotQuiteLite->new(
63               parsers => [qw/+PrereqParser::For::MyProject/],
64             );
65
66           If you don't want to load a specific parser for some reason,
67           prepend "-" to the parser name.
68
69       suggests
70           Perl::PrereqScanner::NotQuiteLite ignores "use"-like statements in
71           "eval" by default. If you set this option to true,
72           Perl::PrereqScanner::NotQuiteLite also parses statements in "eval",
73           and records requirements as suggestions.
74
75   scan_file
76       takes a path to a file and returns a ::Context object.
77
78   scan_string
79       takes a string, scans and returns a ::Context object.
80

SEE ALSO

82       Perl::PrereqScanner, Perl::PrereqScanner::Lite, Module::ExtractUse
83

AUTHOR

85       Kenichi Ishigaki, <ishigaki@cpan.org>
86
88       This software is copyright (c) 2015 by Kenichi Ishigaki.
89
90       This is free software; you can redistribute it and/or modify it under
91       the same terms as the Perl 5 programming language system itself.
92
93
94
95perl v5.28.1                      2019-02-0P3erl::PrereqScanner::NotQuiteLite(3)
Impressum