Schema/cpan/distname.pm

filter: Statementstmt 100% 9 / 9 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 1 / 1 Podpod n/a totaltotal 100% 10 / 10 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
CRAP 1.0
↑ Summary Schema/cpan/modname.pm »
1 package Sah::Schema::cpan::distname;
2  
3 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 1 our $AUTHORITY = 'cpan:PERLANCAR'; # AUTHORITY
6 1 our $DATE = '2024-06-13'; # DATE
7 1 our $DIST = 'Sah-SchemaBundle-CPAN'; # DIST
8 1 our $VERSION = '0.016'; # VERSION
9  
10 1 our $schema = ["perl::distname", {
11 summary => 'A distribution name on CPAN, e.g. "Module-Installed-Tiny"',
12 description => <<'MARKDOWN',
13  
14 This schema can be used to validate a CPAN distribution name. It's like the
15 `perl::distname` schema, but with completion from distribution names on CPAN
16 (using <prog:lcpan>). It does not check whether a CPAN distribution exists or
17 not (indexed on PAUSE); use the `cpan::distname::exists` or
18 `cpan::distname::not_exists` schemas for that purpose.
19  
20 MARKDOWN
21 'x.completion'=>['lcpan_distname'],
22 examples => [
23 {value=>'', valid=>0},
24 {value=>'Foo-Bar' , valid=>1, validated_value=>'Foo-Bar'},
25 {value=>'Foo::Bar', valid=>1, validated_value=>'Foo-Bar'},
26 ],
27 }];
28  
29 1 1;
30  
31 # ABSTRACT: A distribution name on CPAN, e.g. "Module-Installed-Tiny"
32  
33 __END__
↑ Summary Schema/cpan/modname.pm »